Skip to content

Allow functions in test mock blocks#37883

Merged
dsa0x merged 9 commits intomainfrom
sams/test-override-block-functions
Jan 22, 2026
Merged

Allow functions in test mock blocks#37883
dsa0x merged 9 commits intomainfrom
sams/test-override-block-functions

Conversation

@dsa0x
Copy link
Member

@dsa0x dsa0x commented Nov 7, 2025

This PR allows the use of hcl functions within the terraform test mocking framework. Values for all mock related blocks (mock* and override*) will be held as hcl expressions, and evaluated within the test runtime, thus resolving the dynamic values (which may contain functions and literal values).

RFC Link.

Target Release

1.15.x

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

Are there any changes to security controls (access controls, encryption, logging) in this pull request? If so, explain.

CHANGELOG entry

  • This change is user-facing and I added a changelog entry.
  • This change is not user-facing.

@dsa0x dsa0x changed the title Allow functions in override blocks Allow functions in test mock blocks Nov 7, 2025
@dsa0x dsa0x force-pushed the sams/test-override-block-functions branch from 9b18bfa to 0a452ad Compare January 13, 2026 10:53
@dsa0x dsa0x force-pushed the sams/test-override-block-functions branch from 4a1379f to 83c8299 Compare January 13, 2026 12:06
@dsa0x dsa0x force-pushed the sams/test-override-block-functions branch from 83c8299 to 2d2a9b9 Compare January 13, 2026 12:06
@dsa0x dsa0x force-pushed the sams/test-override-block-functions branch 3 times, most recently from f403f04 to c30720b Compare January 13, 2026 16:15
@dsa0x dsa0x force-pushed the sams/test-override-block-functions branch from c30720b to 5f37588 Compare January 13, 2026 16:32
@dsa0x dsa0x marked this pull request as ready for review January 14, 2026 10:30
@dsa0x dsa0x requested a review from a team as a code owner January 14, 2026 10:30
@dsa0x dsa0x merged commit 0b35407 into main Jan 22, 2026
15 checks passed
@dsa0x dsa0x deleted the sams/test-override-block-functions branch January 22, 2026 08:42
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.

2 participants