abcxyz / abc

Apache License 2.0
12 stars 3 forks source link

Test prompting during upgrade when a new input is added with a default #603

Closed drevell closed 3 months ago

drevell commented 3 months ago

This tests an edge case where:

  1. A template is installed that has no inputs.
  2. The template is updated to add an input that has a default value
  3. We run an upgrade
  4. The user should be prompted for a value for the new input; the default value should not silently be used.

I thought I saw this last week in my manual testing, but the test passes without changing the logic, so I may have been mistaken.

This change involves some refactoring and test util updates because this is the first time that we've tested prompting logic at the library layer (common/*), rather than the Command layer (commands/*) which wraps the library.