Skip to content

Commit 6a164ee

Browse files
committed
Updated tests
1 parent bcdca45 commit 6a164ee

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/can/id.rs

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,12 @@ mod tests {
194194

195195
#[test]
196196
fn cmp_id() {
197-
assert!(Id::Standard(StandardId::MAX) < Id::Standard(StandardId::ZERO));
198-
assert!(Id::Extended(ExtendedId::MAX) < Id::Extended(ExtendedId::ZERO));
197+
assert!(StandardId::ZERO < StandardId::MAX);
198+
assert!(ExtendedId::ZERO < ExtendedId::MAX);
199+
200+
assert!(Id::Standard(StandardId::ZERO) < Id::Extended(ExtendedId::ZERO));
201+
assert!(Id::Extended(ExtendedId::ZERO) < Id::Extended(ExtendedId::MAX));
202+
assert!(Id::Extended(ExtendedId((1 << 11) - 1)) < Id::Standard(StandardId(1)));
203+
assert!(Id::Standard(StandardId(1)) < Id::Extended(ExtendedId::MAX));
199204
}
200205
}

0 commit comments

Comments
 (0)