Skip to content

Conversation

austinvalle
Copy link
Member

Related Issue

Closes #516
Supersedes #519

Description

#516 was a regression split across two PRs so it was a little tough to catch, as well as the behavior of teststep.Config is not obvious:

  • Add additional import test modes #442
    • Removed teststep.Config usage in favor of a string, however, the original mergedConfig is actually ignored when creating a new teststep.Config, which is confusing, but would essentially result in a ConfigFile/Directory test step being shaved down into just a string that has a required_providers block.
  • plannable import: support step.ConfigExact = [true|false] for all config sources #494
    • Removed the check for reusing a prior test step config, because it was checking a value that was always populated (either with real config via step.Config or just a shaved down required_providers block via step.ConfigFile/Directory)

This PR reintroduces the usage of a teststep.Config over a raw string, adjusts some of the existing tests to cover this scenario, and adds a new one for the command import mode.

Rollback Plan

  • If a change needs to be reverted, we will roll out an update to the code within 7 days.

Changes to Security Controls

No

@austinvalle austinvalle added this to the v1.13.2 milestone Jun 6, 2025
@austinvalle austinvalle requested a review from a team as a code owner June 6, 2025 15:04
@austinvalle austinvalle added the bug Something isn't working label Jun 6, 2025
rainkwan
rainkwan previously approved these changes Jun 6, 2025
Copy link
Contributor

@rainkwan rainkwan left a comment

Choose a reason for hiding this comment

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

Looks sensible and logically sound to me.

@austinvalle austinvalle force-pushed the av/config-regression branch from c667d05 to c50745f Compare June 11, 2025 20:29
@austinvalle austinvalle merged commit 2d87e3d into main Jun 11, 2025
40 checks passed
@austinvalle austinvalle deleted the av/config-regression branch June 11, 2025 20:38
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 11, 2025
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.

1.13.* : importstate doesn't use configuration from previous state with ConfigDirectory
3 participants