Skip to content

Commit ae54b37

Browse files
committed
tests/data-source/aws_organizations_organization: Add Organizations PreCheck
For consistency with other Organizations testing and to prevent the following failure: ``` --- FAIL: TestAccAWSOrganizations/Organization/DataSource (3.55s) testing.go:568: Step 0 error: errors during apply: Error: Error creating organization: AlreadyInOrganizationException: The AWS account is already a member of an organization. ``` Acceptance testing from Organizations member account: ``` --- SKIP: TestAccAWSOrganizations/Organization/DataSource (1.57s) provider_test.go:247: skipping tests; this AWS account must not be an existing member of an AWS Organization ``` Acceptance testing from standalone account: ``` --- PASS: TestAccAWSOrganizations/Organization/DataSource (29.70s) ```
1 parent 5f9aaa4 commit ae54b37

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

aws/data_source_aws_organizations_organization_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ func testAccDataSourceAwsOrganizationsOrganization_basic(t *testing.T) {
1313
resource.Test(t, resource.TestCase{
1414
PreCheck: func() {
1515
testAccPreCheck(t)
16+
testAccOrganizationsAccountPreCheck(t)
1617
},
1718
Providers: testAccProviders,
1819
Steps: []resource.TestStep{

0 commit comments

Comments
 (0)