@@ -25,12 +25,12 @@ func TestAccGithubOrganizationRole(t *testing.T) {
2525 Steps : []resource.TestStep {
2626 {
2727 Config : config ,
28- Check : resource .ComposeTestCheckFunc (
28+ Check : resource .ComposeAggregateTestCheckFunc (
2929 resource .TestCheckResourceAttrSet ("github_organization_role.test" , "id" ),
3030 resource .TestCheckResourceAttrSet ("github_organization_role.test" , "role_id" ),
3131 resource .TestCheckResourceAttr ("github_organization_role.test" , "name" , name ),
3232 resource .TestCheckResourceAttr ("github_organization_role.test" , "base_role" , "none" ),
33- resource .TestCheckResourceAttrSet ("github_organization_role.test" , "permissions.# " ),
33+ resource .TestCheckNoResourceAttr ("github_organization_role.test" , "permissions" ),
3434 resource .TestCheckResourceAttr ("github_organization_role.test" , "permissions.#" , "0" ),
3535 ),
3636 },
@@ -57,11 +57,11 @@ func TestAccGithubOrganizationRole(t *testing.T) {
5757 Steps : []resource.TestStep {
5858 {
5959 Config : config ,
60- Check : resource .ComposeTestCheckFunc (
60+ Check : resource .ComposeAggregateTestCheckFunc (
6161 resource .TestCheckResourceAttrSet ("github_organization_role.test" , "id" ),
6262 resource .TestCheckResourceAttr ("github_organization_role.test" , "name" , name ),
6363 resource .TestCheckResourceAttr ("github_organization_role.test" , "base_role" , baseRole ),
64- resource .TestCheckResourceAttrSet ("github_organization_role.test" , "permissions.# " ),
64+ resource .TestCheckNoResourceAttr ("github_organization_role.test" , "permissions" ),
6565 resource .TestCheckResourceAttr ("github_organization_role.test" , "permissions.#" , "0" ),
6666 ),
6767 },
@@ -167,16 +167,16 @@ func TestAccGithubOrganizationRole(t *testing.T) {
167167 Steps : []resource.TestStep {
168168 {
169169 Config : config ,
170- Check : resource .ComposeTestCheckFunc (
170+ Check : resource .ComposeAggregateTestCheckFunc (
171171 resource .TestCheckResourceAttrSet ("github_organization_role.test" , "id" ),
172172 resource .TestCheckResourceAttrSet ("github_organization_role.test" , "role_id" ),
173173 resource .TestCheckResourceAttr ("github_organization_role.test" , "name" , name ),
174174 resource .TestCheckResourceAttr ("github_organization_role.test" , "description" , description ),
175175 resource .TestCheckResourceAttr ("github_organization_role.test" , "base_role" , baseRole ),
176176 resource .TestCheckResourceAttrSet ("github_organization_role.test" , "permissions.#" ),
177177 resource .TestCheckResourceAttr ("github_organization_role.test" , "permissions.#" , "2" ),
178- resource .TestCheckResourceAttr ("github_organization_role.test" , "permissions.0 " , permission0 ),
179- resource .TestCheckResourceAttr ("github_organization_role.test" , "permissions.1 " , permission1 ),
178+ resource .TestCheckTypeSetElemAttr ("github_organization_role.test" , "permissions.* " , permission0 ),
179+ resource .TestCheckTypeSetElemAttr ("github_organization_role.test" , "permissions.* " , permission1 ),
180180 ),
181181 },
182182 },
0 commit comments