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 tests for CLI usage #511

Merged
merged 1 commit into from
Sep 16, 2023
Merged

add tests for CLI usage #511

merged 1 commit into from
Sep 16, 2023

Conversation

marcospb19
Copy link
Member

No description provided.

@figsoda
Copy link
Member

figsoda commented Sep 12, 2023

Aren't we already testing most of them in the integration tests?

@marcospb19
Copy link
Member Author

marcospb19 commented Sep 12, 2023

Maybe we do, but it didn't cover #485 case, I wrote these tests to get that case.

On top of that, our tests are property-based, it's also good to have explicit and straight-forward tests like this.

@figsoda
Copy link
Member

figsoda commented Sep 12, 2023

yeah sounds good to me then

src/cli/args.rs Outdated Show resolved Hide resolved
@marcospb19
Copy link
Member Author

I don't plan on removing your property tests, they're useful and also provide us some fuzzing, but I might add some specific tests in the future (the objective is not to be redundant, but I might accidentally get redundant sometimes).

Talking about our proptests, can you tell why this run failed?

https://github.com/ouch-org/ouch/actions/runs/6113846588/job/16594167075

Mmmmm that's the bad thing about only having tests with a scope so broad, investigating can be very confusing.

@figsoda
Copy link
Member

figsoda commented Sep 12, 2023

From the error message, it looks like the runner might have run out of memory possibly due to the fact that we are using cross and the combination of compression methods happened to take more memory than usual

@marcospb19
Copy link
Member Author

From the error message, it looks like the runner might have run out of memory possibly due to the fact that we are using cross and the combination of compression methods happened to take more memory than usual

That's great to hear :D , do you suggest we do something in order to reduce the chance of getting another false-positive?

@figsoda
Copy link
Member

figsoda commented Sep 12, 2023

Maybe trying to decrease the number of extensions, or decrease the maximum size of the file

@figsoda figsoda merged commit 4703f1b into main Sep 16, 2023
12 checks passed
@figsoda figsoda deleted the cli-add-tests branch September 16, 2023 14:16
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