Skip to content
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 EXPECT_TEXT runtime test directive #2842

Closed
danobi opened this issue Nov 21, 2023 · 1 comment
Closed

Add EXPECT_TEXT runtime test directive #2842

danobi opened this issue Nov 21, 2023 · 1 comment
Labels
enhancement New feature or request, changes on existing features good first issue Good for newcomers tests Issues with our tests or test framework; missing tests; invalid tests

Comments

@danobi
Copy link
Member

danobi commented Nov 21, 2023

Similar to #2841, would be great to have an EXPECT_TEXT directive that compared output with contents of of a checked in file. This would make testing the human readable text output of helpers like hist() more tractable.

A good candidate is adding more tests for hist() cuz that's mostly been missing. See #2831

@danobi danobi added enhancement New feature or request, changes on existing features good first issue Good for newcomers tests Issues with our tests or test framework; missing tests; invalid tests labels Nov 21, 2023
@luigirizzo
Copy link
Contributor

See #2845 for a possible implementation of this and EXPECT_JSON features.

I have used EXPECT_FILE instead of EXPECT_TEXT as keyword, because
the latter seems ambiguous (is the rest of the line plaintext to compare, or a filename?)

But I have no strong opinions and this is a trivial change.

I

@danobi danobi closed this as completed Nov 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request, changes on existing features good first issue Good for newcomers tests Issues with our tests or test framework; missing tests; invalid tests
Projects
None yet
Development

No branches or pull requests

2 participants