@@ -4,23 +4,23 @@ import (
4
4
"testing"
5
5
6
6
"github.com/Shopify/sarama"
7
- "github.com/lovoo/goka/internal/test "
7
+ "github.com/stretchr/testify/require "
8
8
)
9
9
10
10
func TestConfig_DefaultConfig (t * testing.T ) {
11
11
t .Run ("equal" , func (t * testing.T ) {
12
12
cfg := DefaultConfig ()
13
- test . AssertTrue (t , cfg .Version == sarama .V2_0_0_0 )
14
- test . AssertTrue (t , cfg .Consumer .Return .Errors == true )
15
- test . AssertTrue (t , cfg .Consumer .MaxProcessingTime == defaultMaxProcessingTime )
16
- test . AssertTrue (t , cfg .Consumer .Offsets .Initial == sarama .OffsetNewest )
17
- test . AssertTrue (t , cfg .Producer .RequiredAcks == sarama .WaitForLocal )
18
- test . AssertTrue (t , cfg .Producer .Compression == sarama .CompressionSnappy )
19
- test . AssertTrue (t , cfg .Producer .Flush .Frequency == defaultFlushFrequency )
20
- test . AssertTrue (t , cfg .Producer .Flush .Bytes == defaultFlushBytes )
21
- test . AssertTrue (t , cfg .Producer .Return .Successes == true )
22
- test . AssertTrue (t , cfg .Producer .Return .Errors == true )
23
- test . AssertTrue (t , cfg .Producer .Retry .Max == defaultProducerMaxRetries )
13
+ require . True (t , cfg .Version == sarama .V2_0_0_0 )
14
+ require . True (t , cfg .Consumer .Return .Errors == true )
15
+ require . True (t , cfg .Consumer .MaxProcessingTime == defaultMaxProcessingTime )
16
+ require . True (t , cfg .Consumer .Offsets .Initial == sarama .OffsetNewest )
17
+ require . True (t , cfg .Producer .RequiredAcks == sarama .WaitForLocal )
18
+ require . True (t , cfg .Producer .Compression == sarama .CompressionSnappy )
19
+ require . True (t , cfg .Producer .Flush .Frequency == defaultFlushFrequency )
20
+ require . True (t , cfg .Producer .Flush .Bytes == defaultFlushBytes )
21
+ require . True (t , cfg .Producer .Return .Successes == true )
22
+ require . True (t , cfg .Producer .Return .Errors == true )
23
+ require . True (t , cfg .Producer .Retry .Max == defaultProducerMaxRetries )
24
24
})
25
25
}
26
26
@@ -29,7 +29,7 @@ func TestConfig_ReplaceGlobalConfig(t *testing.T) {
29
29
custom := DefaultConfig ()
30
30
custom .Version = sarama .V0_8_2_0
31
31
ReplaceGlobalConfig (custom )
32
- test . AssertEqual (t , globalConfig .Version , custom .Version )
32
+ require . Equal (t , custom .Version , globalConfig .Version )
33
33
})
34
34
t .Run ("panic" , func (t * testing.T ) {
35
35
defer func () {
0 commit comments