1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Merge pull request #2087 from alexlarsson/device-mapper-test

Device mapper test branch update
This commit is contained in:
Victor Vieux 2013-10-04 07:54:43 -07:00
commit f6913592a1
3 changed files with 7 additions and 3 deletions

View file

@ -881,7 +881,6 @@ func (devices *DeviceSetDM) SetInitialized(hash string) error {
}
func (devices *DeviceSetDM) ensureInit() error {
utils.Debugf("ensureInit(). Initialized: %v", devices.initialized)
if !devices.initialized {
devices.initialized = true
if err := devices.initDevmapper(); err != nil {

View file

@ -11,7 +11,7 @@ bundle_test() {
for test_dir in $(find_test_dirs); do (
set -x
cd $test_dir
DEBUG=1 go test -v -ldflags "$LDFLAGS" $BUILDFLAGS -run TestRunHostname
DEBUG=1 go test -v -ldflags "$LDFLAGS" $BUILDFLAGS
) done
} 2>&1 | tee $DEST/test.log
}

View file

@ -147,8 +147,13 @@ func init() {
panic(err)
}
deviceset := devmapper.NewDeviceSetDM(unitTestStoreDevicesBase)
// Create a device, which triggers the initiation of the base FS
// This avoids other tests doing this and timing out
deviceset.AddDevice("init","")
// Make it our Store root
if runtime, err := NewRuntimeFromDirectory(unitTestStoreBase, devmapper.NewDeviceSetDM(unitTestStoreDevicesBase), false); err != nil {
if runtime, err := NewRuntimeFromDirectory(unitTestStoreBase, deviceset, false); err != nil {
panic(err)
} else {
globalRuntime = runtime