diff --git a/client/cloud_credentials.go b/client/cloud_credentials.go index 8e174379..bf175448 100644 --- a/client/cloud_credentials.go +++ b/client/cloud_credentials.go @@ -5,7 +5,7 @@ import "strings" type AwsCredentialsType string type GcpCredentialsType string type AzureCredentialsType string -type VaultCrednetialsType string +type VaultCredentialsType string type Credentials struct { Id string `json:"id"` @@ -92,7 +92,7 @@ type VaultCredentialsValuePayload struct { type VaultCredentialsCreatePayload struct { Name string `json:"name,omitempty"` OrganizationId string `json:"organizationId,omitempty"` - Type VaultCrednetialsType `json:"type"` + Type VaultCredentialsType `json:"type"` Value VaultCredentialsValuePayload `json:"value"` } @@ -127,7 +127,7 @@ const ( AzureCostCredentialsType AzureCredentialsType = "AZURE_CREDENTIALS" AzureServicePrincipalCredentialsType AzureCredentialsType = "AZURE_SERVICE_PRINCIPAL_FOR_DEPLOYMENT" AzureOidcCredentialsType AzureCredentialsType = "AZURE_OIDC" - VaultOidcCredentialsType VaultCrednetialsType = "VAULT_OIDC" + VaultOidcCredentialsType VaultCredentialsType = "VAULT_OIDC" ) func (client *ApiClient) CloudCredentials(id string) (Credentials, error) { diff --git a/client/cloud_credentials_project_assignment_test.go b/client/cloud_credentials_project_assignment_test.go index ce0752f0..4b677c33 100644 --- a/client/cloud_credentials_project_assignment_test.go +++ b/client/cloud_credentials_project_assignment_test.go @@ -15,7 +15,7 @@ var _ = Describe("Credentials Project Assignment", func() { Describe("AssignCloudCredentialsToProject", func() { expectedResponse := CloudCredentialsProjectAssignment{ - Id: "assigment id", + Id: "assignment id", CredentialId: "credentialId", ProjectId: projectId, } diff --git a/client/cost_credentials_project_assignment_test.go b/client/cost_credentials_project_assignment_test.go index af015a15..0e0e4ea2 100644 --- a/client/cost_credentials_project_assignment_test.go +++ b/client/cost_credentials_project_assignment_test.go @@ -15,7 +15,7 @@ var _ = Describe(" Cost Credentials Project Assignment", func() { Describe("AssignCostCredentialsToProject", func() { expectedResponse := CostCredentialProjectAssignment{ - ProjectId: "assigment id", + ProjectId: "assignment id", CredentialsId: "credentialId", CredentialsType: "GCP_CREDENTIALS", } @@ -79,13 +79,13 @@ var _ = Describe(" Cost Credentials Project Assignment", func() { var actualResult []CostCredentialProjectAssignment firstResulteResponse := CostCredentialProjectAssignment{ - ProjectId: "assigment id", + ProjectId: "assignment id", CredentialsId: "credentialId", CredentialsType: "GCP_CREDENTIALS", } secondResulteResponse := CostCredentialProjectAssignment{ - ProjectId: "assigment id", + ProjectId: "assignment id", CredentialsId: "credentialId-2", CredentialsType: "GCP_CREDENTIALS", } diff --git a/client/custom_flow.go b/client/custom_flow.go index 17fe6a8c..b1286476 100644 --- a/client/custom_flow.go +++ b/client/custom_flow.go @@ -54,7 +54,7 @@ func (client *ApiClient) CustomFlowCreate(payload CustomFlowCreatePayload) (*Cus return nil, err } - payloadWithOrganzationId := struct { + payloadWithOrganizationId := struct { OrganizationId string `json:"organizationId"` CustomFlowCreatePayload }{ @@ -63,7 +63,7 @@ func (client *ApiClient) CustomFlowCreate(payload CustomFlowCreatePayload) (*Cus } var result CustomFlow - if err := client.http.Post("/custom-flow", &payloadWithOrganzationId, &result); err != nil { + if err := client.http.Post("/custom-flow", &payloadWithOrganizationId, &result); err != nil { return nil, err } diff --git a/client/gpg_key.go b/client/gpg_key.go index ac9eb897..1ad6ef02 100644 --- a/client/gpg_key.go +++ b/client/gpg_key.go @@ -21,7 +21,7 @@ func (client *ApiClient) GpgKeyCreate(payload *GpgKeyCreatePayload) (*GpgKey, er return nil, err } - payloadWithOrganzationId := struct { + payloadWithOrganizationId := struct { OrganizationId string `json:"organizationId"` GpgKeyCreatePayload }{ @@ -30,7 +30,7 @@ func (client *ApiClient) GpgKeyCreate(payload *GpgKeyCreatePayload) (*GpgKey, er } var result GpgKey - if err := client.http.Post("/gpg-keys", payloadWithOrganzationId, &result); err != nil { + if err := client.http.Post("/gpg-keys", payloadWithOrganizationId, &result); err != nil { return nil, err } diff --git a/client/kubernetes_credentials.go b/client/kubernetes_credentials.go index 62331b96..1365f413 100644 --- a/client/kubernetes_credentials.go +++ b/client/kubernetes_credentials.go @@ -1,22 +1,22 @@ package client -type KubernetesCrednetialsType string +type KubernetesCredentialsType string const ( - KubeconfigCredentialsType KubernetesCrednetialsType = "K8S_KUBECONFIG_FILE" - AwsEksCredentialsType KubernetesCrednetialsType = "K8S_EKS_AUTH" - AzureAksCredentialsType KubernetesCrednetialsType = "K8S_AZURE_AKS_AUTH" - GcpGkeCredentialsType KubernetesCrednetialsType = "K8S_GCP_GKE_AUTH" + KubeconfigCredentialsType KubernetesCredentialsType = "K8S_KUBECONFIG_FILE" + AwsEksCredentialsType KubernetesCredentialsType = "K8S_EKS_AUTH" + AzureAksCredentialsType KubernetesCredentialsType = "K8S_AZURE_AKS_AUTH" + GcpGkeCredentialsType KubernetesCredentialsType = "K8S_GCP_GKE_AUTH" ) type KubernetesCredentialsCreatePayload struct { Name string `json:"name"` - Type KubernetesCrednetialsType `json:"type"` + Type KubernetesCredentialsType `json:"type"` Value interface{} `json:"value"` } type KubernetesCredentialsUpdatePayload struct { - Type KubernetesCrednetialsType `json:"type"` + Type KubernetesCredentialsType `json:"type"` Value interface{} `json:"value"` } diff --git a/client/sshkey_test.go b/client/sshkey_test.go index 606c777c..5a608dbf 100644 --- a/client/sshkey_test.go +++ b/client/sshkey_test.go @@ -81,7 +81,7 @@ var _ = Describe("SshKey", func() { }) }) - Describe("SshKetUpdate", func() { + Describe("SshKeyUpdate", func() { Describe("Success", func() { updateMockSshKey := mockSshKey updateMockSshKey.Value = "new-value" diff --git a/docs/data-sources/project.md b/docs/data-sources/project.md index c48183fa..92703f1c 100644 --- a/docs/data-sources/project.md +++ b/docs/data-sources/project.md @@ -19,12 +19,12 @@ data "env0_project" "default_project" { data "env0_project" "with_parent_name_filter" { name = "Default Organization Project" - parent_project_name = "parent projet name" + parent_project_name = "parent project name" } data "env0_project" "with_parent_id_filter" { name = "Default Organization Project" - parent_project_id = "parent-projet-id" + parent_project_id = "parent-project-id" } ``` diff --git a/docs/data-sources/user.md b/docs/data-sources/user.md index 0f6f5616..61195b98 100644 --- a/docs/data-sources/user.md +++ b/docs/data-sources/user.md @@ -18,7 +18,7 @@ data "env0_user" "user_by_email_example" { } output "user_id" { - value = data.env0_user.user_by_email_exmple.id + value = data.env0_user.user_by_email_example.id } ``` diff --git a/docs/resources/agent_project_assignment.md b/docs/resources/agent_project_assignment.md index 03a631d8..9d53c68c 100644 --- a/docs/resources/agent_project_assignment.md +++ b/docs/resources/agent_project_assignment.md @@ -43,5 +43,5 @@ resource "env0_agent_project_assignment" "example" { Import is supported using the following syntax: ```shell -terraform import env0_agent_project_assigment.example project_id +terraform import env0_agent_project_assignment.example project_id ``` diff --git a/docs/resources/custom_role.md b/docs/resources/custom_role.md index f4202c63..cbb64b9f 100644 --- a/docs/resources/custom_role.md +++ b/docs/resources/custom_role.md @@ -44,5 +44,5 @@ Import is supported using the following syntax: ```shell terraform import env0_custom_role.by_id ddda7b30-6789-4d24-937c-22322754934e -terraform import env0_cusom_role.by_name "custom-role-name" +terraform import env0_custom_role.by_name "custom-role-name" ``` diff --git a/docs/resources/environment.md b/docs/resources/environment.md index 3e0b716f..de19e348 100644 --- a/docs/resources/environment.md +++ b/docs/resources/environment.md @@ -128,7 +128,7 @@ Optional: - `approve_plan_automatically` (Boolean) when 'true' (default) plans are approved automatically, otherwise ('false') deployment require manual approval - `configuration` (Block List) sub environment configuration variables. Note: do not use with 'env0_configuration_variable' resource (see [below for nested schema](#nestedblock--sub_environment_configuration--configuration)) -- `workspace` (String) sub environment workspace (overrides the configurtion in the yml file) +- `workspace` (String) sub environment workspace (overrides the configuration in the yml file) Read-Only: diff --git a/docs/resources/user_team_assignment.md b/docs/resources/user_team_assignment.md index 4de0378d..1cbcb2e1 100644 --- a/docs/resources/user_team_assignment.md +++ b/docs/resources/user_team_assignment.md @@ -21,7 +21,7 @@ resource "env0_team" "team_example" { name = "team-example" } -resource "env0_user_team_assignment" "assginment_example" { +resource "env0_user_team_assignment" "assignment_example" { user_id = data.env0_user.user_example.id team_id = env0_team.team_example.id } diff --git a/env0/credentials.go b/env0/credentials.go index abcd3f83..cd909bf7 100644 --- a/env0/credentials.go +++ b/env0/credentials.go @@ -88,7 +88,7 @@ func getCredentialsById(id string, prefixList []string, meta interface{}) (clien } if !credentials.HasPrefix(prefixList) { - return client.Credentials{}, fmt.Errorf("credentials type mistmatch %s", credentials.Type) + return client.Credentials{}, fmt.Errorf("credentials type mismatch %s", credentials.Type) } return credentials, nil diff --git a/env0/data_kubernetes_credentials.go b/env0/data_kubernetes_credentials.go index 76d1079f..d9344f13 100644 --- a/env0/data_kubernetes_credentials.go +++ b/env0/data_kubernetes_credentials.go @@ -11,7 +11,7 @@ import ( func dataKubernetesCredentials(credentialsType CloudType) *schema.Resource { return &schema.Resource{ - ReadContext: dataKuberentesCredentialsRead(credentialsType), + ReadContext: dataKubernetesCredentialsRead(credentialsType), Schema: map[string]*schema.Schema{ "name": { @@ -30,7 +30,7 @@ func dataKubernetesCredentials(credentialsType CloudType) *schema.Resource { } } -func dataKuberentesCredentialsRead(credentialsType CloudType) func(ctx context.Context, d *schema.ResourceData, meta interface{}) diag.Diagnostics { +func dataKubernetesCredentialsRead(credentialsType CloudType) func(ctx context.Context, d *schema.ResourceData, meta interface{}) diag.Diagnostics { return func(ctx context.Context, d *schema.ResourceData, meta interface{}) diag.Diagnostics { var credentials client.Credentials diff --git a/env0/resource_aws_credentials.go b/env0/resource_aws_credentials.go index 21972455..d2b7651c 100644 --- a/env0/resource_aws_credentials.go +++ b/env0/resource_aws_credentials.go @@ -65,7 +65,7 @@ func resourceAwsCredentialsCreate(ctx context.Context, d *schema.ResourceData, m _, arnExist := d.GetOk("arn") if !accessKeyExist && !arnExist { - // Due to "import" must be inforced here and not in the schema level. + // Due to "import" must be enforced here and not in the schema level. // This fields are only available during creation (will not be returned in read or import). return diag.Errorf("one of `access_key_id,arn` must be specified") } diff --git a/env0/resource_configuration_variable_test.go b/env0/resource_configuration_variable_test.go index 8b23a780..5fe0dd08 100644 --- a/env0/resource_configuration_variable_test.go +++ b/env0/resource_configuration_variable_test.go @@ -77,7 +77,7 @@ func TestUnitConfigurationVariableResource(t *testing.T) { }) t.Run("Create sensitive", func(t *testing.T) { - createSenstiveConfig := client.ConfigurationVariableCreateParams{ + createSensitiveConfig := client.ConfigurationVariableCreateParams{ Name: "name", Value: "value", IsSensitive: true, @@ -86,7 +86,7 @@ func TestUnitConfigurationVariableResource(t *testing.T) { sensitiveConfig := client.ConfigurationVariable{ Id: uuid.NewString(), - Name: createSenstiveConfig.Name, + Name: createSensitiveConfig.Name, Value: "*", IsSensitive: boolPtr(true), Scope: client.ScopeGlobal, @@ -96,14 +96,14 @@ func TestUnitConfigurationVariableResource(t *testing.T) { Steps: []resource.TestStep{ { Config: resourceConfigCreate(resourceType, resourceName, map[string]interface{}{ - "name": createSenstiveConfig.Name, - "value": createSenstiveConfig.Value, + "name": createSensitiveConfig.Name, + "value": createSensitiveConfig.Value, "is_sensitive": true, }), Check: resource.ComposeAggregateTestCheckFunc( resource.TestCheckResourceAttr(accessor, "id", sensitiveConfig.Id), - resource.TestCheckResourceAttr(accessor, "name", createSenstiveConfig.Name), - resource.TestCheckResourceAttr(accessor, "value", createSenstiveConfig.Value), + resource.TestCheckResourceAttr(accessor, "name", createSensitiveConfig.Name), + resource.TestCheckResourceAttr(accessor, "value", createSensitiveConfig.Value), resource.TestCheckResourceAttr(accessor, "is_sensitive", strconv.FormatBool(true)), ), }, @@ -111,7 +111,7 @@ func TestUnitConfigurationVariableResource(t *testing.T) { } runUnitTest(t, createTestCase, func(mock *client.MockApiClientInterface) { - mock.EXPECT().ConfigurationVariableCreate(createSenstiveConfig).Times(1).Return(sensitiveConfig, nil) + mock.EXPECT().ConfigurationVariableCreate(createSensitiveConfig).Times(1).Return(sensitiveConfig, nil) mock.EXPECT().ConfigurationVariablesById(sensitiveConfig.Id).Times(1).Return(sensitiveConfig, nil) mock.EXPECT().ConfigurationVariableDelete(sensitiveConfig.Id).Times(1).Return(nil) }) @@ -648,7 +648,7 @@ resource "%s" "test" { IsRequired: &isRequired, Scope: "BLUEPRINT", } - stepConfirImport := resourceConfigCreate(resourceType, resourceName, map[string]interface{}{ + stepConfigImport := resourceConfigCreate(resourceType, resourceName, map[string]interface{}{ "name": configVarImport.Name, "description": configVarImport.Description, @@ -676,7 +676,7 @@ resource "%s" "test" { createTestCaseForImport := resource.TestCase{ Steps: []resource.TestStep{ { - Config: stepConfirImport, + Config: stepConfigImport, }, { ResourceName: ResourceNameImport, @@ -700,7 +700,7 @@ resource "%s" "test" { createTestCaseForImport := resource.TestCase{ Steps: []resource.TestStep{ { - Config: stepConfirImport, + Config: stepConfigImport, }, { ResourceName: ResourceNameImport, diff --git a/env0/resource_environment.go b/env0/resource_environment.go index dc33e545..e4abe039 100644 --- a/env0/resource_environment.go +++ b/env0/resource_environment.go @@ -323,7 +323,7 @@ func resourceEnvironment() *schema.Resource { }, "workspace": { Type: schema.TypeString, - Description: "sub environment workspace (overrides the configurtion in the yml file)", + Description: "sub environment workspace (overrides the configuration in the yml file)", Optional: true, }, "configuration": { @@ -922,15 +922,15 @@ func resourceEnvironmentDelete(ctx context.Context, d *schema.ResourceData, meta } func waitForEnvironmentDestroy(ctx context.Context, apiClient client.ApiClientInterface, deploymentId string) error { - waitInteval := time.Second * 10 + waitInterval := time.Second * 10 timeout := time.Minute * 30 if os.Getenv("TF_ACC") == "1" { // For acceptance tests reducing interval to 1 second and timeout to 10 seconds. - waitInteval = time.Second + waitInterval = time.Second timeout = time.Second * 10 } - ticker := time.NewTicker(waitInteval) // When invoked - check the status. + ticker := time.NewTicker(waitInterval) // When invoked - check the status. timer := time.NewTimer(timeout) // When invoked - timeout. results := make(chan error) diff --git a/env0/resource_environment_test.go b/env0/resource_environment_test.go index 3c6122fe..2c298efc 100644 --- a/env0/resource_environment_test.go +++ b/env0/resource_environment_test.go @@ -3069,8 +3069,8 @@ func TestUnitEnvironmentWithSubEnvironment(t *testing.T) { updatedSubEnvironment.Workspace = "workspace2" - subEnvrionmentWithId := subEnvironment - subEnvrionmentWithId.Id = workflowSubEnvironment.EnvironmentId + subEnvironmentWithId := subEnvironment + subEnvironmentWithId.Id = workflowSubEnvironment.EnvironmentId environment := client.Environment{ Id: "id", @@ -3290,7 +3290,7 @@ func TestUnitEnvironmentWithSubEnvironment(t *testing.T) { mock.EXPECT().ConfigurationVariablesByScope(client.ScopeWorkflow, environment.Id).Times(1).Return(client.ConfigurationChanges{configurationVariable}, nil), mock.EXPECT().ConfigurationSetsAssignments("ENVIRONMENT", environment.Id).Times(1).Return(nil, nil), mock.EXPECT().ConfigurationSetsAssignments("ENVIRONMENT", environment.Id).Times(1).Return(nil, nil), - mock.EXPECT().ConfigurationVariablesByScope(client.ScopeEnvironment, subEnvrionmentWithId.Id).Times(1).Return(subEnvironment.Configuration, nil), + mock.EXPECT().ConfigurationVariablesByScope(client.ScopeEnvironment, subEnvironmentWithId.Id).Times(1).Return(subEnvironment.Configuration, nil), mock.EXPECT().EnvironmentDeploy(environment.Id, deployRequest).Times(1).Return(client.EnvironmentDeployResponse{ Id: environment.Id, }, nil), diff --git a/env0/resource_module.go b/env0/resource_module.go index fc29a91e..25cf23d9 100644 --- a/env0/resource_module.go +++ b/env0/resource_module.go @@ -12,7 +12,7 @@ import ( ) func resourceModule() *schema.Resource { - vcsExcatlyOneOf := []string{ + vcsExactlyOneOf := []string{ "token_id", "github_installation_id", "bitbucket_client_key", @@ -53,7 +53,7 @@ func resourceModule() *schema.Resource { Type: schema.TypeString, Description: "the git token id to be used", Optional: true, - ExactlyOneOf: vcsExcatlyOneOf, + ExactlyOneOf: vcsExactlyOneOf, }, "token_name": { Type: schema.TypeString, @@ -65,13 +65,13 @@ func resourceModule() *schema.Resource { Type: schema.TypeInt, Description: "the env0 application installation id on the relevant Github repository", Optional: true, - ExactlyOneOf: vcsExcatlyOneOf, + ExactlyOneOf: vcsExactlyOneOf, }, "bitbucket_client_key": { Type: schema.TypeString, Description: "the client key used for integration with Bitbucket", Optional: true, - ExactlyOneOf: vcsExcatlyOneOf, + ExactlyOneOf: vcsExactlyOneOf, }, "ssh_keys": { Type: schema.TypeList, diff --git a/env0/resource_notification.go b/env0/resource_notification.go index 2cd075e3..992de8f5 100644 --- a/env0/resource_notification.go +++ b/env0/resource_notification.go @@ -186,11 +186,11 @@ func resourceNotificationDelete(ctx context.Context, d *schema.ResourceData, met func getNotification(ctx context.Context, id string, meta interface{}) (*client.Notification, error) { _, err := uuid.Parse(id) if err == nil { - tflog.Info(ctx, "Resolving notifcation by id", map[string]interface{}{"id": id}) + tflog.Info(ctx, "Resolving notification by id", map[string]interface{}{"id": id}) return getNotificationById(id, meta) } else { - tflog.Info(ctx, "Resolving notifcation by name", map[string]interface{}{"name ": id}) + tflog.Info(ctx, "Resolving notification by name", map[string]interface{}{"name ": id}) return getNotificationByName(id, meta) } diff --git a/env0/resource_project.go b/env0/resource_project.go index 4158f661..c9d6806b 100644 --- a/env0/resource_project.go +++ b/env0/resource_project.go @@ -164,12 +164,12 @@ func resourceProjectDelete(ctx context.Context, d *schema.ResourceData, meta int id := d.Id() if d.Get("wait").(bool) { - waitInteval := PROJECT_DESTROY_WAIT_INTERVAL + waitInterval := PROJECT_DESTROY_WAIT_INTERVAL if os.Getenv("TF_ACC") == "1" { // For acceptance tests. - waitInteval = time.Second + waitInterval = time.Second } - ticker := time.NewTicker(waitInteval) // When invoked check if project can be deleted. + ticker := time.NewTicker(waitInterval) // When invoked check if project can be deleted. timer := time.NewTimer(PROJECT_DESTROY_TOTAL_WAIT_TIME) // When invoked wait time has elapsed. done := make(chan bool) diff --git a/env0/utils.go b/env0/utils.go index 40b9f5b5..1916b8d2 100644 --- a/env0/utils.go +++ b/env0/utils.go @@ -237,7 +237,7 @@ func getFieldName(field reflect.StructField) *parsedField { var res parsedField // Assumes golang is CamalCase and Terraform is snake_case. - // This behavior can be overrided be used in the 'tfschema' tag. + // This behavior can be overridden be used in the 'tfschema' tag. res.name = toSnakeCase(field.Name) if tag, ok := field.Tag.Lookup("tfschema"); ok { diff --git a/examples/data-sources/env0_project/data-source.tf b/examples/data-sources/env0_project/data-source.tf index c2d0ad7c..601361b9 100644 --- a/examples/data-sources/env0_project/data-source.tf +++ b/examples/data-sources/env0_project/data-source.tf @@ -4,10 +4,10 @@ data "env0_project" "default_project" { data "env0_project" "with_parent_name_filter" { name = "Default Organization Project" - parent_project_name = "parent projet name" + parent_project_name = "parent project name" } data "env0_project" "with_parent_id_filter" { name = "Default Organization Project" - parent_project_id = "parent-projet-id" + parent_project_id = "parent-project-id" } diff --git a/examples/data-sources/env0_user/data-source.tf b/examples/data-sources/env0_user/data-source.tf index e7e86697..c0106dbc 100644 --- a/examples/data-sources/env0_user/data-source.tf +++ b/examples/data-sources/env0_user/data-source.tf @@ -3,5 +3,5 @@ data "env0_user" "user_by_email_example" { } output "user_id" { - value = data.env0_user.user_by_email_exmple.id + value = data.env0_user.user_by_email_example.id } diff --git a/examples/resources/env0_agent_project_assignment/import.sh b/examples/resources/env0_agent_project_assignment/import.sh index e1ba6454..fe333267 100644 --- a/examples/resources/env0_agent_project_assignment/import.sh +++ b/examples/resources/env0_agent_project_assignment/import.sh @@ -1 +1 @@ -terraform import env0_agent_project_assigment.example project_id \ No newline at end of file +terraform import env0_agent_project_assignment.example project_id \ No newline at end of file diff --git a/examples/resources/env0_custom_role/import.sh b/examples/resources/env0_custom_role/import.sh index f31451ea..fecf6578 100644 --- a/examples/resources/env0_custom_role/import.sh +++ b/examples/resources/env0_custom_role/import.sh @@ -1,2 +1,2 @@ terraform import env0_custom_role.by_id ddda7b30-6789-4d24-937c-22322754934e -terraform import env0_cusom_role.by_name "custom-role-name" +terraform import env0_custom_role.by_name "custom-role-name" diff --git a/examples/resources/env0_user_team_assignment/resource.tf b/examples/resources/env0_user_team_assignment/resource.tf index a068dc19..bc05815f 100644 --- a/examples/resources/env0_user_team_assignment/resource.tf +++ b/examples/resources/env0_user_team_assignment/resource.tf @@ -6,7 +6,7 @@ resource "env0_team" "team_example" { name = "team-example" } -resource "env0_user_team_assignment" "assginment_example" { +resource "env0_user_team_assignment" "assignment_example" { user_id = data.env0_user.user_example.id team_id = env0_team.team_example.id } diff --git a/tests/harness.go b/tests/harness.go index af4c583a..7f54b18f 100644 --- a/tests/harness.go +++ b/tests/harness.go @@ -39,7 +39,7 @@ func main() { go func(testName string) { if destroyMode == "DESTROY_ONLY" { - terraformDestory(testName) + terraformDestroy(testName) } else { success, err := runTest(testName, destroyMode != "NO_DESTROY") if !success { @@ -87,7 +87,7 @@ func runTest(testName string, destroy bool) (bool, error) { _, _ = terraformCommand(testName, "fmt") if destroy { - defer terraformDestory(testName) + defer terraformDestroy(testName) } _, err = terraformCommand(testName, "apply", "-auto-approve", "-var", "second_run=0") @@ -182,7 +182,7 @@ func bytesOfJsonToStringMap(data []byte) (map[string]string, error) { return result, nil } -func terraformDestory(testName string) { +func terraformDestroy(testName string) { log.Println("Running destroy to clean up in", testName) destroy := exec.Command("tofu", "destroy", "-auto-approve", "-var", "second_run=0") diff --git a/tests/integration/008_cloud_credentials_project_assignment/main.tf b/tests/integration/008_cloud_credentials_project_assignment/main.tf index 34a6a5c8..131cf1b0 100644 --- a/tests/integration/008_cloud_credentials_project_assignment/main.tf +++ b/tests/integration/008_cloud_credentials_project_assignment/main.tf @@ -10,7 +10,7 @@ resource "env0_cloud_credentials_project_assignment" "example" { } resource "env0_project" "test_project" { - name = "Test-Projecte-${random_string.random.result}" + name = "Test-Project-${random_string.random.result}" description = "Test Description" } diff --git a/tests/integration/012_environment/main.tf b/tests/integration/012_environment/main.tf index 8e9de026..b95ecd39 100644 --- a/tests/integration/012_environment/main.tf +++ b/tests/integration/012_environment/main.tf @@ -39,7 +39,7 @@ resource "env0_template_project_assignment" "assignment2" { project_id = env0_project.test_project2.id } -resource "env0_environment" "auto_glob_envrironment" { +resource "env0_environment" "auto_glob_environment" { depends_on = [env0_template_project_assignment.assignment] name = "environment-auto-glob-${random_string.random.result}" project_id = env0_project.test_project.id