Skip to content

Commit

Permalink
azurerm_scheduler_job_collection: added import tests
Browse files Browse the repository at this point in the history
  • Loading branch information
katbyte committed May 9, 2018
1 parent f705ce1 commit cc2142e
Showing 1 changed file with 13 additions and 6 deletions.
19 changes: 13 additions & 6 deletions azurerm/resource_arm_scheduler_job_collection_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,40 +15,47 @@ import (
func TestAccAzureRMSchedulerJobCollection_basic(t *testing.T) {
ri := acctest.RandInt()
resourceName := "azurerm_scheduler_job_collection.test"
config := testAccAzureRMSchedulerJobCollection_basic(ri, testLocation(), "")

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t) },
Providers: testAccProviders,
CheckDestroy: testCheckAzureRMSchedulerJobCollectionDestroy,
Steps: []resource.TestStep{
{
Config: config,
Config: testAccAzureRMSchedulerJobCollection_basic(ri, testLocation(), ""),
Check: checkAccAzureRMSchedulerJobCollection_basic(resourceName),
},
{
ResourceName: resourceName,
ImportState: true,
ImportStateVerify: true,
},
},
})
}

func TestAccAzureRMSchedulerJobCollection_complete(t *testing.T) {
ri := acctest.RandInt()
resourceName := "azurerm_scheduler_job_collection.test"
preConfig := testAccAzureRMSchedulerJobCollection_basic(ri, testLocation(), "")
config := testAccAzureRMSchedulerJobCollection_complete(ri, testLocation())

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t) },
Providers: testAccProviders,
CheckDestroy: testCheckAzureRMSchedulerJobCollectionDestroy,
Steps: []resource.TestStep{
{
Config: preConfig,
Config: testAccAzureRMSchedulerJobCollection_basic(ri, testLocation(), ""),
Check: checkAccAzureRMSchedulerJobCollection_basic(resourceName),
},
{
Config: config,
Config: testAccAzureRMSchedulerJobCollection_complete(ri, testLocation()),
Check: checkAccAzureRMSchedulerJobCollection_complete(resourceName),
},
{
ResourceName: resourceName,
ImportState: true,
ImportStateVerify: true,
},
},
})
}
Expand Down

0 comments on commit cc2142e

Please sign in to comment.