Skip to content

Commit

Permalink
Revert "comment out broken test for now. Will revert whwen the fix ha…
Browse files Browse the repository at this point in the history
…s been released. (#413)" (#423)

This reverts commit 445ceca.
  • Loading branch information
Ben Lucas authored Sep 26, 2023
1 parent ae9e11f commit c637e28
Showing 1 changed file with 37 additions and 37 deletions.
74 changes: 37 additions & 37 deletions sysdig/resource_sysdig_monitor_cloud_account_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,42 +2,42 @@

package sysdig_test

// import (
// "github.com/draios/terraform-provider-sysdig/sysdig"
// "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
// "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema"
// "os"
// "testing"
// )
import (
"github.com/draios/terraform-provider-sysdig/sysdig"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema"
"os"
"testing"
)

// func TestCustomerProviderKeys(t *testing.T) {
// resource.Test(t, resource.TestCase{
// PreCheck: func() {
// if v := os.Getenv("SYSDIG_MONITOR_API_TOKEN"); v == "" {
// t.Fatal("SYSDIG_MONITOR_API_TOKEN must be set for acceptance tests")
// }
// },
// ProviderFactories: map[string]func() (*schema.Provider, error){
// "sysdig": func() (*schema.Provider, error) {
// return sysdig.Provider(), nil
// },
// },
// Steps: []resource.TestStep{
// {
// Config: monitorCustomerProviderKey(),
// ExpectNonEmptyPlan: true,
// },
// },
// })
// }
func TestCustomerProviderKeys(t *testing.T) {
resource.Test(t, resource.TestCase{
PreCheck: func() {
if v := os.Getenv("SYSDIG_MONITOR_API_TOKEN"); v == "" {
t.Fatal("SYSDIG_MONITOR_API_TOKEN must be set for acceptance tests")
}
},
ProviderFactories: map[string]func() (*schema.Provider, error){
"sysdig": func() (*schema.Provider, error) {
return sysdig.Provider(), nil
},
},
Steps: []resource.TestStep{
{
Config: monitorCustomerProviderKey(),
ExpectNonEmptyPlan: true,
},
},
})
}

// func monitorCustomerProviderKey() string {
// return `
// resource "sysdig_monitor_cloud_account" "provider" {
// cloud_provider = "GCP"
// integration_type = "API"
// account_id = "joe-test-project-372418"
// additional_options = "ewogICJ0eXBlIjogInNlcnZpY2VfYWNjb3VudCIsCiAgInByb2plY3RfaWQiOiAiam9lLXRlc3QtcHJvamVjdC0zNzI0MTgiLAogICJwcml2YXRlX2tleV9pZCI6ICI2MzVlMTk0ZGNkODI4MWU5ZWE1YWZlMmJjNjdlMGIwYjY0OGI2YTM4IiwKICAicHJpdmF0ZV9rZXkiOiAiLS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tXG5NSUlFdkFJQkFEQU5CZ2txaGtpRzl3MEJBUUVGQUFTQ0JLWXdnZ1NpQWdFQUFvSUJBUURkZlFrR0haN3d5Z3RKXG5kVnlKVHM5M3g5SldMeXQ4bTh2cHZNYzVzUDltMzRBQ1k0bTNNMGNxcE8yZWVkRTlWSURIeVR0Z25RZ3Fja2ZNXG5KTDlFZE9HQURHOEJlcFh5WmdiWjR2c2NvdDB4emFTTDRkQ3pvVDJqUEkvV3JEdFFaSGR4K1hOc0VpZFFzYjlQXG5qTndnN29DSE5XSkY3MXRNZCt3dUphejFMTlJOME5sRnU3b01BV3N0KzluQjIwS2FLZDZpTWY3Tlo1bko4N1lwXG5YV3hsM2RkSnRmV2RmTmgvSU1zZGhvSTBGMEhIMUIwdnBoOGl5L01kbDBsSExpeUNUdXVDS01PZ0NhNFRubENXXG5PcjJkaGJSSG5aV1ZtaXd4dVR4cllGRVRVeUZERDJiNVhjV3loQlh5ajJZNVpnVldqQWhmMlVyblJRTjJvMVVHXG44WVVBUzEwVEFnTUJBQUVDZ2dFQVF6MGJtYk14VnFrSGp5ZmxUVHZUS09wTkZPUGlBRVN0dlVvVmN4S2tIbDlZXG5WYUZSSkFBWnFUMERjL3BJUnFXYUtNeVN6WXd1ZC9CVWtvbFBWV0ZrT2NMTWlqYmtRWCt1c2NQQjl0b01hM3VoXG42ZU5HUDlvQnc4WDFacmJIbE9yREJpTXo0b21LVE9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20iCn0="
// }
// `
// }
func monitorCustomerProviderKey() string {
return `
resource "sysdig_monitor_cloud_account" "provider" {
cloud_provider = "GCP"
integration_type = "API"
account_id = "joe-test-project-372418"
additional_options = "ewogICJ0eXBlIjogInNlcnZpY2VfYWNjb3VudCIsCiAgInByb2plY3RfaWQiOiAiam9lLXRlc3QtcHJvamVjdC0zNzI0MTgiLAogICJwcml2YXRlX2tleV9pZCI6ICI2MzVlMTk0ZGNkODI4MWU5ZWE1YWZlMmJjNjdlMGIwYjY0OGI2YTM4IiwKICAicHJpdmF0ZV9rZXkiOiAiLS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tXG5NSUlFdkFJQkFEQU5CZ2txaGtpRzl3MEJBUUVGQUFTQ0JLWXdnZ1NpQWdFQUFvSUJBUURkZlFrR0haN3d5Z3RKXG5kVnlKVHM5M3g5SldMeXQ4bTh2cHZNYzVzUDltMzRBQ1k0bTNNMGNxcE8yZWVkRTlWSURIeVR0Z25RZ3Fja2ZNXG5KTDlFZE9HQURHOEJlcFh5WmdiWjR2c2NvdDB4emFTTDRkQ3pvVDJqUEkvV3JEdFFaSGR4K1hOc0VpZFFzYjlQXG5qTndnN29DSE5XSkY3MXRNZCt3dUphejFMTlJOME5sRnU3b01BV3N0KzluQjIwS2FLZDZpTWY3Tlo1bko4N1lwXG5YV3hsM2RkSnRmV2RmTmgvSU1zZGhvSTBGMEhIMUIwdnBoOGl5L01kbDBsSExpeUNUdXVDS01PZ0NhNFRubENXXG5PcjJkaGJSSG5aV1ZtaXd4dVR4cllGRVRVeUZERDJiNVhjV3loQlh5ajJZNVpnVldqQWhmMlVyblJRTjJvMVVHXG44WVVBUzEwVEFnTUJBQUVDZ2dFQVF6MGJtYk14VnFrSGp5ZmxUVHZUS09wTkZPUGlBRVN0dlVvVmN4S2tIbDlZXG5WYUZSSkFBWnFUMERjL3BJUnFXYUtNeVN6WXd1ZC9CVWtvbFBWV0ZrT2NMTWlqYmtRWCt1c2NQQjl0b01hM3VoX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