/third_party/rust/crates/minimal-lexical/tests/ |
H A D | lemire_tests.rs | 41 assert_eq!(compute_error32(0, 16777216), (111 + f32::INVALID_FP, 9223372036854775808)); in compute_error32_test() 42 assert_eq!(compute_error32(0, 16777217), (111 + f32::INVALID_FP, 9223372586610589696)); in compute_error32_test() 43 assert_eq!(compute_error32(0, 16777218), (111 + f32::INVALID_FP, 9223373136366403584)); in compute_error32_test() 44 assert_eq!(compute_error32(0, 16777219), (111 + f32::INVALID_FP, 9223373686122217472)); in compute_error32_test() 45 assert_eq!(compute_error32(0, 16777220), (111 + f32::INVALID_FP, 9223374235878031360)); in compute_error32_test() 49 assert_eq!( in compute_error32_test() 53 assert_eq!( in compute_error32_test() 57 assert_eq!( in compute_error32_test() 62 assert_eq!( in compute_error32_test() 66 assert_eq!( in compute_error32_test() [all...] |
H A D | vec_tests.rs | 19 assert_eq!(x.len(), 1); in simple_test() 20 assert_eq!(x.is_empty(), false); in simple_test() 21 assert_eq!(x.capacity(), bigint::BIGINT_LIMBS); in simple_test() 23 assert_eq!(x.len(), 2); in simple_test() 24 assert_eq!(x.pop(), Some(5)); in simple_test() 25 assert_eq!(x.len(), 1); in simple_test() 26 assert_eq!(&*x, &[1]); in simple_test() 28 assert_eq!(x.len(), 4); in simple_test() 29 assert_eq!(&*x, &[1, 2, 3, 4]); in simple_test() 31 assert_eq!( in simple_test() [all...] |
H A D | number_tests.rs | 10 assert_eq!(number.is_fast_path::<f32>(), true); in is_fast_path_test() 11 assert_eq!(number.is_fast_path::<f64>(), true); in is_fast_path_test() 14 assert_eq!(number.is_fast_path::<f32>(), false); in is_fast_path_test() 15 assert_eq!(number.is_fast_path::<f64>(), true); in is_fast_path_test() 18 assert_eq!(number.is_fast_path::<f32>(), false); in is_fast_path_test() 19 assert_eq!(number.is_fast_path::<f64>(), false); in is_fast_path_test() 22 assert_eq!(number.is_fast_path::<f32>(), false); in is_fast_path_test() 23 assert_eq!(number.is_fast_path::<f64>(), true); in is_fast_path_test() 26 assert_eq!(number.is_fast_path::<f32>(), false); in is_fast_path_test() 27 assert_eq!(numbe in is_fast_path_test() [all...] |
H A D | slow_tests.rs | 22 assert_eq!(b(1e-45_f32), (1, -149)); in b_test() 23 assert_eq!(b(5e-324_f64), (1, -1074)); in b_test() 24 assert_eq!(b(1e-323_f64), (2, -1074)); in b_test() 25 assert_eq!(b(2e-323_f64), (4, -1074)); in b_test() 26 assert_eq!(b(3e-323_f64), (6, -1074)); in b_test() 27 assert_eq!(b(4e-323_f64), (8, -1074)); in b_test() 28 assert_eq!(b(5e-323_f64), (10, -1074)); in b_test() 29 assert_eq!(b(6e-323_f64), (12, -1074)); in b_test() 30 assert_eq!(b(7e-323_f64), (14, -1074)); in b_test() 31 assert_eq!( in b_test() [all...] |
H A D | bellerophon_tests.rs | 176 assert_eq!(compute_float32(0, 16777216), (151, 0)); in compute_float_f32_test() 177 assert_eq!(compute_float32(0, 16777217), (111 + f32::INVALID_FP, 9223372586610589696)); in compute_float_f32_test() 178 assert_eq!(compute_float32(0, 16777218), (151, 1)); in compute_float_f32_test() 179 assert_eq!(compute_float32(0, 16777219), (111 + f32::INVALID_FP, 9223373686122217472)); in compute_float_f32_test() 180 assert_eq!(compute_float32(0, 16777220), (151, 2)); in compute_float_f32_test() 184 assert_eq!(compute_float32(-10, 167772160000000000), (151, 0)); in compute_float_f32_test() 185 assert_eq!( in compute_float_f32_test() 189 assert_eq!(compute_float32(-10, 167772180000000000), (151, 1)); in compute_float_f32_test() 191 assert_eq!( in compute_float_f32_test() 195 assert_eq!(compute_float3 in compute_float_f32_test() [all...] |
/third_party/rust/crates/clap/tests/builder/ |
H A D | action.rs | 14 assert_eq!(matches.get_one::<String>("mammal"), None); in set() 15 assert_eq!(matches.contains_id("mammal"), false); in set() 16 assert_eq!(matches.index_of("mammal"), None); in set() 22 assert_eq!(matches.get_one::<String>("mammal").unwrap(), "dog"); in set() 23 assert_eq!(matches.contains_id("mammal"), true); in set() 24 assert_eq!(matches.index_of("mammal"), Some(2)); in set() 30 assert_eq!(err.kind(), ErrorKind::ArgumentConflict); in set() 37 assert_eq!(matches.get_one::<String>("mammal").unwrap(), "cat"); in set() 38 assert_eq!(matches.contains_id("mammal"), true); in set() 39 assert_eq!(matche in set() [all...] |
/third_party/rust/crates/rustix/tests/path/ |
H A D | arg.rs | 16 assert_eq!("hello", t.as_str().unwrap()); in test_arg() 17 assert_eq!("hello".to_owned(), Arg::to_string_lossy(&t)); in test_arg() 18 assert_eq!(cstr!("hello"), Borrow::borrow(&t.as_cow_c_str().unwrap())); in test_arg() 19 assert_eq!(cstr!("hello"), Borrow::borrow(&t.into_c_str().unwrap())); in test_arg() 22 assert_eq!("hello", Arg::as_str(&t).unwrap()); in test_arg() 23 assert_eq!("hello".to_owned(), Arg::to_string_lossy(&t)); in test_arg() 24 assert_eq!(cstr!("hello"), Borrow::borrow(&t.as_cow_c_str().unwrap())); in test_arg() 25 assert_eq!(cstr!("hello"), Borrow::borrow(&t.into_c_str().unwrap())); in test_arg() 28 assert_eq!("hello", t.as_str().unwrap()); in test_arg() 29 assert_eq!("hell in test_arg() [all...] |
/third_party/rust/crates/glob/tests/ |
H A D | glob-std.rs | 82 assert_eq!( in main() 95 assert_eq!( in main() 107 assert_eq!( in main() 127 assert_eq!( in main() 141 assert_eq!( in main() 151 assert_eq!( in main() 160 assert_eq!( in main() 168 assert_eq!(glob_vec(""), Vec::<PathBuf>::new()); in main() 169 assert_eq!(glob_vec("."), vec!(PathBuf::from("."))); in main() 170 assert_eq!(glob_ve in main() [all...] |
/third_party/rust/crates/nom/src/bytes/ |
H A D | tests.rs | 26 assert_eq!(a_or_b(a), Ok((&b"cd"[..], &b"ab"[..]))); in is_a() 29 assert_eq!(a_or_b(b), Ok((&b"cde"[..], &b"b"[..]))); in is_a() 32 assert_eq!( in is_a() 38 assert_eq!(a_or_b(d), Ok((&b"cdef"[..], &b"ba"[..]))); in is_a() 50 assert_eq!(a_or_b(a), Ok((&b"ab"[..], &b"cd"[..]))); in is_not() 53 assert_eq!(a_or_b(b), Ok((&b"bde"[..], &b"c"[..]))); in is_not() 56 assert_eq!( in is_not() 62 assert_eq!(a_or_b(d), Ok((&b"ba"[..], &b"cdef"[..]))); in is_not() 65 assert_eq!(a_or_b(e), Err(Err::Incomplete(Needed::new(1)))); in is_not() 77 assert_eq!(es in escaping() [all...] |
/third_party/rust/crates/proc-macro2/tests/ |
H A D | test.rs | 14 assert_eq!( in idents() 18 assert_eq!(Ident::new("fn", Span::call_site()).to_string(), "fn"); in idents() 19 assert_eq!(Ident::new("_", Span::call_site()).to_string(), "_"); in idents() 24 assert_eq!( in raw_idents() 28 assert_eq!(Ident::new_raw("fn", Span::call_site()).to_string(), "r#fn"); in raw_idents() 99 assert_eq!(Literal::string("foo").to_string(), "\"foo\""); in literal_string() 100 assert_eq!(Literal::string("\"").to_string(), "\"\\\"\""); in literal_string() 101 assert_eq!(Literal::string("didn't").to_string(), "\"didn't\""); in literal_string() 102 assert_eq!( in literal_string() 137 assert_eq!(Litera in literal_byte_string() [all...] |
/third_party/rust/crates/clap/tests/ |
H A D | macros.rs | 5 assert_eq!(arg.get_id(), "foo"); in name_explicit() 6 assert_eq!(arg.get_long(), Some("bar")); in name_explicit() 7 assert_eq!(arg.get_value_names(), Some(vec!["NUM".into()].as_slice())); in name_explicit() 14 assert_eq!(arg.get_id(), "bar"); in name_from_long() 15 assert_eq!(arg.get_long(), Some("bar")); in name_from_long() 16 assert_eq!(arg.get_value_names(), Some(vec!["NUM".into()].as_slice())); in name_from_long() 23 assert_eq!(arg.get_id(), "NUM"); in name_from_value() 24 assert_eq!(arg.get_long(), None); in name_from_value() 25 assert_eq!(arg.get_value_names(), Some(vec!["NUM".into()].as_slice())); in name_from_value() 44 assert_eq!(ar in short() [all...] |
/third_party/rust/crates/bitflags/src/ |
H A D | lib.rs | 35 //! assert_eq!((e1 | e2), Flags::ABC); // union 36 //! assert_eq!((e1 & e2), Flags::C); // intersection 37 //! assert_eq!((e1 - e2), Flags::A); // set difference 38 //! assert_eq!(!e2, Flags::A); // set complement 77 //! assert_eq!(format!("{}", flags), "hi!"); 78 //! assert_eq!(format!("{:?}", Flags::A | Flags::B), "A | B"); 79 //! assert_eq!(format!("{:?}", Flags::B), "B"); 217 //! assert_eq!(derived_default.bits(), 0); 243 //! assert_eq!(implemented_default, (Flags::A | Flags::C)); 305 /// assert_eq!((e [all...] |
/third_party/rust/crates/cxx/tests/ |
H A D | test.rs | 41 assert_eq!(2020, ffi::c_return_primitive()); in test_c_return() 42 assert_eq!(2020, ffi::c_return_shared().z); in test_c_return() 43 assert_eq!(2020, ffi::c_return_box().0); in test_c_return() 46 assert_eq!(2020, *ffi::c_return_ref(&shared)); in test_c_return() 47 assert_eq!(2020, *ffi::c_return_ns_ref(&ns_shared)); in test_c_return() 48 assert_eq!(2020, *ffi::c_return_nested_ns_ref(&nested_ns_shared)); in test_c_return() 49 assert_eq!("2020", ffi::c_return_str(&shared)); in test_c_return() 50 assert_eq!( in test_c_return() 54 assert_eq!("2020", ffi::c_return_rust_string()); in test_c_return() 55 assert_eq!("Hell in test_c_return() [all...] |
/third_party/rust/crates/once_cell/tests/ |
H A D | it.rs | 14 assert_eq!(c.get(), Some(&92)); in once_cell() 17 assert_eq!(c.get(), Some(&92)); in once_cell() 24 assert_eq!(cell.get(), Some(&12)); in once_cell_with_value() 33 assert_eq!(c.get_mut(), Some(&mut 92)); in once_cell_get_mut() 48 assert_eq!(DROP_CNT.load(SeqCst), 0); in once_cell_drop() 50 assert_eq!(DROP_CNT.load(SeqCst), 1); in once_cell_drop() 67 assert_eq!(c.get().map(String::as_str), Some("hello")); in clone() 72 assert_eq!(OnceCell::from("value").get(), Some(&"value")); in from_impl() 88 assert_eq!(cell.into_inner(), None); in into_inner() 91 assert_eq!(cel in into_inner() [all...] |
/third_party/rust/crates/unicode-width/src/ |
H A D | tests.rs | 117 assert_eq!(UnicodeWidthStr::width("hello"), 10); in test_str() 118 assert_eq!("hello".width_cjk(), 10); in test_str() 119 assert_eq!(UnicodeWidthStr::width("\0\0\0\x01\x01"), 0); in test_str() 120 assert_eq!("\0\0\0\x01\x01".width_cjk(), 0); in test_str() 121 assert_eq!(UnicodeWidthStr::width(""), 0); in test_str() 122 assert_eq!("".width_cjk(), 0); in test_str() 123 assert_eq!(UnicodeWidthStr::width("\u{2081}\u{2082}\u{2083}\u{2084}"), 4); in test_str() 124 assert_eq!("\u{2081}\u{2082}\u{2083}\u{2084}".width_cjk(), 8); in test_str() 132 assert_eq!(UnicodeWidthStr::width("?"), 2); // Woman in test_emoji() 133 assert_eq!(UnicodeWidthSt in test_emoji() [all...] |
/third_party/rust/crates/rustix/tests/process/ |
H A D | id.rs | 5 assert_eq!(process::getuid(), process::getuid()); in test_getuid() 7 assert_eq!(process::getuid().as_raw(), libc::getuid()); in test_getuid() 8 assert_eq!(process::getuid().is_root(), libc::getuid() == 0); in test_getuid() 14 assert_eq!(process::getgid(), process::getgid()); in test_getgid() 16 assert_eq!(process::getgid().as_raw(), libc::getgid()); in test_getgid() 17 assert_eq!(process::getgid().is_root(), libc::getgid() == 0); in test_getgid() 23 assert_eq!(process::geteuid(), process::geteuid()); in test_geteuid() 25 assert_eq!(process::geteuid().as_raw(), libc::geteuid()); in test_geteuid() 26 assert_eq!(process::geteuid().is_root(), libc::geteuid() == 0); in test_geteuid() 32 assert_eq!(proces in test_getegid() [all...] |
/third_party/rust/crates/lazycell/src/ |
H A D | lib.rs | 35 //! assert_eq!(lazycell.borrow(), None); 39 //! assert_eq!(lazycell.borrow(), Some(&1)); 40 //! assert_eq!(lazycell.into_inner(), Some(1)); 358 assert_eq!(value, None); in test_borrow_from_empty() 361 assert_eq!(value, None); in test_borrow_from_empty() 373 assert_eq!(value, Some(&1)); in test_fill_and_borrow() 376 assert_eq!(value, Some(1)); in test_fill_and_borrow() 385 assert_eq!(lazycell.borrow_mut(), Some(&mut 1)); in test_borrow_mut() 388 assert_eq!(lazycell.borrow_mut(), Some(&mut 2)); in test_borrow_mut() 400 assert_eq!(lazycel in test_already_filled_error() [all...] |
/third_party/rust/crates/nom/src/sequence/ |
H A D | tests.rs | 13 assert_eq!(parser("abc123def"), Ok(("123def", ("abc",)))); in single_element_tuples() 14 assert_eq!( in single_element_tuples() 81 assert_eq!( in error_to_string() 93 assert_eq!( in pair_test() 97 assert_eq!( in pair_test() 101 assert_eq!( in pair_test() 105 assert_eq!( in pair_test() 109 assert_eq!( in pair_test() 113 assert_eq!( in pair_test() 125 assert_eq!( in separated_pair_test() [all...] |
/third_party/rust/crates/rust-openssl/openssl-errors/tests/ |
H A D | test.rs | 23 assert_eq!(error.library().unwrap(), "test library"); in basic() 24 assert_eq!(error.function().unwrap(), "function foo"); in basic() 25 assert_eq!(error.reason().unwrap(), "out of milk"); in basic() 27 assert_eq!( in basic() 31 assert_eq!(error.line(), line!() - 11); in basic() 37 assert_eq!(error.data(), None); in basic() 47 assert_eq!(error.library().unwrap(), "test library"); in static_data() 48 assert_eq!(error.function().unwrap(), "function bar"); in static_data() 49 assert_eq!(error.reason().unwrap(), "out of bacon"); in static_data() 51 assert_eq!( in static_data() [all...] |
/third_party/rust/crates/nom/src/multi/ |
H A D | tests.rs | 47 assert_eq!(multi(a), Ok((&b"ef"[..], res1))); in separated_list0_test() 49 assert_eq!(multi(b), Ok((&b"ef"[..], res2))); in separated_list0_test() 50 assert_eq!(multi(c), Ok((&b"azerty"[..], Vec::new()))); in separated_list0_test() 52 assert_eq!(multi_empty(d), Ok((&b"abc"[..], res3))); in separated_list0_test() 54 assert_eq!( in separated_list0_test() 62 assert_eq!(multi(e), Ok((&b",ef"[..], res4))); in separated_list0_test() 64 assert_eq!(multi(f), Err(Err::Incomplete(Needed::new(1)))); in separated_list0_test() 65 assert_eq!(multi_longsep(g), Err(Err::Incomplete(Needed::new(1)))); in separated_list0_test() 66 assert_eq!(multi(h), Err(Err::Incomplete(Needed::new(1)))); in separated_list0_test() 89 assert_eq!(mult in separated_list1_test() [all...] |
/third_party/rust/crates/regex/regex-syntax/src/hir/ |
H A D | translate.rs | 240 assert_eq!(self.trans().stack.borrow().len(), 1); in finish() 1376 assert_eq!(t(""), Hir::empty()); in empty() 1377 assert_eq!(t("(?i)"), Hir::empty()); in empty() 1378 assert_eq!(t("()"), hir_group(1, Hir::empty())); in empty() 1379 assert_eq!(t("(?:)"), hir_group_nocap(Hir::empty())); in empty() 1380 assert_eq!(t("(?P<wat>)"), hir_group_name(1, "wat", Hir::empty())); in empty() 1381 assert_eq!(t("|"), hir_alt(vec![Hir::empty(), Hir::empty()])); in empty() 1382 assert_eq!( in empty() 1389 assert_eq!( in empty() 1393 assert_eq!( in empty() [all...] |
/third_party/rust/crates/clap/tests/derive/ |
H A D | options.rs | 29 assert_eq!( in required_option() 33 assert_eq!( in required_option() 37 assert_eq!( in required_option() 41 assert_eq!( in required_option() 56 assert_eq!( in option_with_default() 60 assert_eq!( in option_with_default() 64 assert_eq!(Opt { arg: 42 }, Opt::try_parse_from(["test"]).unwrap()); in option_with_default() 75 assert_eq!( in option_with_raw_default() 79 assert_eq!( in option_with_raw_default() 83 assert_eq!(Op in option_with_raw_default() [all...] |
H A D | flags.rs | 30 assert_eq!(Opt { alice: false }, Opt::try_parse_from(["test"]).unwrap()); in bool_type_is_flag() 31 assert_eq!( in bool_type_is_flag() 35 assert_eq!( in bool_type_is_flag() 39 assert_eq!( in bool_type_is_flag() 66 assert_eq!(opt.alice, 5); in non_bool_type_flag() 67 assert_eq!(opt.bob, 5); in non_bool_type_flag() 70 assert_eq!(opt.alice, 10); in non_bool_type_flag() 71 assert_eq!(opt.bob, 5); in non_bool_type_flag() 74 assert_eq!(opt.alice, 5); in non_bool_type_flag() 75 assert_eq!(op in non_bool_type_flag() [all...] |
/third_party/rust/crates/humantime/src/ |
H A D | duration.rs | 227 /// assert_eq!(parse_duration("2h 37min"), Ok(Duration::new(9420, 0))); 228 /// assert_eq!(parse_duration("32ms"), Ok(Duration::new(0, 32_000_000))); 251 /// assert_eq!(format_duration(val1).to_string(), "2h 37m"); 253 /// assert_eq!(format_duration(val2).to_string(), "32ms"); 345 assert_eq!(parse_duration("17nsec"), Ok(Duration::new(0, 17))); in test_units() 346 assert_eq!(parse_duration("17nanos"), Ok(Duration::new(0, 17))); in test_units() 347 assert_eq!(parse_duration("33ns"), Ok(Duration::new(0, 33))); in test_units() 348 assert_eq!(parse_duration("3usec"), Ok(Duration::new(0, 3000))); in test_units() 349 assert_eq!(parse_duration("78us"), Ok(Duration::new(0, 78000))); in test_units() 350 assert_eq!(parse_duratio in test_units() [all...] |
/third_party/rust/crates/regex/tests/ |
H A D | api.rs | 4 assert_eq!(vec![(0, 0)], findall!(re, "")); in empty_regex_empty_match() 10 assert_eq!(vec![(0, 0), (1, 1), (2, 2), (3, 3)], findall!(re, "abc")); in empty_regex_nonempty_match() 16 assert_eq!(vec![(0, 0), (1, 2), (3, 4)], findall!(re, "a1b2")); in one_zero_length_match() 22 assert_eq!( in many_zero_length_match() 31 assert_eq!( in many_sequential_zero_length_match() 40 assert_eq!(vec![(0, 1), (1, 2)], findall!(re, "[]")); in quoted_bracket_set() 42 assert_eq!(vec![(0, 1), (1, 2)], findall!(re, "[]")); in quoted_bracket_set() 48 assert_eq!(vec![(0, 1), (1, 2)], findall!(re, "[]")); in first_range_starts_with_left_bracket() 54 assert_eq!(vec![(0, 1), (1, 2)], findall!(re, "[]")); in range_ends_with_escape() 60 assert_eq!(ve in empty_match_find_iter() [all...] |