Skip to content

Commit a9f332e

Browse files
committed
fix clippy tests
1 parent 7642673 commit a9f332e

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

lib/rs/src/protocol/compact.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -681,8 +681,6 @@ fn u8_to_type(b: u8) -> crate::Result<TType> {
681681
#[cfg(test)]
682682
mod tests {
683683

684-
use std::i32;
685-
686684
use crate::protocol::{
687685
TFieldIdentifier, TInputProtocol, TListIdentifier, TMapIdentifier, TMessageIdentifier,
688686
TMessageType, TOutputProtocol, TSetIdentifier, TStructIdentifier, TType,
@@ -2818,7 +2816,7 @@ mod tests {
28182816
copy_write_buffer_to_read_buffer!(o_prot);
28192817

28202818
let read_double = i_prot.read_double().unwrap();
2821-
assert!(read_double - double < std::f64::EPSILON);
2819+
assert!((read_double - double).abs() < f64::EPSILON);
28222820
}
28232821

28242822
#[test]

0 commit comments

Comments
 (0)