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

Fix path used when persisting working directory #113

Merged
merged 4 commits into from
Apr 5, 2023

Conversation

bendbennett
Copy link
Contributor

Closes: #55

@bendbennett bendbennett added the bug Something isn't working label Apr 4, 2023
@bendbennett bendbennett requested a review from a team as a code owner April 4, 2023 09:05
Copy link
Contributor

@bflad bflad left a comment

Choose a reason for hiding this comment

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

This now works as expected with configuring TestCase.WorkingDir and using TF_ACC_PERSIST_WORKING_DIR=1 🚀

I'm going to create a followup issue to consider some directory and file naming changes for usability:

$ tree /Users/bflad/test/testing55
/Users/bflad/test/testing55
├── step_1
│   ├── work2542351694
│   │   ├── terraform.tfstate
│   │   ├── terraform.tfstate.backup
│   │   ├── terraform_plugin_test.tf
│   │   └── tfplan
│   └── work3964272250
│       ├── terraform.tfstate
│       ├── terraform_plugin_test.tf
│       └── tfplan
├── step_2
│   └── work2542351694
│       ├── terraform.tfstate
│       ├── terraform.tfstate.backup
│       ├── terraform_plugin_test.tf
│       └── tfplan
├── step_3
│   └── work2542351694
│       ├── terraform.tfstate
│       ├── terraform.tfstate.backup
│       ├── terraform_plugin_test.tf
│       └── tfplan
├── work2542351694
│   ├── terraform.tfstate
│   ├── terraform.tfstate.backup
│   ├── terraform_plugin_test.tf
│   └── tfplan
├── work3964272250
│   ├── terraform.tfstate
│   ├── terraform.tfstate.backup
│   ├── terraform_plugin_test.tf
│   └── tfplan
└── work862501402
    ├── terraform.tfstate
    └── terraform_plugin_test.tf

11 directories, 25 files

As well as save multiple plan files to capture each intermediate plan, since all the tfplan are the post-apply-with-refresh no-op plans.

@bflad bflad added this to the v1.3.0 milestone Apr 4, 2023
@bendbennett bendbennett merged commit cfd55c3 into main Apr 5, 2023
@bendbennett bendbennett deleted the bendbennett/issues-55 branch April 5, 2023 06:23
@github-actions
Copy link

github-actions bot commented May 6, 2023

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active contributions.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 6, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Setting TF_ACC_PERSIST_WORKING_DIR and TestCase.WorkingDir Saved to Unexpected Path
2 participants