Skip to content

cmdline tests are executed in their respective test directory #15996

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

Merged
merged 2 commits into from
Apr 22, 2025

Conversation

clonker
Copy link
Member

@clonker clonker commented Apr 10, 2025

  • cmdlineTests.sh now changes directory into the respective test directory of the executed tests
  • updated test expectations accordingly

@clonker clonker requested a review from cameel April 12, 2025 07:29
cameel
cameel previously approved these changes Apr 22, 2025
Copy link
Member

@cameel cameel left a comment

Choose a reason for hiding this comment

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

Finally, this wart is gone :)

It's fine to merge as is, though you may also want to consider getting rid or the superfluous ./ prefix from test files.

scriptCount="$(echo "${scriptFiles}" | wc -w)"

inputFiles="$(ls -1 "${tdir}/input."* 2> /dev/null || true)"
inputFiles="$(ls -1 "./input."* 2> /dev/null || true)"
Copy link
Member

Choose a reason for hiding this comment

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

I think we'd be better off without the ./ prefix for input.* and other files from the test dir. Their names are hard-coded, so there's no risk that we get one prefixed with -, which looks like an option name and this prefix does show through in some places. E.g. model_checker_bmc_loop_iterations_no_argument/ output:

Error: the argument ('./input.sol') for option '--model-checker-bmc-loop-iterations' is invalid

Though, TBH it's actually less of an issue than I expected - after going over all the files here I've seen very few of these. This is because we try hard to normalize the paths passed on the CLI.

Copy link
Member Author

Choose a reason for hiding this comment

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

Ah yeah that is fair enough, let me fix that!

@cameel cameel force-pushed the cmdlineTests_go_to_test_dir branch from 27693c6 to 06a9e47 Compare April 22, 2025 14:38
@clonker clonker merged commit 2ab62d7 into develop Apr 22, 2025
74 checks passed
@clonker clonker deleted the cmdlineTests_go_to_test_dir branch April 22, 2025 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants