This project is mirrored from https://:*****@github.com/hashicorp/terraform.git.
Pull mirroring failed .
Repository mirroring has been paused due to too many failed attempts. It can be resumed by a project maintainer.
Repository mirroring has been paused due to too many failed attempts. It can be resumed by a project maintainer.
- 12 Oct, 2018 2 commits
-
-
Martin Atkins authored
-
Martin Atkins authored
-
- 11 Oct, 2018 4 commits
-
-
Martin Atkins authored
There are several steps here and a number of them can include reaching out to remote servers or executing local processes, so it's helpful to have some trace logs to better narrow down causes of errors and hangs during this step.
-
Martin Atkins authored
Our serialization of the backend configuration has changed slightly for Terraform 0.12 due to reimplementing it in terms of the HCL2 types, so the base case that should be unchanged during the test needs to be changed.
-
Martin Atkins authored
In all real cases the schemas should be populated here, but we don't want to panic in UI rendering code if there's a bug here. This can also be tripped up by tests with incomplete mocks. It's unfortunate that this can therefore mask some problems in tests, but tests can protect against it by asserting on specific output text rather than just assuming that a zero exit status is a pass.
-
Martin Atkins authored
In earlier refactoring we skipped implementing prior state safety checks, propagating the target addresses from plan, and verifying that all of the providers are exactly the same from the plan being created. This change reinstates those checks, including a new error message for the "stale plan" situation.
-
- 10 Oct, 2018 6 commits
-
-
Kristin Laemmert authored
mildwonkey/f-state-format-cmd
-
Kristin Laemmert authored
-
Kristin Laemmert authored
also run go mod tidy
-
Martin Atkins authored
If we fail to parse the resource address given to "terraform import" then it's helpful to produce a "source code" snippet of what the user provided so they might see more precisely which part of the address was invalid.
-
Martin Atkins authored
-
Martin Atkins authored
Most of this is just updates to allow for the fact that we now always save the provider address as part of resource state, whereas before it was only saved conditionally. This also updates TestTaint_module for the intentional change that it now expects a child module to be specified using normal resource address syntax, rather than as a separate -module option.
-
- 09 Oct, 2018 15 commits
-
-
Martin Atkins authored
The untaint command now uses normal resource address syntax to specify the module path, rather than passing it in as a separate argument.
-
Martin Atkins authored
Resource instance state now always includes the provider address fo each resource, so our expected state output strings needed to be adjusted.
-
Martin Atkins authored
-
Martin Atkins authored
This is just to make sure they show up later when we are working on the tests, so we can be sure not to forget to address them.
-
Martin Atkins authored
-
Kristin Laemmert authored
-
Kristin Laemmert authored
-
Kristin Laemmert authored
Added a very simple test with state and schema. TODO: if tests are added we should test using golden files (and example state files, instead of strings). This seemed unnecessary with the simple test cases.
-
Kristin Laemmert authored
Use functions from format/diff to print values
-
Kristin Laemmert authored
format/state now requires provider schemas to properly format output state. command/show has been modified to pass a context to format.State.
-
Martin Atkins authored
In previous work we didn't quite connect these dots. The connection here is sub-awesome since the existing interfaces here had some unfortunate assumptions that we'd like to move away from (like the idea of a "nil backend" implying the local backend) but we're accepting this for now to avoid another big round of refactoring. The main implication of this is that we will now always include a backend configuration in the plan, though it might just be a placeholder config for the local backend in the remaining cases where that's still implicitly set. Later we will change this so that there is no implicit local backend at all (terraform init is always required, _it_ will deal with setting implicitly setting the local backend when appropriate), which will allow us to rework this to be more straightforward and less "spooky".
-
Martin Atkins authored
If we don't do this, we can't produce any output when applying a saved plan file. Here we also introduce a check to the local backend's ReportResult function so that it won't panic if CLI init is skipped, although that will no longer happen in the apply-from-file case due to the change described in the previous paragraph.
-
Martin Atkins authored
We can't generate a valid plan file without a backend configuration to write into it, but it's the responsibility of the caller (the command package) to manage the backend configuration mechanism, so we require it to tell us what to write here. This feels a little strange because the backend in principle knows its own config, but in practice the backend only knows the _processed_ version of the config, not the raw configuration value that was used to configure it.
-
Martin Atkins authored
-
Martin Atkins authored
-
- 08 Oct, 2018 12 commits
-
-
Kristin Laemmert authored
mildwonkey/backend-local-tests
-
Kristin Laemmert authored
converted the existing testPlanState() from terraform.State to states.State to fix various plan tests. reverted the "bandaid" in plans/planfile/tfplan.go - at this moment the backend tests do not include backend configuration, and so the planfile package can write the plan file but not read it back in. That will be revisted in a separate track of work.
-
Kristin Laemmert authored
I have no confidence in the change to plans/planfile/tfplan.go. The tests were passing an empty backend config, which planfile was able to write to a file but not read from the same file. This change let me move past that and it did not break any tests in the planfile package, but I am concerned that it introduces undesired behavior.
-
Kristin Laemmert authored
-
Kristin Laemmert authored
-
Kristin Laemmert authored
for TestLocal_applyBackendFail, config is relative to the tests' wd
-
Kristin Laemmert authored
-
Kristin Laemmert authored
-
James Bardin authored
The legacy test wasn't really testing anything useful, just the plan behavior with no diff in a module returned a module with no diff. There's no reason to convert this to the new plans, since there's no legacy behavior to match.
-
James Bardin authored
-
James Bardin authored
a plan with no diff should return proposed state
-
James Bardin authored
The "internal" provisioners are still run in a separate process, and need to be updated to restart on each walk.
-
- 06 Oct, 2018 1 commit
-
-
James Bardin authored
Some call diagnostics were being missed
-