Skip to content

Merge run provider tests and use built provider#8229

Merged
melinath merged 16 commits into
GoogleCloudPlatform:mainfrom
trodge:run-tests-guide
Jul 25, 2023
Merged

Merge run provider tests and use built provider#8229
melinath merged 16 commits into
GoogleCloudPlatform:mainfrom
trodge:run-tests-guide

Conversation

@trodge

@trodge trodge commented Jun 28, 2023

Copy link
Copy Markdown
Contributor

Merge the "Run provider tests" and "Use built provider" pages into "Run tests" page.

If this PR is for Terraform, I acknowledge that I have:

  • Searched through the issue tracker for an open issue that this either resolves or contributes to, commented on it to claim it, and written "fixes {url}" or "part of {url}" in this PR description. If there were no relevant open issues, I opened one and commented that I would like to work on it (not necessary for very small changes).
  • Ensured that all new fields I added that can be set by a user appear in at least one example (for generated resources) or third_party test (for handwritten resources or update tests).
  • Generated Terraform providers, and ran make test and make lint in the generated providers to ensure it passes unit and linter tests.
  • Ran relevant acceptance tests using my own Google Cloud project and credentials (If the acceptance tests do not yet pass or you are unable to run them, please let your reviewer know).
  • Read Write release notes before writing my release note below.

Release Note Template for Downstream PRs (will be copied)


@modular-magician

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR hasn't generated any diffs, but I'll let you know if a future commit does.

@trodge trodge requested a review from melinath June 28, 2023 22:31
@trodge trodge force-pushed the run-tests-guide branch from 03d656d to 82356fa Compare June 28, 2023 23:16
@modular-magician

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR hasn't generated any diffs, but I'll let you know if a future commit does.

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests analytics

Total tests: 2832
Passed tests 2536
Skipped tests: 295
Affected tests: 1

Action taken

Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccComputeFirewallPolicyRule_multipleRules

Get to know how VCR tests work

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests failed during RECORDING mode:
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@melinath melinath left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks for putting this together - I left some change requests, mostly style cleanup.

Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md
Comment thread docs/content/develop/run-tests.md Outdated
@modular-magician

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR hasn't generated any diffs, but I'll let you know if a future commit does.

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests analytics

Total tests: 2834
Passed tests 2531
Skipped tests: 295
Affected tests: 8

Action taken

Found 8 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccFilestoreInstance_update|TestAccFilestoreInstance_filestoreInstanceFullExample|TestAccFilestoreInstance_filestoreInstanceBasicExample|TestAccFilestoreBackup_update|TestAccFilestoreBackup_filestoreBackupBasicExample|TestAccFilestoreSnapshot_filestoreSnapshotFullExample|TestAccFilestoreSnapshot_filestoreSnapshotBasicExample|TestAccComputeFirewallPolicyRule_multipleRules

Get to know how VCR tests work

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests passed during RECORDING mode:
TestAccFilestoreBackup_update[Debug log]
TestAccFilestoreSnapshot_filestoreSnapshotBasicExample[Debug log]

Tests failed during RECORDING mode:
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

Several tests got terminated during RECORDING mode.
Please fix these to complete your PR
View the build log or the debug log for each test

@trodge trodge force-pushed the run-tests-guide branch from 95b35be to dbc931d Compare June 29, 2023 21:58
@trodge trodge requested a review from melinath June 29, 2023 22:00
@modular-magician

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR hasn't generated any diffs, but I'll let you know if a future commit does.

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests analytics

Total tests: 2834
Passed tests 2536
Skipped tests: 295
Affected tests: 3

Action taken

Found 3 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccFilestoreSnapshot_filestoreSnapshotFullExample|TestAccFilestoreInstance_filestoreInstanceBasicExample|TestAccComputeFirewallPolicyRule_multipleRules

