Skip to content

Commit

Permalink
Add notion of integration vs unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
remingtonc committed May 22, 2019
1 parent 6761552 commit af33839
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 4 deletions.
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ BINARY=pipeline
include skeleton/pipeline.mk

# Setup pretest as a prerequisite of tests.
test: pretest
pretest:
@echo Setting up zookeeper, kafka. Docker required.
testall: pretestinfra
pretestinfra:
@echo Setting up Zookeeper and Kafka. Docker required.
tools/test/run.sh
4 changes: 4 additions & 0 deletions skeleton/pipeline.mk
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ bin/$(BINARY): $(SOURCES)
generated_source:
go generate -x

.PHONY: testall
testall:
go test -v -tags=integration -run=. -bench=. $(PROFILE)

.PHONY: test
test:
go test -v -run=. -bench=. $(PROFILE)
Expand Down
4 changes: 3 additions & 1 deletion xport_kafka_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,18 @@
// All rights reserved.
//
//
// +build integration

package main

import (
"encoding/json"
"fmt"
"github.com/dlintw/goconf"
"strings"
"testing"
"time"

"github.com/dlintw/goconf"
)

var kmod kafkaOutputModule
Expand Down

0 comments on commit af33839

Please sign in to comment.