diff --git a/artifacttest/README.md b/artifacttest/README.md new file mode 100644 index 0000000..305c52b --- /dev/null +++ b/artifacttest/README.md @@ -0,0 +1,3 @@ +# artifacttest + +Этот пакет содержит тесты на [artifact](../distbuild/pkg/artifact). diff --git a/distbuild/pkg/artifact/cache_test.go b/artifacttest/cache_test.go similarity index 98% rename from distbuild/pkg/artifact/cache_test.go rename to artifacttest/cache_test.go index b4a3801..69f2bf0 100644 --- a/distbuild/pkg/artifact/cache_test.go +++ b/artifacttest/cache_test.go @@ -1,4 +1,4 @@ -package artifact_test +package artifacttest import ( "errors" diff --git a/distbuild/pkg/artifact/client_test.go b/artifacttest/client_test.go similarity index 98% rename from distbuild/pkg/artifact/client_test.go rename to artifacttest/client_test.go index 92535a1..55b0222 100644 --- a/distbuild/pkg/artifact/client_test.go +++ b/artifacttest/client_test.go @@ -1,4 +1,4 @@ -package artifact_test +package artifacttest import ( "context" diff --git a/filecachetest/README.md b/filecachetest/README.md new file mode 100644 index 0000000..67c8f61 --- /dev/null +++ b/filecachetest/README.md @@ -0,0 +1,3 @@ +# filecachetest + +Этот пакет содержит тесты на [filecachetest](../distbuild/pkg/filecachetest). diff --git a/distbuild/pkg/filecache/client_test.go b/filecachetest/client_test.go similarity index 100% rename from distbuild/pkg/filecache/client_test.go rename to filecachetest/client_test.go diff --git a/distbuild/pkg/filecache/filecache_test.go b/filecachetest/filecache_test.go similarity index 100% rename from distbuild/pkg/filecache/filecache_test.go rename to filecachetest/filecache_test.go diff --git a/tarstreamtest/README.md b/tarstreamtest/README.md new file mode 100644 index 0000000..4bf67e6 --- /dev/null +++ b/tarstreamtest/README.md @@ -0,0 +1,3 @@ +# tarstreamtest + +Этот пакет содержит тесты на [tarstream](../distbuild/pkg/tarstream). diff --git a/distbuild/pkg/tarstream/stream_test.go b/tarstreamtest/stream_test.go similarity index 89% rename from distbuild/pkg/tarstream/stream_test.go rename to tarstreamtest/stream_test.go index 2a7c9e5..0f18ded 100644 --- a/distbuild/pkg/tarstream/stream_test.go +++ b/tarstreamtest/stream_test.go @@ -1,4 +1,4 @@ -package tarstream +package tarstreamtest import ( "bytes" @@ -8,6 +8,7 @@ import ( "testing" "github.com/stretchr/testify/require" + "gitlab.com/slon/shad-go/distbuild/pkg/tarstream" "golang.org/x/sys/unix" ) @@ -30,9 +31,9 @@ func TestTarStream(t *testing.T) { require.NoError(t, ioutil.WriteFile(filepath.Join(from, "a", "x.bin"), []byte("xxx"), 0777)) require.NoError(t, ioutil.WriteFile(filepath.Join(from, "b", "c", "y.txt"), []byte("yyy"), 0666)) - require.NoError(t, Send(from, &buf)) + require.NoError(t, tarstream.Send(from, &buf)) - require.NoError(t, Receive(to, &buf)) + require.NoError(t, tarstream.Receive(to, &buf)) checkDir := func(path string) { st, err := os.Stat(path)