mirror of
https://github.com/letic/terraform-provider-google.git
synced 2024-07-08 19:18:30 +00:00
Use a unique key when running project_metadata_item import tests (#274)
CI runs tests concurrently and will interfere with each other with the current global key name.
This commit is contained in:
parent
28f8931f0b
commit
c6ae260d63
|
@ -3,17 +3,20 @@ package google
|
|||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/hashicorp/terraform/helper/acctest"
|
||||
"github.com/hashicorp/terraform/helper/resource"
|
||||
)
|
||||
|
||||
func TestAccComputeProjectMetadataItem_importBasic(t *testing.T) {
|
||||
key := "myKey" + acctest.RandString(10)
|
||||
|
||||
resource.Test(t, resource.TestCase{
|
||||
PreCheck: func() { testAccPreCheck(t) },
|
||||
Providers: testAccProviders,
|
||||
CheckDestroy: testAccCheckProjectMetadataItemDestroy,
|
||||
Steps: []resource.TestStep{
|
||||
{
|
||||
Config: testAccProjectMetadataItem_basic("myKey", "myValue"),
|
||||
Config: testAccProjectMetadataItem_basic(key, "myValue"),
|
||||
},
|
||||
{
|
||||
ResourceName: "google_compute_project_metadata_item.foobar",
|
||||
|
|
Loading…
Reference in New Issue
Block a user