summaryrefslogtreecommitdiff
path: root/static_pool_test.go
diff options
context:
space:
mode:
authorValery Piashchynski <[email protected]>2020-12-14 13:54:44 +0300
committerValery Piashchynski <[email protected]>2020-12-14 13:54:44 +0300
commitf6063d06d3a381036abd672dfbb799d777455fb0 (patch)
tree2370c6e2263fd286d8fe412de951304df69f9806 /static_pool_test.go
parent00b42663891713f142a6cc67bcccdc31353daeb2 (diff)
fix tests issues
Diffstat (limited to 'static_pool_test.go')
-rwxr-xr-xstatic_pool_test.go14
1 files changed, 7 insertions, 7 deletions
diff --git a/static_pool_test.go b/static_pool_test.go
index 747f26c4..33799c40 100755
--- a/static_pool_test.go
+++ b/static_pool_test.go
@@ -82,7 +82,7 @@ func Test_StaticPool_Echo(t *testing.T) {
assert.NoError(t, err)
assert.NotNil(t, res)
assert.NotNil(t, res.Body)
- assert.Nil(t, res.Context)
+ assert.Empty(t, res.Context)
assert.Equal(t, "hello", res.String())
}
@@ -106,7 +106,7 @@ func Test_StaticPool_Echo_NilContext(t *testing.T) {
assert.NoError(t, err)
assert.NotNil(t, res)
assert.NotNil(t, res.Body)
- assert.Nil(t, res.Context)
+ assert.Empty(t, res.Context)
assert.Equal(t, "hello", res.String())
}
@@ -129,7 +129,7 @@ func Test_StaticPool_Echo_Context(t *testing.T) {
assert.NoError(t, err)
assert.NotNil(t, res)
- assert.Nil(t, res.Body)
+ assert.Empty(t, res.Body)
assert.NotNil(t, res.Context)
assert.Equal(t, "world", string(res.Context))
@@ -214,7 +214,7 @@ func Test_StaticPool_Broken_FromOutside(t *testing.T) {
assert.NoError(t, err)
assert.NotNil(t, res)
assert.NotNil(t, res.Body)
- assert.Nil(t, res.Context)
+ assert.Empty(t, res.Context)
assert.Equal(t, "hello", res.String())
assert.Equal(t, runtime.NumCPU(), len(p.Workers()))
@@ -293,7 +293,7 @@ func Test_StaticPool_Replace_Worker(t *testing.T) {
assert.NoError(t, err)
assert.NotNil(t, res)
assert.NotNil(t, res.Body)
- assert.Nil(t, res.Context)
+ assert.Empty(t, res.Context)
assert.NotEqual(t, lastPID, string(res.Body))
lastPID = string(res.Body)
@@ -332,7 +332,7 @@ func Test_StaticPool_Debug_Worker(t *testing.T) {
assert.NoError(t, err)
assert.NotNil(t, res)
assert.NotNil(t, res.Body)
- assert.Nil(t, res.Context)
+ assert.Empty(t, res.Context)
assert.NotEqual(t, lastPID, string(res.Body))
lastPID = string(res.Body)
@@ -372,7 +372,7 @@ func Test_StaticPool_Stop_Worker(t *testing.T) {
assert.NoError(t, err)
assert.NotNil(t, res)
assert.NotNil(t, res.Body)
- assert.Nil(t, res.Context)
+ assert.Empty(t, res.Context)
assert.NotEqual(t, lastPID, string(res.Body))
lastPID = string(res.Body)