2016-09-07 07:43:45 +02:00
|
|
|
package aws
|
|
|
|
|
|
|
|
import (
|
2016-09-08 05:51:31 +02:00
|
|
|
"testing"
|
2016-09-07 07:43:45 +02:00
|
|
|
|
2016-09-08 05:51:31 +02:00
|
|
|
"github.com/hashicorp/terraform/helper/resource"
|
2016-09-07 07:43:45 +02:00
|
|
|
)
|
|
|
|
|
|
|
|
func TestAccAWSBillingServiceAccount_basic(t *testing.T) {
|
2016-09-08 05:51:31 +02:00
|
|
|
resource.Test(t, resource.TestCase{
|
|
|
|
PreCheck: func() { testAccPreCheck(t) },
|
|
|
|
Providers: testAccProviders,
|
|
|
|
Steps: []resource.TestStep{
|
|
|
|
resource.TestStep{
|
|
|
|
Config: testAccCheckAwsBillingServiceAccountConfig,
|
|
|
|
Check: resource.ComposeTestCheckFunc(
|
|
|
|
resource.TestCheckResourceAttr("data.aws_billing_service_account.main", "id", "386209384616"),
|
|
|
|
resource.TestCheckResourceAttr("data.aws_billing_service_account.main", "arn", "arn:aws:iam::386209384616:root"),
|
|
|
|
),
|
|
|
|
},
|
|
|
|
},
|
|
|
|
})
|
2016-09-07 07:43:45 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
const testAccCheckAwsBillingServiceAccountConfig = `
|
|
|
|
data "aws_billing_service_account" "main" { }
|
|
|
|
`
|