Get to know how VCR tests work

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests passed during RECORDING mode:
TestAccFilestoreSnapshot_filestoreSnapshotFullExample[Debug log]
TestAccFilestoreInstance_filestoreInstanceBasicExample[Debug log]

Rerun these tests in REPLAYING mode to catch issues

All tests passed after rerunning REPLAYING mode.


Tests failed during RECORDING mode:
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@melinath melinath left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

could you add some guidance on how folks can create a test configuration to do manual tests with?

Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md
Comment thread docs/content/develop/run-tests.md Outdated
Sometimes, for example for manual testing, you may want to build the provider from source and use it with `terraform`.

## Developer Overrides
### Build provider

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Possibly put this after the developer overrides section.

Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md
Comment thread docs/content/develop/run-tests.md Outdated
## Alternative: using a global CLI configuration file
### Alternative: using a global CLI configuration file

If you do not want to use the `TF_CLI_CONFIG_FILE` environment variable, as described above, you can instead create a global version of the CLI configuration file. This configuration will be used automatically by Terraform. To do this, follow [the guidance in the official documentation](https://developer.hashicorp.com/terraform/cli/config/config-file#locations).

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We should recommend a specific path here and link to the Hashicorp docs for more details to reduce the amount of inline context

Comment thread docs/content/develop/run-tests.md
@melinath

Copy link
Copy Markdown
Member

btw this is a huge improvement already, thank you!

@modular-magician

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR hasn't generated any diffs, but I'll let you know if a future commit does.

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests analytics

Total tests: 2836
Passed tests 2540
Skipped tests: 295
Affected tests: 1

Action taken

Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccComputeFirewallPolicyRule_multipleRules

Get to know how VCR tests work

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests failed during RECORDING mode:
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@modular-magician

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR hasn't generated any diffs, but I'll let you know if a future commit does.

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests analytics

Total tests: 2836
Passed tests 2540
Skipped tests: 295
Affected tests: 1

Action taken

Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccComputeFirewallPolicyRule_multipleRules

Get to know how VCR tests work

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests failed during RECORDING mode:
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@modular-magician

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR hasn't generated any diffs, but I'll let you know if a future commit does.

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests analytics

Total tests: 2836
Passed tests 2540
Skipped tests: 295
Affected tests: 1

Action taken

Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccComputeFirewallPolicyRule_multipleRules

Get to know how VCR tests work

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests failed during RECORDING mode:
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@melinath melinath self-requested a review July 10, 2023 16:58

@melinath melinath left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This is looking really good! I left a few comments but then realized there are still a few things pending from the last review - apologies for the double-review!

Comment thread docs/content/develop/run-tests.md
Comment thread docs/content/develop/run-tests.md
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
trodge and others added 2 commits July 10, 2023 21:55
Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>
@trodge trodge force-pushed the run-tests-guide branch from 670d93e to 1326a94 Compare July 10, 2023 21:55
@trodge trodge requested a review from melinath July 10, 2023 21:55
@modular-magician

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR hasn't generated any diffs, but I'll let you know if a future commit does.

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests analytics

Total tests: 2848
Passed tests 2550
Skipped tests: 295
Affected tests: 3

Action taken

Found 3 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccFolderIamPolicy_basic|TestAccContainerAwsNodePool_BetaBasicHandWritten|TestAccComputeFirewallPolicyRule_multipleRules

Get to know how VCR tests work

@modular-magician

Copy link
Copy Markdown
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccFolderIamPolicy_basic[Debug log]

Rerun these tests in REPLAYING mode to catch issues

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccContainerAwsNodePool_BetaBasicHandWritten[Error message] [Debug log]
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$
View the build log or the debug log for each test

@melinath melinath left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks, looking better! Some additional change requests below.

Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>
@modular-magician

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

Terraform GA: Diff ( 1 file changed, 1 insertion(+))
TF Conversion: Diff ( 2 files changed, 3 insertions(+), 3 deletions(-))

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests analytics

Total tests: 2851
Passed tests 2552
Skipped tests: 296
Affected tests: 3

Action taken

Found 3 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccContainerCluster_withMonitoringConfig|TestAccContainerAwsNodePool_BetaBasicHandWritten|TestAccComputeFirewallPolicyRule_multipleRules

Get to know how VCR tests work

@modular-magician

Copy link
Copy Markdown
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccContainerCluster_withMonitoringConfig[Debug log]

Rerun these tests in REPLAYING mode to catch issues

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccContainerAwsNodePool_BetaBasicHandWritten[Error message] [Debug log]
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$
View the build log or the debug log for each test

@trodge trodge requested a review from melinath July 14, 2023 20:30
@modular-magician

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR hasn't generated any diffs, but I'll let you know if a future commit does.

@modular-magician

Copy link
Copy Markdown
Collaborator

Tests analytics

Total tests: 2856
Passed tests 2554
Skipped tests: 299
Affected tests: 3

Action taken

Found 3 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccContainerAwsNodePool_BetaBasicHandWritten|TestAccContainerCluster_withMonitoringConfig|TestAccComputeFirewallPolicyRule_multipleRules

Get to know how VCR tests work

@modular-magician

Copy link
Copy Markdown
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccContainerCluster_withMonitoringConfig[Debug log]

Rerun these tests in REPLAYING mode to catch issues

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccContainerAwsNodePool_BetaBasicHandWritten[Error message] [Debug log]
TestAccComputeFirewallPolicyRule_multipleRules[Error message] [Debug log]

$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$
View the build log or the debug log for each test

@melinath melinath left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

A few more change requests and then I think this will be good to go!

Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Comment thread docs/content/develop/run-tests.md Outdated
Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>
@trodge trodge force-pushed the run-tests-guide branch from fb9b6cd to 57b1dfc Compare July 19, 2023 21:44
@trodge trodge requested a review from melinath July 19, 2023 21:45
@modular-magician

Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

TF Conversion: Diff ( 2 files changed, 3 insertions(+), 3 deletions(-))

@melinath melinath left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM - this is a significant improvement over the previous pages. Thanks for your work on this!

@melinath melinath merged commit 8863502 into GoogleCloudPlatform:main Jul 25, 2023
@trodge trodge deleted the run-tests-guide branch July 25, 2023 20:28
ericayyliu pushed a commit to ericayyliu/magic-modules that referenced this pull request Jul 26, 2023
…8229)

