text stringlengths 93 16.4k | id stringlengths 20 40 | metadata dict | input_ids listlengths 45 2.05k | attention_mask listlengths 45 2.05k | complexity int64 1 9 |
|---|---|---|---|---|---|
#[test]
fn test_ignoring_multiple_keys_on_get() {
let statement = get_statement!("GET KEY1 KEY2 KEY3");
assert_eq!(
statement,
Statement {
stype: StatementType::Get,
key: Some("KEY1".to_owned()),
... | rust_cleaned_test_functions.jsonl/104583 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 229
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
62,
622,
5503,
45233,
12631,
4470,
3062,
368,
341,
310,
1077,
5114,
284,
633,
37404,
17223,
3806,
12013,
16,
12013,
17,
12013,
18,
797,
310,
2060,
10714,
33673,
394,
5114,
345,
394,
21756,
341,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_reqopt_missing() {
let args = vec!("blah".to_string());
let opts = vec!(reqopt("t", "test", "testing", "TEST"));
let rs = getopts(args.as_slice(), opts.as_slice());
match rs {
Err(f) => check_fail_type(f, OptionMissing_),
_ => fail!()
}... | rust_cleaned_test_functions.jsonl/13309 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 167
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
17644,
2912,
40447,
368,
341,
286,
1077,
2827,
284,
7486,
17223,
70614,
3263,
983,
3904,
1423,
286,
1077,
12185,
284,
7486,
10297,
2958,
2912,
445,
83,
497,
330,
1944,
497,
330,
8840,
497,
330,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
#[test]
fn test_parse() {
let image = vec![1, 2, 3, 4, 5, 6, 7, 8];
let layers = parse_space_image_format(&image, 2, 1);
assert_eq!(layers.len(), 4);
let expectation = vec![vec![1, 2], vec![3, 4], vec![5, 6], vec![7, 8]];
assert_eq!(layers.cmp(&expectation), std::cmp::Or... | rust_cleaned_test_functions.jsonl/10791 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 394
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
368,
341,
286,
1077,
2168,
284,
7486,
20703,
16,
11,
220,
17,
11,
220,
18,
11,
220,
19,
11,
220,
20,
11,
220,
21,
11,
220,
22,
11,
220,
23,
4821,
286,
1077,
13617,
284,
4715,
14663,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_zero_commit_fails() {
let keychain = Keychain::from_random_seed().unwrap();
let key_id1 = keychain.derive_key_id(1).unwrap();
// blinding should fail as signing with a zero r*G shouldn't work
build::transaction(
vec![
input(10, key_id1.clone()),
output(9, key_id1.clone()),
... | rust_cleaned_test_functions.jsonl/9522 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 166
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
19359,
36346,
761,
6209,
368,
341,
197,
10217,
1376,
8819,
284,
5309,
8819,
486,
1499,
22644,
33809,
1005,
15454,
543,
197,
10217,
1376,
842,
16,
284,
1376,
8819,
75819,
533,
3097,
842,
7,
16,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_sub_call_system_no_args_allowed() {
assert_parser_err!(
"SYSTEM 42",
QError::syntax_error("Expected: end-of-statement"),
1,
7
);
} | rust_cleaned_test_functions.jsonl/27896 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 157
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
5228,
13429,
17687,
6536,
8384,
42155,
368,
341,
310,
2060,
18517,
9266,
33673,
394,
330,
46487,
220,
19,
17,
756,
394,
1207,
1454,
486,
56193,
4096,
445,
18896,
25,
835,
8668,
5477,
5605,
4461,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_list_attempts_by_msg_query_parameters_validation() {
let q: ListAttemptsByMsgQueryParameters =
serde_json::from_value(json!({ "event_types": INVALID_EVENT_TYPES })).unwrap();
assert!(q.validate().is_err());
let q: ListAttemptsByMsgQueryParameters =
... | rust_cleaned_test_functions.jsonl/64493 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 461
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
2019,
79490,
3710,
6483,
5738,
18263,
19416,
368,
341,
286,
1077,
2804,
25,
1759,
81517,
1359,
6611,
2859,
9706,
4035,
310,
61570,
9455,
486,
1499,
3142,
9304,
0,
2306,
330,
3087,
9763,
788,
32269... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_variance_with_low_d2() {
let variance = |x: FisherSnedecor| x.variance().unwrap();
get_value(0.1, 0.1, variance);
} | rust_cleaned_test_functions.jsonl/42683 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 80
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
77450,
6615,
23767,
814,
17,
368,
341,
286,
1077,
32273,
284,
760,
87,
25,
35504,
50,
18694,
757,
269,
91,
856,
19526,
5284,
1005,
15454,
543,
286,
633,
3142,
7,
15,
13,
16,
11,
220,
15,
13,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_sub() {
let mut a : felem_as_words = [11671922859260663127, 11050707557586042878, 284884720401305268, 17749945728364010941, 8613774818643959860, 145621051382923523];
let mut b : felem_as_words = [9794203289623549276, 7309342082925068282, 1139538881605221074, 15659550692327388916, 1600835... | rust_cleaned_test_functions.jsonl/91329 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 280
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
5228,
368,
341,
262,
1077,
5206,
264,
549,
1152,
3433,
11898,
18981,
284,
508,
16,
16,
21,
22,
16,
24,
17,
17,
23,
20,
24,
17,
21,
15,
21,
21,
18,
16,
17,
22,
11,
220,
16,
16,
15,
20,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_convert_from_biguint() {
assert_eq!(BigInt::from(BigUint::zero()), BigInt::zero());
assert_eq!(BigInt::from(BigUint::one()), BigInt::one());
assert_eq!(
BigInt::from(BigUint::from_slice(&[1, 2, 3])),
BigInt::from_slice(Plus, &[1, 2, 3])
);
} | rust_cleaned_test_functions.jsonl/56627 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 145
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
34910,
5673,
36386,
2496,
368,
341,
262,
2060,
10714,
10297,
87474,
486,
1499,
5349,
343,
21570,
486,
14154,
11858,
62608,
486,
14154,
1423,
262,
2060,
10714,
10297,
87474,
486,
1499,
5349,
343,
215... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_range_inclusive() {
assert!(super::range_inclusive(0, 5).eq([0, 1, 2, 3, 4, 5].iter().cloned()));
assert!(super::range_inclusive(0, 5)
.rev()
.eq([5, 4, 3, 2, 1, 0].iter().cloned()));
assert_eq!(super::range_inclusive(200, -5).count(), 0);
... | rust_cleaned_test_functions.jsonl/37394 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 420
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
9698,
1243,
8336,
368,
341,
286,
2060,
10297,
9522,
486,
9669,
1243,
8336,
7,
15,
11,
220,
20,
568,
11006,
2561,
15,
11,
220,
16,
11,
220,
17,
11,
220,
18,
11,
220,
19,
11,
220,
20,
936,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_len_with_right_trim() {
assert_eq!(len_with_right_trim(b"ATGC\n"), 4);
assert_eq!(len_with_right_trim(b"ATGC\r\n"), 4);
} | rust_cleaned_test_functions.jsonl/27395 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 93
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6043,
6615,
10539,
70025,
368,
341,
286,
2060,
10714,
10297,
2892,
6615,
10539,
70025,
1883,
1,
828,
22863,
1699,
3975,
220,
19,
317,
286,
2060,
10714,
10297,
2892,
6615,
10539,
70025,
1883,
1,
82... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_digraph_visit() {
let mut g = Digraph::new(13);
g.add_edge(0, 1);
g.add_edge(2, 0);
g.add_edge(6, 0);
g.add_edge(0, 5);
g.add_edge(3, 5);
g.add_edge(5, 4);
g.add_edge(2, 3);
g.add_edge(3, 2);
g.add_edge(4, 3);
g.add_edge(4, 2);
g.add_edge(6, 4);... | rust_cleaned_test_functions.jsonl/66716 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 585
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
814,
53867,
56484,
368,
341,
262,
1077,
5206,
342,
284,
37969,
1935,
486,
931,
7,
16,
18,
317,
262,
342,
1364,
17932,
7,
15,
11,
220,
16,
317,
262,
342,
1364,
17932,
7,
17,
11,
220,
15,
31... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_circuit_error_handler_no_service() {
// Set up disptacher and mock sender
let sender = Box::new(MockSender::default());
let mut dispatcher = Dispatcher::new(sender.box_clone());
// create empty state
let circuit_directory = CircuitDirectory::new();
... | rust_cleaned_test_functions.jsonl/93795 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 659
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
666,
37268,
4096,
10183,
6536,
12267,
368,
341,
286,
442,
2573,
705,
827,
417,
11007,
323,
7860,
4646,
198,
286,
1077,
4646,
284,
8261,
486,
931,
66436,
20381,
486,
2258,
1423,
286,
1077,
5206,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_c_return() {
let shared = ffi::Shared { z: 2020 };
let ns_shared = ffi::AShared { z: 2020 };
let nested_ns_shared = ffi::ABShared { z: 2020 };
assert_eq!(2020, ffi::c_return_primitive());
assert_eq!(2020, ffi::c_return_shared().z);
assert_eq!(2020, ffi::c_return_box().0)... | rust_cleaned_test_functions.jsonl/50895 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1082
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
666,
12511,
368,
341,
262,
1077,
6094,
284,
76956,
486,
16997,
314,
1147,
25,
220,
17,
15,
17,
15,
2605,
262,
1077,
12268,
20405,
284,
76956,
486,
1911,
71,
1605,
314,
1147,
25,
220,
17,
15,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 6 |
#[test]
fn test_panic_file() {
let mut scan = scanner_from_file("input_file.txt");
let mut out = writer_to_file("output_file.txt");
solve(&mut scan, &mut out);
} | rust_cleaned_test_functions.jsonl/129560 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 89
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
620,
31270,
2458,
368,
341,
286,
1077,
5206,
8569,
284,
20775,
5673,
2458,
445,
1355,
2458,
3909,
797,
286,
1077,
5206,
700,
284,
6916,
2346,
2458,
445,
3006,
2458,
3909,
3071,
286,
11625,
2099,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_fill_pdt_interval_sql_errors() {
use DateTimeField::*;
let test_cases = [
// Invalid syntax
(
"1.2",
Year,
"Invalid syntax at offset 1: provided Dot but expected Dash",
),
(
... | rust_cleaned_test_functions.jsonl/100330 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 579
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
30728,
620,
8047,
20541,
18063,
20196,
368,
341,
286,
990,
6520,
1877,
56162,
286,
1077,
1273,
41427,
284,
2278,
310,
442,
13882,
19482,
198,
310,
2399,
394,
330,
16,
13,
17,
756,
394,
9742,
345... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
#[test]
fn test_multiple_outs_signal_flow() {
let mut graph: RouteGraph<S, R> = RouteGraphBuilder::new().with_buffer_size(32).build();
let output = graph.add_node_with_idx(|id| {
Node::with_id(
id,
1,
Box::new(OutputRoute {
... | rust_cleaned_test_functions.jsonl/72322 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1014
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
45233,
6068,
82,
21137,
27441,
368,
341,
286,
1077,
5206,
4771,
25,
9572,
11212,
18858,
11,
431,
29,
284,
9572,
11212,
3297,
486,
931,
1005,
4197,
7776,
2368,
7,
18,
17,
568,
5834,
1428,
286,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
#[test]
fn test_highlighting_multiline_nodes_to_html() {
let source = vec![
"const SOMETHING = `",
" one ${",
" two()",
" } three",
"`",
"",
]
.join("\n");
assert_eq!(
&to_html(&source, get_language("javascript"), &JS_SHEET,).unwrap()... | rust_cleaned_test_functions.jsonl/12257 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 466
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
74546,
287,
26290,
26560,
14896,
2346,
9564,
368,
341,
262,
1077,
2530,
284,
7486,
90515,
286,
330,
1024,
73290,
7625,
1718,
284,
1565,
756,
286,
330,
220,
825,
3570,
756,
286,
330,
262,
1378,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_with_key_usages() {
let mut params: CertificateParams = Default::default();
// Set key_usages
params.key_usages = vec![
KeyUsagePurpose::DigitalSignature,
KeyUsagePurpose::KeyEncipherment,
KeyUsagePurpose::ContentCommitment,
];
// This can sign things!
params.is_ca = IsCa:... | rust_cleaned_test_functions.jsonl/3855 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 411
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6615,
3097,
11306,
1134,
368,
341,
197,
10217,
5206,
3628,
25,
31402,
4870,
284,
7899,
486,
2258,
1428,
197,
197,
322,
2573,
1376,
11306,
1134,
198,
197,
25856,
4735,
11306,
1134,
284,
7486,
90515... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
#[test]
fn test_invalid_private_key_1() {
let compressed = hex::decode("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa").unwrap();
let private_key = PrivateKey::new(&compressed.as_slice());
assert_eq!(private_key.is_err(), true);
... | rust_cleaned_test_functions.jsonl/65086 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 122
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
31433,
26249,
3097,
62,
16,
368,
341,
286,
1077,
30649,
284,
12371,
486,
18196,
445,
69440,
69440,
69440,
69440,
69440,
69440,
69440,
69440,
69440,
69440,
69440,
69440,
28458,
1827,
15454,
543,
286,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_uuid_value() {
let uuid = uuid::Uuid::parse_str("936DA01F9ABD4d9d80C702AF85C822A8").unwrap();
let value: Value = uuid.into();
let out: uuid::Uuid = value.unwrap();
assert_eq!(out, uuid);
} | rust_cleaned_test_functions.jsonl/12495 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 131
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
25540,
3142,
368,
341,
286,
1077,
16040,
284,
16040,
486,
38431,
486,
6400,
2895,
445,
24,
18,
21,
6352,
15,
16,
37,
24,
1867,
35,
19,
67,
24,
67,
23,
15,
34,
22,
15,
17,
8276,
23,
20,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_word_movement() {
let f = |s: &str| mv_magnitude(Word, s.chars());
assert_eq!(f("Hello, world!"), 5);
assert_eq!(f(", world! Another word"), 7);
} | rust_cleaned_test_functions.jsonl/78498 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 101
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
13533,
70325,
368,
341,
286,
1077,
282,
284,
760,
82,
25,
609,
495,
91,
23164,
717,
34715,
7,
10879,
11,
274,
85062,
1423,
286,
2060,
10714,
10297,
69,
445,
9707,
11,
1879,
0,
3975,
220,
20,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_ecdsa_object_pool_panic_on_wrong_type() {
let metrics_registry = MetricsRegistry::new();
let metrics = EcdsaPoolMetrics::new(metrics_registry, POOL_ECDSA, POOL_TYPE_VALIDATED);
let mut object_pool = EcdsaObjectPool::new(EcdsaMessageType::DealingSupport, metrics);
... | rust_cleaned_test_functions.jsonl/26783 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 230
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
36844,
96780,
5314,
15709,
620,
31270,
4470,
75198,
1819,
368,
341,
286,
1077,
16734,
50650,
284,
54190,
15603,
486,
931,
543,
286,
1077,
16734,
284,
468,
4385,
9081,
10551,
27328,
486,
931,
89788,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_umount() {
let vfs = Vfs::new(VfsOptions::default());
let fs1 = FakeFileSystemOne {};
let fs2 = FakeFileSystemOne {};
assert!(vfs.mount(Box::new(fs1), "/foo").is_ok());
assert!(vfs.umount("/foo").is_ok());
assert!(vfs.mount(Box::new(fs2), "/x/y").... | rust_cleaned_test_functions.jsonl/33258 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 243
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
72063,
629,
368,
341,
286,
1077,
92941,
284,
647,
3848,
486,
931,
12410,
3848,
3798,
486,
2258,
1423,
286,
1077,
8619,
16,
284,
36965,
50720,
3966,
9321,
286,
1077,
8619,
17,
284,
36965,
50720,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_lms_pos() {
let orig_text = b"GCCTTAACATTATTACGCCTA$";
let alphabet = Alphabet::new(orig_text);
let text: Vec<u8> = transform_text(orig_text, &alphabet, 1);
let n = text.len();
let mut sais = SAIS::new(n);
let pos_types = PosTypes::new(&text);
... | rust_cleaned_test_functions.jsonl/71442 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 184
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
907,
1011,
6479,
368,
341,
286,
1077,
2713,
4326,
284,
293,
1,
22863,
1162,
15204,
1706,
21614,
21614,
1706,
22863,
1162,
32,
3,
876,
286,
1077,
27790,
284,
62797,
486,
931,
54837,
4326,
317,
28... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_nullif_int_array_offset() {
let a = Int32Array::from(vec![None, Some(15), Some(8), Some(1), Some(9)]);
let a = a.slice(1, 3);
let a = a.as_any().downcast_ref::<Int32Array>().unwrap();
let comp = BooleanArray::from(vec![
Some(false),
Some(f... | rust_cleaned_test_functions.jsonl/45031 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 442
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
15162,
333,
4042,
3858,
6917,
368,
341,
286,
1077,
264,
284,
1333,
18,
17,
1857,
486,
1499,
25592,
20703,
4064,
11,
4329,
7,
16,
20,
701,
4329,
7,
23,
701,
4329,
7,
16,
701,
4329,
7,
24,
4... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_switch_threshold_across_tower_reload() {
solana_logger::setup();
// Init state
let mut vote_simulator = VoteSimulator::new(2);
let my_pubkey = vote_simulator.node_pubkeys[0];
let other_vote_account = vote_simulator.vote_pubkeys[1];
let bank0 = vote... | rust_cleaned_test_functions.jsonl/77050 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 3625
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
27652,
21858,
14718,
2128,
528,
1202,
79405,
368,
341,
286,
2048,
3362,
27413,
486,
15188,
543,
286,
442,
15690,
1584,
198,
286,
1077,
5206,
6910,
18314,
10511,
284,
34034,
14027,
10511,
486,
931,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
#[test]
fn test_overload_constructors() {
let cxx = indoc! {"
Bob::Bob() {}
Bob::Bob(uint32_t _a) :a(_a) {}
"};
let hdr = indoc! {"
#include <cstdint>
#include <memory>
struct Bob {
Bob();
Bob(uint32_t a);
uint32_t a;
... | rust_cleaned_test_functions.jsonl/9787 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 290
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
15431,
1078,
64803,
1087,
368,
341,
262,
1077,
272,
4146,
284,
1257,
509,
0,
314,
698,
286,
14261,
486,
32388,
368,
5613,
286,
14261,
486,
32388,
8488,
18,
17,
528,
716,
64,
8,
549,
64,
2490,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_merge_our_head_only() -> BitResult<()> {
BitRepo::with_minimal_repo(|repo| {
let base = commit! {};
let ours = commit! {
foo < "hello"
};
let theirs = commit! {};
repo.three_way_merge_with_base(base, ours, theirs)?;
assert_eq!(cat!(... | rust_cleaned_test_functions.jsonl/94152 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 192
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
20888,
62,
413,
13138,
18410,
368,
1464,
6495,
2077,
71698,
341,
262,
6495,
25243,
486,
4197,
7260,
2861,
37784,
22428,
23476,
91,
341,
286,
1077,
2331,
284,
5266,
0,
9321,
286,
1077,
11350,
284,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
#[test]
fn test_leader_to_validator_transition() {
logger::setup();
let leader_rotation_interval = 20;
// Make a dummy validator id to be the next leader
let validator_keypair = Keypair::new();
// Create the leader node information
let leader_keypair = Arc::new(Keypair::new());
let... | rust_cleaned_test_functions.jsonl/36558 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1625
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
79991,
2346,
64959,
53593,
368,
341,
262,
5925,
486,
15188,
543,
262,
1077,
7653,
44813,
20541,
284,
220,
17,
15,
401,
262,
442,
7405,
264,
17292,
22935,
877,
311,
387,
279,
1790,
7653,
198,
262... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 7 |
#[test]
fn test_find_best_labeling() {
let left_image = [[1, 1, 0].to_vec()].to_vec();
let right_image = [[1, 0, 0].to_vec()].to_vec();
let max_disparity: usize = 3;
let mut diffusion_graph = DiffusionGraph::initialize(left_image, right_image, max_disparity, 1.);
dif... | rust_cleaned_test_functions.jsonl/133564 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 593
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21814,
33101,
6106,
287,
368,
341,
260,
1077,
2115,
4954,
284,
4318,
16,
11,
220,
16,
11,
220,
15,
936,
983,
13251,
57590,
983,
13251,
543,
260,
1077,
1290,
4954,
284,
4318,
16,
11,
220,
15,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_parse_hexa_byte_invalid_format() {
let invalid = "0xG42";
let parsed = parse_hexa_byte(invalid);
assert!(parsed.is_err());
} | rust_cleaned_test_functions.jsonl/116174 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 89
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
32655,
64,
19737,
31433,
8955,
368,
341,
286,
1077,
8318,
284,
330,
15,
87,
38,
19,
17,
876,
286,
1077,
15676,
284,
4715,
32655,
64,
19737,
5900,
1891,
317,
286,
2060,
10297,
41030,
2079,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_authorize_with_seed() {
let authority_base_address = solana_sdk::pubkey::new_rand();
let authority_address = solana_sdk::pubkey::new_rand();
let seed = "42";
let stake_address = Pubkey::create_with_seed(&authority_base_address, seed, &id()).unwrap();
let s... | rust_cleaned_test_functions.jsonl/31637 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1981
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
22938,
551,
6615,
33809,
368,
341,
286,
1077,
11198,
7651,
6744,
284,
2048,
3362,
61783,
486,
9585,
792,
486,
931,
33864,
543,
286,
1077,
11198,
6744,
284,
2048,
3362,
61783,
486,
9585,
792,
486,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_program_id_as_payer() {
solana_logger::setup();
let (genesis_config, mint_keypair) = create_genesis_config(500);
let mut bank = Bank::new(&genesis_config);
let from_pubkey = solana_sdk::pubkey::new_rand();
let to_pubkey = solana_sdk::pubkey::new_rand();
... | rust_cleaned_test_functions.jsonl/2633 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 834
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
25096,
842,
11898,
620,
1135,
368,
341,
286,
2048,
3362,
27413,
486,
15188,
543,
286,
1077,
320,
77894,
5332,
11,
28337,
3097,
12670,
8,
284,
1855,
16322,
13774,
5332,
7,
20,
15,
15,
317,
286,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_circular_load() {
let loader = MockLoader::new();
let loads = loader.loads.clone();
let mut runtime = JsRuntime::new(RuntimeOptions {
module_loader: Some(loader),
..Default::default()
});
let fut = async move {
let spec = crate::resolve_url("file:///circula... | rust_cleaned_test_functions.jsonl/126049 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 819
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
666,
21472,
12411,
368,
341,
262,
1077,
16047,
284,
14563,
9181,
486,
931,
543,
262,
1077,
20907,
284,
16047,
22961,
15997,
543,
262,
1077,
5206,
15592,
284,
39122,
15123,
486,
931,
52610,
3798,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_good() {
let input = "Allegoric Alaskians;Blithering Badgers;win\n".to_string() +
"Devastating Donkeys;Courageous Californians;draw\n" +
"Devastating Donkeys;Allegoric Alaskians;win\n" +
"Courageous Californians;Blithering Badgers;loss\n" +
... | rust_cleaned_test_functions.jsonl/21168 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 505
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
44781,
368,
341,
262,
1077,
1946,
284,
330,
2101,
1937,
26359,
1674,
1073,
5380,
26,
4923,
2485,
287,
11461,
10637,
26,
7526,
1699,
3263,
983,
3904,
368,
3610,
394,
330,
14592,
559,
1095,
4320,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_cpi_equal() {
let mut state = State8080::empty_state();
state.memory = vec![0xfe, 0x4a];
state.a = 0x4a;
emulate_8080_op(&mut state);
assert_eq!(state.cc.cy, 0);
assert_eq!(state.cc.z, 1);
assert_eq!(state.program_counter(), 2);
} | rust_cleaned_test_functions.jsonl/7783 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 167
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
666,
2493,
11478,
368,
341,
286,
1077,
5206,
1584,
284,
3234,
23,
15,
23,
15,
486,
3194,
4387,
543,
286,
1584,
36611,
284,
7486,
20703,
15,
31469,
11,
220,
15,
87,
19,
64,
935,
286,
1584,
58... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_read_bits() {
let val: u32 = 0b1000_0000_0000_0000_0011_0101_0001_0000;
// Test a couple of successive ranges
assert!(
val.read_bits_in_range(&BitRange {
msb_index: 3,
lsb_index: 2
}) == 0b00
);
asse... | rust_cleaned_test_functions.jsonl/4120 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1641
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6443,
20034,
368,
341,
286,
1077,
1044,
25,
575,
18,
17,
284,
220,
15,
65,
16,
15,
15,
15,
62,
15,
15,
15,
15,
62,
15,
15,
15,
15,
62,
15,
15,
15,
15,
62,
15,
15,
16,
16,
62,
15,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_votes_land_in_fork_during_long_partition() {
let total_stake = 100;
// Make `lighter_stake` insufficient for switching threshold
let lighter_stake = (SWITCH_FORK_THRESHOLD as f64 * total_stake as f64) as u64;
let heavier_stake = lighter_stake + 1;
let failures_stake = total_s... | rust_cleaned_test_functions.jsonl/31919 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1996
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
65116,
60506,
1243,
761,
669,
814,
1677,
17799,
43840,
368,
341,
262,
1077,
2790,
1261,
726,
284,
220,
16,
15,
15,
280,
262,
442,
7405,
1565,
4145,
261,
1261,
726,
63,
38313,
369,
27765,
12171,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
#[test]
fn test_bank_record_transactions() {
solana_logger::setup();
let GenesisConfigInfo {
genesis_config,
mint_keypair,
..
} = create_genesis_config(10_000);
let bank = Arc::new(Bank::new_no_wallclock_throttle_for_tests(&genesis_config));
... | rust_cleaned_test_functions.jsonl/15482 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1378
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
35733,
14192,
68182,
368,
341,
286,
2048,
3362,
27413,
486,
15188,
1428,
286,
1077,
40788,
2648,
1731,
341,
310,
59366,
5332,
345,
310,
28337,
3097,
12670,
345,
310,
54538,
286,
335,
284,
1855,
16... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_vcx_credential_release() {
let _setup = SetupMocks::init();
let handle = _vcx_credential_create_with_offer_c_closure(ARIES_CREDENTIAL_OFFER).unwrap();
assert_eq!(vcx_credential_release(handle + 1), error::INVALID_CREDENTIAL_HANDLE.code_num);
assert_eq!(vcx_cred... | rust_cleaned_test_functions.jsonl/115039 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 212
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
2273,
25844,
666,
30320,
24577,
368,
341,
286,
1077,
716,
15188,
284,
18626,
72577,
486,
2327,
1428,
286,
1077,
3705,
284,
716,
7362,
87,
666,
30320,
8657,
6615,
67814,
666,
72823,
7,
934,
5369,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_old_overridden() {
let toml = r#"
unstable_features = true
imports_granularity = "Module"
"#;
let mut config = Config::from_toml(toml, Path::new("")).unwrap();
config.override_value("merge_imports", "true");
... | rust_cleaned_test_functions.jsonl/130644 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 224
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21108,
15431,
42185,
368,
341,
310,
1077,
311,
1014,
284,
435,
2,
698,
394,
44211,
14965,
284,
830,
198,
394,
15202,
15682,
276,
28979,
284,
330,
3332,
698,
310,
5869,
280,
310,
1077,
5206,
2193... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_setb_reg() {
assert_emit!(0x0f, 0x94, 0xc0; emit_setb_reg(CondCode::Equal, RAX));
assert_emit!(0x41, 0x0f, 0x95, 0xc7; emit_setb_reg(CondCode::NotEqual, R15));
assert_emit!(0x0f, 0x9d, 0xc1; emit_setb_reg(CondCode::GreaterEq, RCX));
assert_emit!(0x0f, 0x9f, 0xc2; ... | rust_cleaned_test_functions.jsonl/85456 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 302
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
2602,
65,
4920,
368,
341,
286,
2060,
69082,
10297,
15,
87,
15,
69,
11,
220,
15,
87,
24,
19,
11,
220,
15,
8148,
15,
26,
16691,
2602,
65,
4920,
7,
49696,
2078,
486,
2993,
11,
431,
2954,
1106... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_get() {
let file_name: String = String::from("/tmp/apache_license.txt");
let uri: String = String::from("https://raw.githubusercontent.com/pyrsia/.github/main/LICENSE");
let result = get(File::create(file_name.clone()).unwrap(), uri);
match futures::executor::block_on(result) {
... | rust_cleaned_test_functions.jsonl/74935 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 339
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
3062,
368,
341,
262,
1077,
1034,
1269,
25,
923,
284,
923,
486,
1499,
4283,
5173,
38737,
63839,
3909,
797,
262,
1077,
13071,
25,
923,
284,
923,
486,
1499,
445,
2428,
1110,
1041,
50927,
905,
90834... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
#[test]
fn test_protoentry_all_supported_unsupported_high_version() {
let protocols: UnvalidatedProtoEntry = "HSDir=12-100".parse().unwrap();
let unsupported: Option<UnvalidatedProtoEntry> = protocols.all_supported();
assert_eq!(true, unsupported.is_some());
assert_eq!("HSDir=12-... | rust_cleaned_test_functions.jsonl/5155 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 145
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
37689,
4085,
5705,
57885,
4907,
18216,
22680,
9438,
368,
341,
286,
1077,
31785,
25,
1230,
59590,
31549,
5874,
284,
330,
39,
5491,
404,
28,
16,
17,
12,
16,
15,
15,
3263,
6400,
1005,
15454,
543,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_ecdsa_p256_jwk_thumbprint() {
let k = KeyPair::from_pem(KEY_ECDSA_P256_PEM.as_bytes()).unwrap();
let jwk = k.jwk_public_key_thumbprint().unwrap();
assert!(jwk.is_object());
let jwk = jwk.as_object().unwrap();
assert_eq!(jwk.len(), 4);
assert!(jwk.contains_key("kty"));
... | rust_cleaned_test_functions.jsonl/72349 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 446
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
36844,
96780,
620,
17,
20,
21,
5374,
50522,
46352,
1350,
368,
341,
262,
1077,
595,
284,
5309,
12443,
486,
1499,
620,
336,
37076,
69510,
72638,
1088,
17,
20,
21,
1088,
2716,
5357,
12524,
6011,
15... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_expansions()
{
let mut test = ExpansionTester::new("tests/no_features", "testing");
test.add_source_dir("from", vec![ExpansionTester::duplicate_for_inline()]);
test.add_source_dir(
"expected",
vec![
ExpansionTester::copy(),
ExpansionTester::copy_with_prefix("inline_"),
],
);
tes... | rust_cleaned_test_functions.jsonl/116796 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 247
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
14214,
596,
908,
741,
515,
10217,
5206,
1273,
284,
54554,
58699,
486,
931,
445,
23841,
33100,
14965,
497,
330,
8840,
797,
18185,
1364,
10347,
4334,
445,
1499,
497,
7486,
20703,
71642,
58699,
486,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_delete_all_documents_and_rollback() {
let mut schema_builder = schema::Schema::builder();
let text_field = schema_builder.add_text_field("text", schema::TEXT);
let index = Index::create_in_ram(schema_builder.build());
let mut index_writer = index.writer_with_num_t... | rust_cleaned_test_functions.jsonl/21508 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 588
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
11353,
5705,
75927,
8378,
62,
33559,
368,
341,
286,
1077,
5206,
10802,
28532,
284,
10802,
486,
8632,
486,
17850,
543,
286,
1077,
1467,
5013,
284,
10802,
28532,
1364,
4326,
5013,
445,
1318,
497,
10... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_parse_lang_val_min() {
let source = format!("Add RX1 {}", LangValue::min_value());
assert_eq!(
parse(&source).unwrap().body,
vec![Node(
Statement::Operator(Node(
Operator::Add(
Node(RegisterRef::U... | rust_cleaned_test_functions.jsonl/118218 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 547
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
17876,
6189,
7260,
368,
341,
286,
1077,
2530,
284,
3561,
17223,
2212,
28170,
16,
24689,
22463,
1130,
486,
1065,
3142,
1423,
286,
2060,
10714,
33673,
310,
4715,
2099,
2427,
568,
15454,
1005,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_sufficient_stake() {
let driver = fake::FakeDriver::default();
let mut gov = Governance::new(
fixture_for_following(),
driver.get_fake_env(),
driver.get_fake_ledger(),
);
gov.proto
.neurons
.get_mut(&1)
.unwrap()
.cache... | rust_cleaned_test_functions.jsonl/1120 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 804
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
643,
26683,
1261,
726,
368,
341,
262,
1077,
5579,
284,
12418,
486,
52317,
11349,
486,
2258,
543,
262,
1077,
5206,
47625,
284,
80589,
486,
931,
1006,
286,
12507,
5478,
43490,
287,
3148,
286,
5579,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_arc_cyclic_with_zero_refs() {
struct ZeroRefs {
inner: Weak<ZeroRefs>,
}
let zero_refs = Arc::new_cyclic(|inner| {
assert_eq!(inner.strong_count(), 0);
assert!(inner.upgrade().is_none());
ZeroRefs { inner: Weak::new() }
});
assert_eq!(Arc::str... | rust_cleaned_test_functions.jsonl/42735 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 233
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
62914,
666,
65304,
6615,
19359,
60638,
368,
341,
262,
2036,
18306,
82807,
341,
286,
9179,
25,
41164,
27,
17999,
82807,
12520,
262,
456,
262,
1077,
7168,
60638,
284,
19689,
486,
931,
666,
65304,
22... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_decode_loca() {
let buffer = read_fixture("tests/fonts/opentype/test-font.ttf");
let file = ReadScope::new(&buffer).read::<OpenTypeFile>().unwrap();
match file.font {
OpenTypeFont::Single(ttf) => {
let head = ttf
.read_table(&file.scope, tag::HEAD... | rust_cleaned_test_functions.jsonl/6592 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 658
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
15227,
5560,
924,
368,
341,
262,
1077,
4147,
284,
1349,
74409,
445,
23841,
60667,
52000,
306,
499,
12697,
30671,
45192,
797,
262,
1077,
1034,
284,
4457,
10803,
486,
931,
2099,
7573,
568,
878,
2763... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
#[test]
fn test_join_err() -> Result<()> {
let df1 = df![
"a" => [1, 2],
"b" => ["foo", "bar"]
]?;
let df2 = df![
"a" => [1, 2, 3, 4],
"b" => [true, true, true, false]
]?;
assert!(df1
.join(&df2, vec![... | rust_cleaned_test_functions.jsonl/10283 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 350
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
31017,
9266,
368,
1464,
5714,
71698,
341,
286,
1077,
6764,
16,
284,
6764,
90515,
310,
330,
64,
1,
589,
508,
16,
11,
220,
17,
1259,
310,
330,
65,
1,
589,
4383,
7975,
497,
330,
2257,
7026,
286... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
#[test]
fn test_debug_format() {
// Check zero padding
let hash = Hash::new([1; 32]);
assert_eq!(format!("{:?}", &hash), "Hash(01010101)");
let pk = PublicKey::new([15; 32]);
assert_eq!(format!("{:?}", &pk), "PublicKey(0F0F0F0F)");
let sk = SecretKey::new([8; 64]... | rust_cleaned_test_functions.jsonl/5653 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 427
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
15446,
8955,
368,
341,
286,
442,
4248,
7168,
5300,
198,
286,
1077,
5175,
284,
6531,
486,
931,
2561,
16,
26,
220,
18,
17,
2558,
286,
2060,
10714,
10297,
2243,
88928,
25,
52652,
609,
8296,
701,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_parse_token_mint_with_extensions() {
let owner_pubkey = SplTokenPubkey::new(&[3; 32]);
let mint_size =
ExtensionType::get_account_len::<Mint>(&[ExtensionType::MintCloseAuthority]);
let mint_base = Mint {
mint_authority: COption::Some(owner_pubkey),... | rust_cleaned_test_functions.jsonl/103632 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1139
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
6458,
717,
396,
6615,
60498,
368,
341,
286,
1077,
6372,
34014,
792,
284,
51198,
3323,
29162,
792,
486,
931,
2099,
58,
18,
26,
220,
18,
17,
2558,
286,
1077,
28337,
2368,
4035,
310,
26473,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_from_xml() {
let xml = r#"<Types xmlns="http://schemas.openxmlformats.org/package/2006/content-types">
<Override ContentType="application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml" PartName="/word/document.xml"></Override></Types>"#;
let c = Con... | rust_cleaned_test_functions.jsonl/59504 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 284
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
5673,
23855,
368,
341,
286,
1077,
8396,
284,
435,
2,
22476,
4173,
24967,
428,
1254,
1110,
56543,
5826,
6455,
63482,
2659,
64000,
14,
17,
15,
15,
21,
27917,
20817,
881,
286,
366,
2177,
70431,
428... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_join_nulls() -> Result<()> {
let a = df![
"a" => [Some(1), None, None]
]?;
let b = df![
"a" => [Some(1), None, None, None, None]
]?;
let out = a.inner_join(&b, ["a"], ["a"])?;
assert_eq!(out.shape(), (9, 1));
Ok(()... | rust_cleaned_test_functions.jsonl/69997 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 194
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
31017,
15162,
82,
368,
1464,
5714,
71698,
341,
286,
1077,
264,
284,
6764,
90515,
310,
330,
64,
1,
589,
508,
8373,
7,
16,
701,
2240,
11,
2240,
921,
286,
2279,
37445,
286,
1077,
293,
284,
6764,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
#[test]
fn test_entry_ref_and_replace_entry_with() {
let mut a = HashMap::new();
let key = "a key";
let value = "an initial value";
let new_value = "a new value";
let entry = a.entry_ref(key).and_replace_entry_with(|_, _| panic!());
match entry {
En... | rust_cleaned_test_functions.jsonl/26982 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 722
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
9078,
7793,
8378,
10633,
9078,
6615,
368,
341,
286,
1077,
5206,
264,
284,
10528,
486,
931,
1428,
286,
1077,
1376,
284,
330,
64,
1376,
876,
286,
1077,
897,
284,
330,
276,
2856,
897,
876,
286,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
#[test]
fn test_string_diff() {
let sa = String::from("test");
let sb = String::from("another_string");
let diff = sa.diff(&sb).unwrap();
assert_eq!(diff, DiffString(Some("another_string".into())));
let sc = sa.merge(diff).unwrap();
assert_eq!(sb, sc);
} | rust_cleaned_test_functions.jsonl/95414 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 121
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
3904,
15850,
368,
341,
262,
1077,
822,
284,
923,
486,
1499,
445,
1944,
797,
262,
1077,
7898,
284,
923,
486,
1499,
445,
41963,
3904,
3071,
262,
1077,
3638,
284,
822,
40679,
2099,
16892,
568,
1545... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_unordered_list() {
assert_markdown_eq(
common::parts::unordered_list,
r###"
* one
* two
* three
"###,
);
} | rust_cleaned_test_functions.jsonl/133515 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 80
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
4907,
10544,
2019,
368,
341,
262,
2060,
18924,
2923,
10714,
1006,
286,
4185,
486,
18252,
486,
30419,
2019,
345,
286,
435,
14374,
698,
9,
825,
198,
9,
1378,
198,
9,
2326,
271,
1,
14374,
345,
26... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_lazy_is_null() {
let df = get_df();
let new = df
.clone()
.lazy()
.filter(col("sepal.width").is_null())
.collect()
.unwrap();
assert_eq!(new.height(), 0);
let new = df
.clone()
.lazy()
.filter(col("sepal.width").is... | rust_cleaned_test_functions.jsonl/109 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 335
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
49646,
6892,
15162,
368,
341,
262,
1077,
6764,
284,
633,
10894,
543,
262,
1077,
501,
284,
6764,
198,
286,
659,
19982,
741,
286,
659,
49013,
741,
286,
659,
5315,
19611,
445,
325,
19308,
5441,
182... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_parse_thread_id_element() {
assert_eq!(parse_thread_id_element(&b"0"[..]), Done(&b""[..], Id::Any));
assert_eq!(parse_thread_id_element(&b"-1"[..]), Done(&b""[..], Id::All));
assert_eq!(
parse_thread_id_element(&b"23"[..]),
Done(&b""[..], Id::Id(0x23))
);
} | rust_cleaned_test_functions.jsonl/40109 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 152
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
10814,
842,
7894,
368,
341,
262,
2060,
10714,
10297,
6400,
10814,
842,
7894,
2099,
65,
1,
15,
36864,
496,
9719,
27357,
2099,
65,
3014,
95874,
1125,
5223,
486,
8610,
1106,
262,
2060,
10714,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_transcribes_guanine_cytosine() {
assert_eq!(Ok(dna::RNA::new("C")), dna::DNA::new("G").to_rna());
} | rust_cleaned_test_functions.jsonl/107197 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 65
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
7965,
55136,
1889,
10386,
482,
666,
16415,
436,
482,
368,
341,
262,
2060,
10714,
10297,
11578,
1500,
3376,
486,
30720,
486,
931,
445,
34,
35674,
75334,
486,
55320,
486,
931,
445,
38,
1827,
983,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_events_no_data() {
let event_fd = EventFd::new(0).unwrap();
let event_set = EventSet::IN;
let events_raw = Events::new_raw(event_fd.as_raw_fd(), event_set);
let events = Events::new(&event_fd, event_set);
assert_eq!(events_raw, events);
assert_e... | rust_cleaned_test_functions.jsonl/78841 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 212
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
19691,
6536,
1769,
368,
341,
286,
1077,
1538,
17676,
284,
3665,
74476,
486,
931,
7,
15,
568,
15454,
543,
286,
1077,
1538,
2602,
284,
3665,
1649,
486,
687,
401,
286,
1077,
4357,
16067,
284,
17627... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_gjk_exact() {
let shape = Rectangle::new(1., 1.);
let t = transform(0., 0., 0.);
let gjk = GJK2::new();
let p = gjk.intersection(&CollisionStrategy::FullResolution, &shape, &t, &shape, &t);
assert!(p.is_some());
let d = gjk.distance(&shape, &t, &sh... | rust_cleaned_test_functions.jsonl/90900 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 189
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
1889,
41808,
71084,
368,
341,
286,
1077,
6083,
284,
19280,
486,
931,
7,
16,
2572,
220,
16,
58957,
286,
1077,
259,
284,
5165,
7,
15,
2572,
220,
15,
2572,
220,
15,
58957,
286,
1077,
35001,
74,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_check_secondary_locks() {
let storage = TestStorageBuilder::new(DummyLockManager {}, false)
.build()
.unwrap();
let cm = storage.concurrency_manager.clone();
let (tx, rx) = channel();
let k1 = Key::from_raw(b"k1");
let k2 = Key::fr... | rust_cleaned_test_functions.jsonl/2101 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 2143
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
7200,
77759,
9818,
82,
368,
341,
286,
1077,
5819,
284,
3393,
5793,
3297,
486,
931,
5432,
8574,
11989,
2043,
16452,
895,
340,
310,
659,
5834,
741,
310,
659,
15454,
543,
286,
1077,
9961,
284,
5819... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_needs_kick() {
let m = &GuestMemoryMmap::from_ranges(&[(GuestAddress(0), 0x10000)]).unwrap();
let vq = VirtQueue::new(GuestAddress(0), m, 16);
let mut q = vq.create_queue();
{
q.uses_notif_suppression = false;
for... | rust_cleaned_test_functions.jsonl/134255 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 880
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
13925,
6767,
4698,
865,
368,
341,
286,
1077,
296,
284,
609,
37804,
10642,
44,
2186,
486,
1499,
58748,
2099,
9697,
37804,
4286,
7,
15,
701,
220,
15,
87,
16,
15,
15,
15,
15,
7252,
568,
15454,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
#[test]
fn test_dynamic_vec_count() {
let test_data: Vec<u8> = [0x02, 0xAA, 0xBB].to_vec();
// Read
let mut ret_read = samples::VecCountDeku::try_from(test_data.as_ref()).unwrap();
assert_eq!(
samples::VecCountDeku {
count: 0x02,
vec_data: vec![0xAA, 0xBB]
... | rust_cleaned_test_functions.jsonl/123225 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 300
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
45992,
13251,
3180,
368,
341,
262,
1077,
1273,
1769,
25,
11312,
34837,
23,
29,
284,
508,
15,
87,
15,
17,
11,
220,
15,
60051,
11,
220,
15,
80197,
936,
983,
13251,
1428,
262,
442,
4457,
198,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_loopback_alpn() {
let cert = match localhost_cert() {
Some(cert) => cert,
None => return,
};
let listener = TcpListener::bind("127.0.0.1:0").unwrap();
let addr = listener.local_addr().unwrap();
let t = thread::spawn(move || {
let stream = TcpStream::conn... | rust_cleaned_test_functions.jsonl/93520 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 625
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
17198,
1419,
8418,
19958,
368,
341,
10217,
2777,
284,
2432,
47422,
37097,
368,
341,
286,
4329,
87793,
8,
589,
2777,
345,
286,
2240,
589,
470,
345,
262,
3634,
262,
1077,
11446,
284,
64876,
2743,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
#[test]
fn test_init() {
let pd = PocketDimension::new3(&Pos3(0,0,0), test_grid());
assert_eq!(pd.at(&Pos3(0,0,0)), &Cube::Inactive);
assert_eq!(pd.at(&Pos3(1,0,0)), &Cube::Active);
assert_eq!(pd.at(&Pos3(3,6,9)), &Cube::Inactive);
assert_eq!(pd.at(&Pos3(2,1,0)), &Cube::A... | rust_cleaned_test_functions.jsonl/76745 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 180
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6137,
368,
341,
286,
1077,
7744,
284,
45724,
26121,
486,
931,
18,
2099,
4859,
18,
7,
15,
11,
15,
11,
15,
701,
1273,
15604,
1423,
286,
2060,
10714,
10297,
15360,
6847,
2099,
4859,
18,
7,
15,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_sentinel() {
use rocket::{local::blocking::Client, error::ErrorKind::SentinelAborts};
let err = Client::debug_with(routes![is_reloading]).unwrap_err();
assert!(matches!(err.kind(), SentinelAborts(vec) if vec.len() == 1));
let err = Client::debug_with(routes![is_reloading, templ... | rust_cleaned_test_functions.jsonl/84749 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 694
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
24115,
29708,
368,
341,
262,
990,
24306,
22964,
2438,
486,
70356,
486,
2959,
11,
1465,
486,
1454,
10629,
486,
31358,
29708,
5830,
18955,
2315,
262,
1077,
1848,
284,
8423,
486,
8349,
6615,
44888,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_mq_setattr() {
use nix::mqueue::{mq_getattr, mq_setattr};
const MSG_SIZE: mq_attr_member_t = 32;
let initial_attr = MqAttr::new(0, 10, MSG_SIZE, 0);
let mq_name = &CString::new(b"/attr_test_get_attr".as_ref()).unwrap();
let oflag = MQ_OFlag::O_CREAT | MQ_OFlag::O_WRONLY;
... | rust_cleaned_test_functions.jsonl/28038 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 705
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
717,
80,
2602,
2991,
368,
341,
262,
990,
308,
941,
486,
76,
4584,
22964,
27674,
3062,
2991,
11,
72298,
2602,
2991,
2440,
262,
733,
23317,
4098,
25,
72298,
10422,
19388,
528,
284,
220,
18,
17,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
#[test]
fn test_boolean_builder_increases_buffer_len() {
let buf = Buffer::from([72_u8, 2_u8]);
let mut builder = BufferBuilder::<bool>::new(8);
for i in 0..10 {
if i == 3 || i == 6 || i == 9 {
builder.push(true).unwrap();
} else {
... | rust_cleaned_test_functions.jsonl/127623 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 277
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
46642,
28532,
1243,
837,
2264,
7776,
6043,
368,
341,
1789,
286,
1077,
6607,
284,
10312,
486,
1499,
2561,
22,
17,
7300,
23,
11,
220,
17,
7300,
23,
2558,
286,
1077,
5206,
7363,
284,
10312,
3297,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 5 |
#[test]
fn test_foreign_ns_func_arg_nonpod() {
let hdr = indoc! {"
#include <cstdint>
#include <memory>
namespace A {
struct Bob {
uint32_t a;
Bob(uint32_t _a) :a(_a) {}
};
}
namespace B {
inline uint... | rust_cleaned_test_functions.jsonl/9824 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 320
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
78983,
34728,
9596,
6057,
21637,
39073,
368,
341,
262,
1077,
36615,
284,
1257,
509,
0,
314,
698,
286,
671,
997,
366,
96975,
397,
286,
671,
997,
366,
17269,
397,
286,
4473,
362,
341,
310,
2036,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_add() {
let mut a = Num::from_input("[[[[4,3],4],4],[7,[[8,4],9]]]");
let b = Num::from_input("[1,1]");
a.add(b);
assert_eq!(a._format(), "[[[[0,7],4],[[7,8],[6,0]]],[8,1]]");
} | rust_cleaned_test_functions.jsonl/122923 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 139
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
2891,
368,
341,
286,
1077,
5206,
264,
284,
16212,
486,
1499,
5898,
10937,
15505,
58,
19,
11,
18,
1125,
19,
1125,
19,
14955,
22,
11,
15505,
23,
11,
19,
1125,
24,
5053,
37389,
286,
1077,
293,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_nums() {
// Complete number
assert_eq!(number(&b"0x12344+"[..]), Done(&b"+"[..], 0x12344));
assert_eq!(number(&b"012344+"[..]), Done(&b"+"[..], 0o12344));
assert_eq!(number(&b"-012344+"[..]), Done(&b"+"[..], -0o12344));
assert_eq!(number(&b"12344+"[..]), Done(&b"+"[..], 12344... | rust_cleaned_test_functions.jsonl/11380 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 666
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
51875,
368,
341,
262,
442,
18608,
1372,
198,
262,
2060,
10714,
10297,
4082,
2099,
65,
1,
15,
87,
16,
17,
18,
19,
19,
5172,
95874,
9719,
27357,
2099,
65,
77728,
95874,
1125,
220,
15,
87,
16,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_inherit_env() {
use os;
if running_on_valgrind() { return; }
let mut result = env_cmd().output().unwrap();
let output = String::from_utf8(result.stdout).unwrap();
let r = os::env();
for &(ref k, ref v) in &r {
// don't check android R... | rust_cleaned_test_functions.jsonl/5989 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 495
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
1243,
9263,
15879,
368,
341,
286,
990,
2643,
280,
286,
421,
4303,
4470,
6189,
901,
484,
368,
314,
470,
26,
555,
286,
1077,
5206,
1102,
284,
6105,
11684,
1005,
3006,
1005,
15454,
543,
286,
1077,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 5 |
#[test]
fn test_static_spendable_outputs_justice_tx_revoked_htlc_success_tx() {
let chanmon_cfgs = create_chanmon_cfgs(2);
let node_cfgs = create_node_cfgs(2, &chanmon_cfgs);
let node_chanmgrs = create_node_chanmgrs(2, &node_cfgs, &[None, None]);
let nodes = create_network(2, &node_cfgs, &node_chanmgrs);
... | rust_cleaned_test_functions.jsonl/28312 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1069
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
25360,
643,
3740,
480,
35189,
62,
38768,
17805,
38082,
10823,
49086,
17257,
18632,
17805,
368,
341,
10217,
26023,
1645,
18343,
82,
284,
1855,
45552,
1645,
18343,
82,
7,
17,
317,
10217,
2436,
18343,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_validate_signature_invalid() {
let channel_secret: &str = "hogehoge";
let signature: &str = "+uCVw4g3BuIOKnlseFJAYyFoVBFaMjxP8KXBbnIRRI0=";
let request_body: &str = r#"
{
"destination": "xxxxxxxxxx",
"events": [
{
... | rust_cleaned_test_functions.jsonl/78227 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1059
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
42681,
39859,
31433,
368,
341,
286,
1077,
5496,
21962,
25,
609,
495,
284,
330,
60622,
2636,
40532,
876,
286,
1077,
11957,
25,
609,
495,
284,
6630,
84,
19589,
86,
19,
70,
18,
59808,
3810,
42,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_txs_wal() {
let wal = SignedTxsWAL::new(FULL_TXS_PATH.to_string());
let txs_01 = mock_wal_txs();
let hash_01 = Hash::digest(Bytes::from(rlp::encode_list(&txs_01)));
wal.save(1u64, hash_01.clone(), txs_01.clone()).unwrap();
let txs_02 = mock_wal_txs();
... | rust_cleaned_test_functions.jsonl/122488 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 381
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
17805,
82,
1670,
278,
368,
341,
286,
1077,
40826,
284,
52453,
51,
18561,
54,
969,
486,
931,
7832,
1426,
18819,
50,
7944,
2389,
3904,
1423,
286,
1077,
9854,
82,
62,
15,
16,
284,
7860,
1670,
278... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_fastq_seek() {
for cap in 3..31 {
let mut reader = Reader::with_capacity(io::Cursor::new(b"@s1\nA\n+\n~\n@s2\nA\n+\n~\n@s3\nA\n+\n~\n"), cap);
let pos0 = reader.position().clone();
let rec1 = reader.next().unwrap().unwrap().to_owned_record();
let pos1 = reader... | rust_cleaned_test_functions.jsonl/40341 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 708
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
35743,
80,
74473,
368,
341,
262,
369,
2062,
304,
220,
18,
496,
18,
16,
341,
286,
1077,
5206,
6604,
284,
25166,
486,
4197,
35603,
37258,
486,
14543,
486,
931,
1883,
96270,
82,
16,
1699,
32,
169... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
#[test]
fn test_transcribes_cytosine_guanine() {
assert_eq!(dna::RibonucleicAcid::new("G"), dna::DeoxyribonucleicAcid::new("C").to_rna());
} | rust_cleaned_test_functions.jsonl/36946 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 75
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
7965,
55136,
666,
16415,
436,
482,
1889,
10386,
482,
368,
341,
262,
2060,
10714,
10297,
92877,
486,
98884,
263,
22147,
292,
11654,
307,
486,
931,
445,
38,
3975,
75334,
486,
1912,
60163,
1897,
263,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_vector_1() {
let x = [0x74, 0x65, 0x73, 0x74, 0x69, 0x6e, 0x67, 0xa];
let h_expected = [0x24, 0xf9, 0x50, 0xaa, 0xc7, 0xb9, 0xea, 0x9b
,0x3c, 0xb7, 0x28, 0x22, 0x8a, 0x0c, 0x82, 0xb6
,0x7c, 0x39, 0xe9, 0x6b, 0x4b... | rust_cleaned_test_functions.jsonl/10634 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 590
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
12247,
62,
16,
368,
341,
16885,
286,
1077,
856,
284,
508,
15,
87,
22,
19,
11,
220,
15,
87,
21,
20,
11,
220,
15,
87,
22,
18,
11,
220,
15,
87,
22,
19,
11,
220,
15,
87,
21,
24,
11,
220,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_collections_in_mapping() {
let s = "
? a sequence
: - item 1
- item 2
? a mapping
: key 1: value 1
key 2: value 2
";
let mut p = Scanner::new(s.chars());
next!(p, StreamStart(..));
next!(p, BlockMappingStart);
next!(p, Key);
next_scalar!(p, TSc... | rust_cleaned_test_functions.jsonl/91011 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 637
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
89742,
1243,
26930,
368,
341,
286,
1077,
274,
284,
6228,
30,
264,
8500,
198,
25,
481,
1509,
220,
16,
198,
220,
481,
1509,
220,
17,
198,
30,
264,
12731,
198,
25,
1376,
220,
16,
25,
897,
220,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_unbond() {
let mut deps = mock_dependencies(&[]);
let msg = InstantiateMsg {
anchor_token: "reward0000".to_string(),
staking_token: "staking0000".to_string(),
distribution_schedule: vec![
(12345, 12345 + 100, Uint128::from(1000000u128)),
(... | rust_cleaned_test_functions.jsonl/2049 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 876
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
4907,
64239,
368,
341,
262,
1077,
5206,
48178,
284,
7860,
71841,
2099,
1294,
626,
262,
1077,
3750,
284,
32288,
6611,
341,
286,
17105,
6458,
25,
330,
49007,
15,
15,
15,
15,
3263,
983,
3904,
3148,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
#[test]
fn test_create_cred_def() {
init!("true");
let (id, _) = generate_cred_def("did", SCHEMAS_JSON, "tag_1", None, Some(false)).unwrap();
assert_eq!(id, CRED_DEF_ID);
} | rust_cleaned_test_functions.jsonl/76652 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 106
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
8657,
73475,
7844,
368,
341,
286,
2930,
17223,
1866,
797,
286,
1077,
320,
307,
11,
27439,
284,
6923,
73475,
7844,
445,
22920,
497,
7531,
1799,
40092,
25356,
11,
330,
4578,
62,
16,
497,
2240,
11,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_time_machine_request_builder_complex() {
let mut builder = TimeMachineRequestBuilder::new(API_KEY, LAT, LONG, TIME);
let mut blocks = vec![ExcludeBlock::Daily, ExcludeBlock::Alerts];
builder = builder.exclude_block(ExcludeBlock::Hourly);
builder = builder.exclude... | rust_cleaned_test_functions.jsonl/24719 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 757
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
3009,
38695,
7893,
28532,
41522,
368,
341,
286,
1077,
5206,
7363,
284,
4120,
21605,
1900,
3297,
486,
931,
48953,
6600,
11,
53187,
11,
33942,
11,
22236,
317,
286,
1077,
5206,
10010,
284,
7486,
2070... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_fr_sub_assign() {
{
// Test arbitrary subtraction that tests reduction.
let mut tmp = Fr(FrRepr([0x6a68c64b6f735a2b, 0xd5f4d143fe0a1972, 0x37c17f3829267c62, 0xa2f37391f30915c]));
tmp.sub_assign(&Fr(FrRepr([0xade5adacdccb6190, 0xaa21ee0f27db3ccd, 0x2550f4704ae39086, 0x... | rust_cleaned_test_functions.jsonl/66325 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 962
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
41537,
5228,
20688,
368,
341,
262,
341,
286,
442,
3393,
24168,
75240,
429,
7032,
13951,
624,
286,
1077,
5206,
4174,
284,
2869,
7832,
81,
693,
649,
2561,
15,
87,
21,
64,
21,
23,
66,
21,
19,
6... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
#[test]
fn test_parse_frame_mask() {
let mut buf = BytesMut::from(&[0b0000_0001u8, 0b1000_0001u8][..]);
buf.extend(b"0001");
buf.extend(b"1");
assert!(Parser::parse(&mut buf, false, 1024).is_err());
let frame = extract(Parser::parse(&mut buf, true, 1024));
asser... | rust_cleaned_test_functions.jsonl/86807 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 217
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
8929,
9999,
368,
341,
286,
1077,
5206,
6607,
284,
30024,
51440,
486,
1499,
2099,
58,
15,
65,
15,
15,
15,
15,
62,
15,
15,
15,
16,
84,
23,
11,
220,
15,
65,
16,
15,
15,
15,
62,
15,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_box_slice_clone() {
let data = vec![vec![0, 1], vec![0], vec![1]];
let data2 = data.clone().into_boxed_slice().clone().to_vec();
assert_eq!(data, data2);
} | rust_cleaned_test_functions.jsonl/12935 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 90
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
10194,
26488,
54742,
368,
341,
262,
1077,
821,
284,
7486,
20703,
4083,
20703,
15,
11,
220,
16,
1125,
7486,
20703,
15,
1125,
7486,
20703,
16,
13204,
262,
1077,
821,
17,
284,
821,
15997,
1005,
181... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_sanitize_unsanitary() {
let unsanitary_tx58 = "ju9xZWuDBX4pRxX2oZkTjxU5jB4SSTgEGhX8bQ8PURNzyzqKMPPpNvWihx8zUe\
FfrbVNoAaEsNKZvGzAnTDy5bhNT9kt6KFCTBixpvrLCzg4M5UdFUQYrn1gdgjX\
pLHxcaShD81xBNaFDgnA2nkkdHnKtZt4hVSfKAmw3VRZbjrZ7L2fKZBx21CwsG\
hD6onjM2M3... | rust_cleaned_test_functions.jsonl/6342 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 566
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
643,
58652,
4907,
33082,
44806,
368,
341,
286,
1077,
6975,
276,
44806,
17805,
20,
23,
284,
330,
8613,
24,
87,
81756,
84,
3506,
55,
19,
79,
50639,
55,
17,
78,
57,
74,
51,
73,
87,
52,
20,
73... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_read_linux() {
// only run this test if linux_checkout present
let linux_dir = PathBuf::from(env!("CARGO_MANIFEST_DIR")).join("benches/assets/linux_checkout");
if linux_dir.exists() {
for each in WalkDir::new(linux_dir) {
let path = each.unwrap().path();
... | rust_cleaned_test_functions.jsonl/126464 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 168
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6443,
77463,
368,
341,
262,
442,
1172,
1598,
419,
1273,
421,
36245,
68186,
3042,
198,
262,
1077,
36245,
4334,
284,
7933,
15064,
486,
1499,
16978,
17223,
34,
7581,
46,
25143,
91120,
8291,
15197,
59... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
#[test]
fn test_workon_from_tags_prioritized() {
let config = a_config();
let logger = a_logger();
let resolved = config.resolve_after_workon(&logger, config.projects.get("test5").unwrap());
assert_that(&resolved).is_equal_to(vec!["workon4".to_string(), "workon3".to_string()]);
} | rust_cleaned_test_functions.jsonl/52622 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 122
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
11498,
263,
5673,
16333,
58782,
83443,
368,
341,
262,
1077,
2193,
284,
264,
5332,
543,
262,
1077,
5925,
284,
264,
27413,
543,
262,
1077,
19673,
284,
2193,
14691,
19844,
11498,
263,
2099,
9786,
11,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_resource_block_resource_must_be_registered() {
let p = Polar::new();
let valid_policy = "resource Org{}";
expect_error(
&p,
valid_policy,
"Invalid resource block 'Org' -- 'Org' must be a registered class.",
);
p.register... | rust_cleaned_test_functions.jsonl/31739 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 215
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
17962,
7113,
17962,
717,
590,
21263,
72683,
368,
341,
286,
1077,
281,
284,
55896,
486,
931,
543,
286,
1077,
2697,
22773,
284,
330,
9233,
33706,
6257,
876,
286,
1720,
4096,
1006,
310,
609,
79,
34... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_chunks_mut_zip() {
let v1: &mut [i32] = &mut [0, 1, 2, 3, 4];
let v2: &[i32] = &[6, 7, 8, 9, 10];
for (a, b) in v1.chunks_mut(2).zip(v2.chunks(2)) {
let sum = b.iter().sum::<i32>();
for v in a {
*v += sum;
}
}
assert_eq!(v1, [13, 14, 19, 2... | rust_cleaned_test_functions.jsonl/4137 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 199
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
65470,
29523,
42131,
368,
341,
262,
1077,
348,
16,
25,
609,
6984,
508,
72,
18,
17,
60,
284,
609,
6984,
508,
15,
11,
220,
16,
11,
220,
17,
11,
220,
18,
11,
220,
19,
935,
262,
1077,
348,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
#[test]
fn test_setup_regs() {
let hv = hypervisor::new().unwrap();
let vm = hv.create_vm().expect("new VM fd creation failed");
let vcpu = vm.create_vcpu(0).unwrap();
let expected_regs: StandardRegisters = StandardRegisters {
rflags: 0x0000000000000002u64,
... | rust_cleaned_test_functions.jsonl/21462 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 415
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21363,
36910,
368,
341,
286,
1077,
22747,
284,
9751,
31396,
486,
931,
1005,
15454,
543,
286,
1077,
10995,
284,
22747,
2520,
39008,
1005,
17119,
445,
931,
17792,
12414,
9688,
4641,
797,
286,
1077,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_new_releases() {
let mut oauth = SpotifyOAuth::default().scope("user-follow-read").build();
match get_token(&mut oauth) {
Some(token_info) => {
let client_credential = SpotifyClientCredentials::default()
.token_info(token_info)
.build()... | rust_cleaned_test_functions.jsonl/79269 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 303
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
5921,
1288,
28299,
368,
341,
262,
1077,
5206,
46415,
284,
40537,
57850,
486,
2258,
1005,
4186,
445,
872,
92585,
28806,
1827,
5834,
543,
262,
2432,
633,
6458,
2099,
6984,
46415,
8,
341,
286,
4329,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
#[test]
fn test_simple() {
let mut m = MemoryBoundedBuffer::new(12);
m.push(1, 4);
m.push(2, 4);
m.push(3, 4);
assert_eq!(
&m.iter_mut().collect::<Vec<(&mut i32, usize)>>()[..],
&[(&mut 1, 4), (&mut 2, 4), (&mut 3, 4)]
... | rust_cleaned_test_functions.jsonl/76999 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 219
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
30015,
368,
341,
310,
1077,
5206,
296,
284,
13850,
33,
13082,
4095,
486,
931,
7,
16,
17,
317,
310,
296,
2552,
7,
16,
11,
220,
19,
317,
310,
296,
2552,
7,
17,
11,
220,
19,
317,
310,
296,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_push_and_into() {
let batch_msg = BatchMessage::Track(Track {
..Default::default()
});
let context = json!({
"foo": "bar",
});
let mut batcher = Batcher::new(Some(context.clone()));
batcher.without_auto_timestamp();
... | rust_cleaned_test_functions.jsonl/35279 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 361
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
14218,
8378,
45514,
368,
341,
286,
1077,
7162,
6483,
284,
33904,
2052,
486,
15667,
7,
15667,
341,
310,
5241,
3675,
486,
2258,
741,
286,
3011,
286,
1077,
2266,
284,
2951,
0,
2262,
310,
330,
7975,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
#[test]
fn test_read_timestamp() -> IonResult<()> {
let mut cursor = ion_cursor_for(&[0x68, 0x80, 0x0F, 0xD0, 0x81, 0x81, 0x80, 0x80, 0x80]);
assert_eq!(cursor.next()?, Some(Value(IonType::Timestamp, false)));
let naive_datetime = NaiveDate::from_ymd(2000 as i32, 1 as u32, 1 as u32)
... | rust_cleaned_test_functions.jsonl/82740 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 277
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6443,
23073,
368,
1464,
44805,
2077,
71698,
341,
286,
1077,
5206,
8128,
284,
27672,
28601,
5478,
2099,
58,
15,
87,
21,
23,
11,
220,
15,
87,
23,
15,
11,
220,
15,
87,
15,
37,
11,
220,
15,
15... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.