Skip to content

Conversation

@mafredri
Copy link
Member

@mafredri mafredri commented Dec 11, 2025

Previously the GetTemplateVersionVariables query did not sort output, relying on PostgreSQL on-disk ordering.

In the TestTemplatePush/Variables/PromptForDifferentRequiredTypes test, a certain order was incorrectly assumed, leading to flakes.

While updating the test, the rest of the test file was modernized and context usage adjusted to better understand future timeouts.

@mafredri mafredri changed the title test(cli): modernize TestTemplatePush and fix contexts fix(coderd): sort template version variables and fix test flake Dec 11, 2025
@mafredri mafredri changed the title fix(coderd): sort template version variables and fix test flake fix(coderd/database): sort template version variables and fix test flake Dec 11, 2025
pty.ExpectMatch("var.string_var")
pty.ExpectMatch("Enter value:")
pty.WriteLine("test-string")
// Variables are prompted in alphabetical order.
Copy link
Member Author

Choose a reason for hiding this comment

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

Review: Below is the actual test flake fix, combined with the query ordering.

@mafredri mafredri marked this pull request as ready for review December 11, 2025 19:51
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