package testutil
import "github.com/containerd/containerd/testutil"
Index ¶
- func DumpDir(t *testing.T, root string)
- func RequiresRoot(t testing.TB)
- func RequiresRootM()
- func Unmount(t *testing.T, mountPoint string)
Functions ¶
func DumpDir ¶
DumpDir will log out all of the contents of the provided directory to testing logger.
Use this in a defer statement within tests that may allocate and exercise a temporary directory. Immensely useful for sanity checking and debugging failing tests.
One should still test that contents are as expected. This is only a visual tool to assist when things don't go your way.
func RequiresRoot ¶
RequiresRoot does nothing on Windows
func RequiresRootM ¶
func RequiresRootM()
RequiresRootM is similar to RequiresRoot but intended to be called from *testing.M.
func Unmount ¶
Unmount unmounts a given mountPoint and sets t.Error if it fails Does nothing on Windows
Source Files ¶
- Version
- v1.0.3-rc.0
- Published
- Mar 29, 2018
- Platform
- windows/amd64
- Imports
- 7 packages
- Last checked
- 5 minutes ago –
Tools for package owners.