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

Fix clippy warnings in tests #198

Merged
merged 1 commit into from
Sep 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions examples/derive_enum.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ use arbitrary::{Arbitrary, Unstructured};

#[derive(Arbitrary, Debug)]
enum MyEnum {
UnitVariant,
TupleVariant(bool, u32),
StructVariant {
Unit,
Tuple(bool, u32),
Struct {
x: i8,
y: (u8, i32),
},

#[arbitrary(skip)]
SkippedVariant(usize),
Skipped(usize),
}

fn main() {
Expand Down
3 changes: 3 additions & 0 deletions tests/derive.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
// Various structs/fields that we are deriving `Arbitrary` for aren't actually
// used except to exercise the derive.
#![allow(dead_code)]
// Various assert_eq! are used to compare result of bool amongst other data types
// In this case, using assert! is less explicit and readable
#![allow(clippy::bool_assert_comparison)]

use arbitrary::*;

Expand Down
Loading