func (s *ProviderSuite) SetUpSuite(c *C) { s.restoreTimeouts = envtesting.PatchAttemptStrategies(&shortAttempt) s.LoggingSuite.SetUpSuite(c) TestMAASObject := gomaasapi.NewTestMAAS("1.0") s.testMAASObject = TestMAASObject s.environ = &maasEnviron{name: "test env", maasClientUnlocked: &TestMAASObject.MAASObject} }
func (s *providerSuite) SetUpSuite(c *gc.C) { s.restoreTimeouts = envtesting.PatchAttemptStrategies(&shortAttempt) s.BaseSuite.SetUpSuite(c) TestMAASObject := gomaasapi.NewTestMAAS("1.0") s.testMAASObject = TestMAASObject restoreFinishBootstrap := envtesting.DisableFinishBootstrap() s.AddSuiteCleanup(func(*gc.C) { restoreFinishBootstrap() }) }
func (s *providerSuite) SetUpSuite(c *gc.C) { s.FakeJujuHomeSuite.SetUpSuite(c) restoreTimeouts := envtesting.PatchAttemptStrategies(&shortAttempt) TestMAASObject := gomaasapi.NewTestMAAS("1.0") s.testMAASObject = TestMAASObject restoreFinishBootstrap := envtesting.DisableFinishBootstrap() s.AddSuiteCleanup(func(*gc.C) { restoreFinishBootstrap() restoreTimeouts() }) s.PatchValue(&nodeDeploymentTimeout, func(*maasEnviron) time.Duration { return coretesting.ShortWait }) }
// TDOO: jam 2013-12-06 This is copied from the providerSuite which is in a // whitebox package maas. Either move that into a whitebox test so it can be // shared, or into a 'testing' package so we can use it here. func (s *environSuite) SetUpSuite(c *gc.C) { s.restoreTimeouts = envtesting.PatchAttemptStrategies(maas.ShortAttempt) s.BaseSuite.SetUpSuite(c) TestMAASObject := gomaasapi.NewTestMAAS("1.0") s.testMAASObject = TestMAASObject }