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

avoid infinite loop with invalid objects #205

Merged
merged 1 commit into from
Feb 21, 2024

Conversation

Ekleog
Copy link
Contributor

@Ekleog Ekleog commented Feb 20, 2024

Actually check for NONSENSICAL_SIZE when in DriverMode::Forced, and introduce a regression test.

@camshaft
Copy link
Owner

Good catch! Thanks!

@camshaft camshaft merged commit a9dc986 into camshaft:master Feb 21, 2024
9 checks passed
@Ekleog Ekleog deleted the avoid-infinite-loop branch February 21, 2024 23:11

#[test]
fn unlikely_to_be_valid() {
let _ = generator_test!(gen_arbitrary::<UnlikelyToBeValid>());
Copy link
Owner

Choose a reason for hiding this comment

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

@Ekleog I saw a failure on this test: https://github.com/camshaft/bolero/actions/runs/8257285194/job/22587562228?pr=208#step:9:522

We'll need to figure out how to make it less flaky.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hmm is the random number generation not uniform? 1024 / 2**128 is definitely not something that should in any way be flaky 😅

Copy link
Owner

Choose a reason for hiding this comment

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

yeah it should be uniform... i haven't had a chance to dig into why it failed

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