Skip to content

Commit

Permalink
test: run integration tests in parallel (#126)
Browse files Browse the repository at this point in the history
  • Loading branch information
ademekici committed Apr 3, 2024
1 parent 3239d0f commit 6e542f1
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion test/integration/integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import (

func Test_Should_Produce_Successfully(t *testing.T) {
// Given
t.Parallel()
topic := "produce-topic"
brokerAddress := "localhost:9092"

Expand All @@ -39,6 +40,7 @@ func Test_Should_Produce_Successfully(t *testing.T) {

func Test_Should_Batch_Produce_Successfully(t *testing.T) {
// Given
t.Parallel()
topic := "batch-produce-topic"
brokerAddress := "localhost:9092"

Expand Down Expand Up @@ -68,6 +70,7 @@ func Test_Should_Batch_Produce_Successfully(t *testing.T) {

func Test_Should_Consume_Message_Successfully(t *testing.T) {
// Given
t.Parallel()
topic := "topic"
consumerGroup := "topic-cg"
brokerAddress := "localhost:9092"
Expand Down Expand Up @@ -107,6 +110,7 @@ func Test_Should_Consume_Message_Successfully(t *testing.T) {

func Test_Should_Pause_And_Resume_Successfully(t *testing.T) {
// Given
t.Parallel()
topic := "pause-topic"
consumerGroup := "pause-topic-cg"
brokerAddress := "localhost:9092"
Expand Down Expand Up @@ -168,6 +172,7 @@ func Test_Should_Pause_And_Resume_Successfully(t *testing.T) {

func Test_Should_Batch_Consume_Messages_Successfully(t *testing.T) {
// Given
t.Parallel()
topic := "batch-topic"
consumerGroup := "batch-topic-cg"
brokerAddress := "localhost:9092"
Expand Down Expand Up @@ -217,11 +222,12 @@ func Test_Should_Batch_Consume_Messages_Successfully(t *testing.T) {

func Test_Should_Batch_Retry_Only_Failed_Messages_When_Transactional_Retry_Is_Disabled(t *testing.T) {
// Given
t.Parallel()
topic := "nontransactional-cronsumer-topic"
consumerGroup := "nontransactional-cronsumer-cg"
brokerAddress := "localhost:9092"

retryTopic := "retry-topic"
retryTopic := "nontransactional-retry-topic"

_, cleanUp := createTopicAndWriteMessages(t, topic, []segmentio.Message{
{Topic: topic, Partition: 0, Offset: 1, Key: []byte("1"), Value: []byte(`foo1`)},
Expand Down Expand Up @@ -274,6 +280,7 @@ func Test_Should_Batch_Retry_Only_Failed_Messages_When_Transactional_Retry_Is_Di

func Test_Should_Integrate_With_Kafka_Cronsumer_Successfully(t *testing.T) {
// Given
t.Parallel()
topic := "cronsumer-topic"
consumerGroup := "cronsumer-cg"
brokerAddress := "localhost:9092"
Expand Down Expand Up @@ -320,6 +327,7 @@ func Test_Should_Integrate_With_Kafka_Cronsumer_Successfully(t *testing.T) {

func Test_Should_Propagate_Custom_Headers_With_Kafka_Cronsumer_Successfully(t *testing.T) {
// Given
t.Parallel()
topic := "cronsumer-header-topic"
consumerGroup := "cronsumer-header-cg"
brokerAddress := "localhost:9092"
Expand Down Expand Up @@ -389,6 +397,7 @@ func Test_Should_Propagate_Custom_Headers_With_Kafka_Cronsumer_Successfully(t *t

func Test_Should_Batch_Consume_With_PreBatch_Enabled(t *testing.T) {
// Given
t.Parallel()
topic := "batch-topic-prebatch-enabled"
consumerGroup := "batch-topic-prebatch-cg"
brokerAddress := "localhost:9092"
Expand Down Expand Up @@ -442,6 +451,7 @@ func Test_Should_Batch_Consume_With_PreBatch_Enabled(t *testing.T) {

func Test_Should_Skip_Message_When_Header_Filter_Given(t *testing.T) {
// Given
t.Parallel()
topic := "header-filter-topic"
consumerGroup := "header-filter-cg"
brokerAddress := "localhost:9092"
Expand Down

0 comments on commit 6e542f1

Please sign in to comment.