move overlay-checks to an overlayutils package

This allows using the utilities without importing the whole
snapshotter.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn
2021-03-15 19:10:32 +01:00
parent a1138182d5
commit ba8f9845ec
5 changed files with 13 additions and 11 deletions

View File

@@ -31,7 +31,7 @@ import (
"github.com/containerd/containerd/log/logtest"
"github.com/containerd/containerd/mount"
"github.com/containerd/containerd/pkg/testutil"
"github.com/containerd/containerd/snapshots/overlay"
"github.com/containerd/containerd/snapshots/overlay/overlayutils"
"github.com/containerd/continuity/fs"
"github.com/containerd/continuity/fs/fstest"
"github.com/pkg/errors"
@@ -46,7 +46,7 @@ func TestOverlayApply(t *testing.T) {
}
defer os.RemoveAll(base)
if err := overlay.Supported(base); err != nil {
if err := overlayutils.Supported(base); err != nil {
t.Skipf("skipping because overlay is not supported %v", err)
}
fstest.FSSuite(t, overlayDiffApplier{
@@ -65,7 +65,7 @@ func TestOverlayApplyNoParents(t *testing.T) {
}
defer os.RemoveAll(base)
if err := overlay.Supported(base); err != nil {
if err := overlayutils.Supported(base); err != nil {
t.Skipf("skipping because overlay is not supported %v", err)
}
fstest.FSSuite(t, overlayDiffApplier{