* Merge run provider tests and use built provider

* Add aliases, fix link

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Move hint and link to wiki

* Reorganize into tabs

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Add tabs for provider version

* Fix link

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Move delve into tabs

* Fix ref links

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

---------

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>
NickElliot pushed a commit to NickElliot/magic-modules that referenced this pull request Jul 31, 2023
…8229)

* Merge run provider tests and use built provider

* Add aliases, fix link

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Move hint and link to wiki

* Reorganize into tabs

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Add tabs for provider version

* Fix link

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Move delve into tabs

* Fix ref links

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

---------

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>
DanielRieske pushed a commit to bschaatsbergen/magic-modules that referenced this pull request Aug 2, 2023
…8229)

* Merge run provider tests and use built provider

* Add aliases, fix link

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Move hint and link to wiki

* Reorganize into tabs

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Add tabs for provider version

* Fix link

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Move delve into tabs

* Fix ref links

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

---------

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>
hao-nan-li pushed a commit to hao-nan-li/magic-modules that referenced this pull request Aug 9, 2023
…8229)

* Merge run provider tests and use built provider

* Add aliases, fix link

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Move hint and link to wiki

* Reorganize into tabs

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Add tabs for provider version

* Fix link

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Move delve into tabs

* Fix ref links

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

* Apply suggestions from code review

* Apply suggestions from code review

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>

---------

Co-authored-by: Stephen Lewis (Burrows) <stephen.r.burrows@gmail.com>
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.

3 participants