Example #1
0
func (s *AmazonServerSuite) SetUpSuite(c *gocheck.C) {
	if !*amazon {
		c.Skip("AmazonServerSuite tests not enabled")
	}
	s.srv.SetUp(c)
	s.ServerTests.elb = elb.New(s.srv.auth, aws.USEast)
}
Example #2
0
func (s *AmazonServerSuite) SetUpSuite(c *gocheck.C) {
	if !testutil.Amazon {
		c.Skip("AmazonServerSuite tests not enabled")
	}
	s.srv.SetUp(c)
	s.ServerTests.ec2 = ec2.NewWithClient(s.srv.auth, aws.USEast, testutil.DefaultClient)
}
Example #3
0
func (s *AmazonClientSuite) SetUpSuite(c *gocheck.C) {
	if !testutil.Amazon {
		c.Skip("AmazonClientSuite tests not enabled")
	}
	s.srv.SetUp(c)
	s.iam = iam.New(s.srv.auth, aws.USEast)
}
Example #4
0
func (s *AmazonClientSuite) SetUpSuite(c *gocheck.C) {
	if !*amazon {
		c.Skip("AmazonClientSuite tests not enabled")
	}
	s.srv.SetUp(c)
	s.elb = elb.New(s.srv.auth, aws.USEast)
	s.ec2 = ec2.New(s.srv.auth, aws.USEast)
}
Example #5
0
func (s *AmazonClientSuite) SetUpSuite(c *gocheck.C) {
	if !testutil.Amazon {
		c.Skip("live tests against AWS disabled (no -amazon)")
	}
	s.srv.SetUp(c)
	s.s3 = s3.New(s.srv.auth, s.Region)
	// In case tests were interrupted in the middle before.
	s.ClientTests.Cleanup()
}
Example #6
0
func (s *AmazonDomainClientSuite) SetUpSuite(c *gocheck.C) {
	if !testutil.Amazon {
		c.Skip("live tests against AWS disabled (no -amazon)")
	}
	s.srv.SetUp(c)
	region := s.Region
	region.S3BucketEndpoint = "https://${bucket}.s3.amazonaws.com"
	s.s3 = s3.New(s.srv.auth, region)
	s.ClientTests.Cleanup()
}
Example #7
0
func (s *LiveSuite) SetUpSuite(c *gocheck.C) {
	if !Amazon {
		c.Skip("amazon tests not enabled (-amazon flag)")
	}
	auth, err := aws.EnvAuth()
	if err != nil {
		c.Fatal(err.Error())
	}
	s.auth = auth
}
Example #8
0
func (s *SuiteI) SetUpSuite(c *gocheck.C) {
	if !*integration {
		c.Skip("Integration tests not enabled (-i flag)")
	}
	auth, err := aws.EnvAuth()
	if err != nil {
		c.Fatal(err.Error())
	}
	s.auth = auth
}
Example #9
0
func (s *TableSuite) SetUpSuite(c *gocheck.C) {
	setUpAuth(c)
	s.DynamoDBTest.TableDescriptionT = s.TableDescriptionT
	s.server = &dynamodb.Server{dynamodb_auth, dynamodb_region}
	pk, err := s.TableDescriptionT.BuildPrimaryKey()
	if err != nil {
		c.Skip(err.Error())
	}
	s.table = s.server.NewTable(s.TableDescriptionT.TableName, pk)

	// Cleanup
	s.TearDownSuite(c)
}
Example #10
0
func setUpAuth(c *gocheck.C) {
	if !*amazon {
		c.Skip("Test against amazon not enabled.")
	}
	if *local {
		c.Log("Using local server")
		dynamodb_region = aws.Region{DynamoDBEndpoint: "http://127.0.0.1:8000"}
		dynamodb_auth = aws.Auth{AccessKey: "DUMMY_KEY", SecretKey: "DUMMY_SECRET"}
	} else {
		c.Log("Using REAL AMAZON SERVER")
		dynamodb_region = aws.USEast
		auth, err := aws.EnvAuth()
		if err != nil {
			c.Fatal(err)
		}
		dynamodb_auth = auth
	}
}
Example #11
0
func (s *ItemSuite) SetUpSuite(c *gocheck.C) {
	setUpAuth(c)
	s.DynamoDBTest.TableDescriptionT = s.TableDescriptionT
	s.server = &dynamodb.Server{dynamodb_auth, dynamodb_region}
	pk, err := s.TableDescriptionT.BuildPrimaryKey()
	if err != nil {
		c.Skip(err.Error())
	}
	s.table = s.server.NewTable(s.TableDescriptionT.TableName, pk)

	// Cleanup
	s.TearDownSuite(c)
	_, err = s.server.CreateTable(s.TableDescriptionT)
	if err != nil {
		c.Fatal(err)
	}
	s.WaitUntilStatus(c, "ACTIVE")
}
Example #12
0
func (s *HandlerSuite) TestGetBuildersMustReturnListOfBuilders(c *gc.C) {
	c.Skip("todo: to make this test work, we will have to separate the 'buildbot' into a entitiy, and make it an interface, mockable, so we can mock the idea of request the list")
}
Example #13
0
func (s *HandlerSuite) TestGetSingleBuilderMustReturnBuilder(c *gc.C) {
	c.Skip("todo")
}
func (s *ContainerBagSuite) TestNewContainerShouldNotSetFilterForInvalidRegex(c *gc.C) {
	c.Skip("todo")
}
func (s *ContainerBagSuite) TestNewContainerShouldReturnProperHashedUrl(c *gc.C) {
	c.Skip("todo")
}
func (s *ContainerBagSuite) TestNewContainerBagMustInitializeComponentsIfConfigProvided(c *gc.C) {
	c.Skip("todo")
}
Example #17
0
func (s *CacheSuite) TestSetCacheShouldCreateFile(c *gc.C) {
	c.Skip("todo")
}
Example #18
0
func (s *HandlerSuite) TestIndexMustReturnOK(c *gc.C) {
	c.Skip("todo")
}
Example #19
0
func (s *CacheSuite) TestNonExistingKeyShouldReturnError(c *gc.C) {
	c.Skip("todo")
}
Example #20
0
func (s *CacheSuite) TestExpiredTimeShouldReturnError(c *gc.C) {
	c.Skip("todo")
}
Example #21
0
func (s *CacheSuite) TestExistingCacheShouldReturnData(c *gc.C) {
	c.Skip("todo")
}