-
Notifications
You must be signed in to change notification settings - Fork 455
Add ‘dune promotion show’ command and tests #12669
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add ‘dune promotion show’ command and tests #12669
Conversation
|
@ElectreAAS do you want to try reviewing this one? |
ElectreAAS
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great!
My only question was: didn't we already have this? isn't this supposed to be what dune promotion diff does?
well apparently not
thanks :)
|
I'll let @ElectreAAS review or merge this one. |
218c6ea to
17be9be
Compare
|
I just rebased on main and apparently fucked up something with Github, don't worry I'm on it ;) |
17be9be to
a9b7a5c
Compare
|
Also as this is user-facing, a changes entry would be nice |
|
|
Implements a new command to display corrected file contents without applying the promotion. Users can now view what the promoted file would look like before deciding to promote. - Added 'show' subcommand to bin/promotion.ml - Exposed correction_file function in src/promote/diff_promotion.mli Tests still need to be added. Fixes ocaml#3883 Signed-off-by: Maxence Maury <[email protected]>
Add a new blackbox test to verify the behavior of the 'dune promotion show' command. The test covers common use cases and edge cases to make sure the command works as intended and doesn’t modify source files. It checks that: - corrected files are displayed after failed diffs - multiple files and missing promotions are handled properly - warnings appear for non-promotable or missing files - source files stay untouched after showing their content Signed-off-by: Maxence Maury <[email protected]>
Signed-off-by: Maxence Maury <[email protected]>
Signed-off-by: Ambre Austen Suhamy <[email protected]>
Signed-off-by: Maxence Maury <[email protected]>
0761581 to
da65ac6
Compare
This PR introduces a new subcommand
dune promotion showthat lets usersview the corrected contents of files ready for promotion without modifying
them.
It also adds a blackbox test verifying key behaviors:
Fixes #3883