Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add datafactory terratest module #1306

Merged

Conversation

sweanan
Copy link

@sweanan sweanan commented Jun 13, 2023

Description

Fixes [#1305 ]

This PR adds below:
Examples datafactory : examples/azure/datafactory
Azure Data Factory Module under: modules/azure/datafactory *
Corresponding tests are added: tests/azure/terraformdatafactory

CI Pipeline run
https://github.com/sweanan/terratest/actions/runs/5327539258/jobs/9651062907

--- PASS: TestTerraformAzureSynapseExample (963.67s)
--- PASS: TestTerraformAzureDataFactoryExample (65.98s)

@sweanan
Copy link
Author

sweanan commented Jun 13, 2023

FYI: @HadwaAbdelhalem @robcamer

"github.com/gruntwork-io/terratest/modules/testing"
"github.com/stretchr/testify/require"
)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could you add a helper to check dataFactoryExists. Similar to here

func FrontDoorExists(t testing.TestingT, frontDoorName string, resourceGroupName string, subscriptionID string) bool {

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @HadwaAbdelhalem added

expectedResourceGroupName := terraform.Output(t, terraformOptions, "resource_group_name")
expectedDataFactoryName := terraform.Output(t, terraformOptions, "datafactory_name")

// // website::tag::4:: Get synapse details and assert them against the terraform output
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you assert DataFactoryExists first

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @HadwaAbdelhalem moved

@@ -0,0 +1,49 @@
package test
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you add the build tags for ci test execution?

Suggested change
package test
//go:build azure
// +build azure
// NOTE: We use build tags to differentiate azure testing because we currently do not have azure access setup for
// CircleCI.
package test

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Hadwa added,also updated the CI pipeline run above in description for datafactory and synapse passed

https://github.com/sweanan/terratest/actions/runs/5327539258/jobs/9651062907

--- PASS: TestTerraformAzureSynapseExample (963.67s)
--- PASS: TestTerraformAzureDataFactoryExample (65.98s)

@sweanan
Copy link
Author

sweanan commented Jun 20, 2023

[Microsoft CI Bot] TL;DR; failure 🤦

You can check the status of the CI Pipeline logs here ; https://github.com/sweanan/terratest/actions/runs/5327302433

@sweanan
Copy link
Author

sweanan commented Jun 20, 2023

[Microsoft CI Bot] TL;DR; failure 🤦

You can check the status of the CI Pipeline logs here ; https://github.com/sweanan/terratest/actions/runs/5327539258

@denis256 denis256 merged commit b8689cd into gruntwork-io:master Jun 21, 2023
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants