KCL: Fix unit test

Fix code bug for removing cyclic dependency and fix unit test.

Test:
hmake test

Change-Id: Ib4d4ba416d0133542e6459459ddf43079ff53ab8
This commit is contained in:
Tao Jiang 2018-04-13 14:26:56 -07:00
parent 425daf70ce
commit 1969713863
11 changed files with 26 additions and 34 deletions

View file

@ -19,5 +19,5 @@ func TestConfig(t *testing.T) {
WithRegionName("us-west-2")
assert.Equal(t, "appName", kclConfig.ApplicationName)
assert.Equal(t, "500", kclConfig.FailoverTimeMillis)
assert.Equal(t, 500, kclConfig.FailoverTimeMillis)
}

View file

@ -151,4 +151,3 @@ func (c *KinesisClientLibConfiguration) WithWorkerThreadPoolSize(n int) *Kinesis
c.WorkerThreadPoolSize = n
return c
}

View file

@ -1,11 +1,9 @@
package types
package interfaces
import (
"time"
ks "github.com/aws/aws-sdk-go/service/kinesis"
. "clientlibrary/interfaces"
)
const (

View file

@ -2,8 +2,6 @@ package interfaces
import (
ks "github.com/aws/aws-sdk-go/service/kinesis"
. "clientlibrary/types"
)
type (

View file

@ -1,9 +1,5 @@
package interfaces
import (
. "clientlibrary/types"
)
// IRecordProcessor is the interface for some callback functions invoked by KCL will
// The main task of using KCL is to provide implementation on IRecordProcessor interface.
// Note: This is exactly the same interface as Amazon KCL IRecordProcessor v2

View file

@ -1,4 +1,4 @@
package types
package interfaces
// ExtendedSequenceNumber represents a two-part sequence number for records aggregated by the Kinesis Producer Library.
//

View file

@ -1,7 +1,7 @@
package checkpoint
import (
. "clientlibrary/types"
. "clientlibrary/interfaces"
)
const (

View file

@ -1,7 +1,7 @@
package impl
import (
. "clientlibrary/types"
. "clientlibrary/interfaces"
)
// KinesisClientLease is a Lease subclass containing KinesisClientLibrary related fields for checkpoints.

View file

@ -14,6 +14,7 @@ local_go_pkgs() {
grep -Fv '/tmp/' | \
grep -Fv '/run/' | \
grep -Fv '/tests/' | \
sed -r 's|(.+)/[^/]+\.go$|\1|g' | \
sort -u
}