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_2019_d11() {
let grid = vec![
"ββββββ ββββ ββββββ ββββββ ββββ ββββββ ββββββ ββ ββ",
"ββ ββ ββ ββ ββ ββ ββ ββ ββ ββ ββ ββ ββ ββ ββ ββ",
"ββ ββ ββ ββ ββ ββ ββ ββ ββ ββββββ ... | rust_cleaned_test_functions.jsonl/129949 | {
"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,
62,
17,
15,
16,
24,
814,
16,
16,
368,
341,
286,
1077,
5827,
284,
7486,
90515,
310,
330,
51678,
21460,
414,
32588,
21460,
15199,
262,
92329,
15199,
262,
92329,
15199,
414,
32588,
21460,
15199,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_parse_let() {
let input = String::from("let x = 0;");
let result = lexer::lex(&input);
parse_let_stmt(&mut result.into_iter().peekable()).unwrap();
parse_program(lexer::lex(&input)).unwrap();
} | rust_cleaned_test_functions.jsonl/83961 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 115
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
62,
1149,
368,
341,
286,
1077,
1946,
284,
923,
486,
1499,
445,
1149,
856,
284,
220,
15,
34649,
286,
1077,
1102,
284,
53259,
486,
2571,
2099,
1355,
317,
286,
4715,
62,
1149,
21824,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_stonemask() {
let x: Vec<f64> = vec![0.0; 256];
let x_length = x.len() as i32;
let fs = 44100;
let option = DioOption::new();
let f0_length: usize;
unsafe {
f0_length = GetSamplesForDIO(fs, x_length, option.frame_period... | rust_cleaned_test_functions.jsonl/20849 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 456
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
1261,
263,
336,
1073,
368,
341,
286,
1077,
856,
25,
11312,
63895,
21,
19,
29,
284,
7486,
20703,
15,
13,
15,
26,
220,
17,
20,
21,
935,
286,
1077,
856,
5118,
262,
284,
856,
19406,
368,
438,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_create_list_table_no_header_no_data() {
let data: Vec<Patient> = vec![];
assert_eq!(
format_table(create_list_table(
data,
PATIENTS_LIST_HEADER,
PATIENTS_LIST_DICOM_TAGS,
true,
)),
... | rust_cleaned_test_functions.jsonl/76485 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 216
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
8657,
2019,
5237,
6536,
8757,
6536,
1769,
368,
341,
286,
1077,
821,
25,
11312,
21604,
16389,
29,
284,
7486,
0,
15078,
286,
2060,
10714,
33673,
310,
3561,
5237,
32602,
2019,
5237,
1006,
394,
821,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_rename() {
catch(|| {
let db = TestDb::new_with_seed()?;
let jbl = db.collection("c1").rename("c2")?.get(1)?;
Ok(())
})
.unwrap();
} | rust_cleaned_test_functions.jsonl/99614 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 133
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
79399,
368,
341,
286,
2287,
79453,
341,
310,
1077,
2927,
284,
3393,
7994,
486,
931,
6615,
33809,
94136,
310,
1077,
502,
2024,
284,
2927,
17578,
445,
66,
16,
1827,
51058,
445,
66,
17,
899,
4607,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_bpf_to_bpf_depth() {
let config = Config::default();
for i in 0..config.max_call_depth {
test_interpreter_and_jit_elf!(
"tests/elfs/multiple_file.so",
[i as u8],
(
b"log" => syscalls::BpfSyscallString::call; syscalls::BpfSyscall... | rust_cleaned_test_functions.jsonl/59043 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 265
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
880,
15897,
2346,
880,
15897,
19061,
368,
341,
262,
1077,
2193,
284,
5532,
486,
2258,
543,
262,
369,
600,
304,
220,
15,
496,
1676,
6678,
13429,
19061,
341,
286,
1273,
15318,
28637,
8378,
5374,
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... | 3 |
#[test]
fn test_install_git_cannot_be_a_base_url() {
assert_that(cargo_process("install").arg("--git").arg("github.com:rust-lang-nursery/rustfmt.git"),
execs().with_status(101).with_stderr("\
error: invalid url `github.com:rust-lang-nursery/rustfmt.git`: cannot-be-a-base-URLs are not support... | rust_cleaned_test_functions.jsonl/74851 | {
"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,
34245,
68801,
666,
3401,
21263,
4306,
7651,
2903,
368,
341,
262,
2060,
70197,
1337,
12088,
11305,
445,
12248,
1827,
858,
21549,
12882,
1827,
858,
445,
5204,
905,
25,
35788,
75460,
5279,
1723,
722,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_array_ptr() {
let mut l = Lexer::<DefaultContext>::new(b"int (*foo[2]) [3]");
let p = TypeDeclaratorParser::new(&mut l);
let mut context = Context::default();
let (_, decl) = p.parse(None, None, true, &mut context).unwrap();
let decl = decl.unwrap();
... | rust_cleaned_test_functions.jsonl/117528 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1582
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
3858,
4348,
368,
341,
286,
1077,
5206,
326,
284,
85082,
27638,
3675,
1972,
6831,
931,
1883,
1,
396,
4609,
7975,
58,
17,
2467,
508,
18,
37389,
286,
1077,
281,
284,
3990,
1912,
12821,
850,
6570,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_partition_template_empty() {
use management::partition_template::part::{ColumnFormat, Part};
let protobuf = management::PartitionTemplate {
parts: vec![management::partition_template::Part {
part: Some(Part::Regex(ColumnFormat {
..... | rust_cleaned_test_functions.jsonl/65181 | {
"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,
43840,
8693,
15124,
368,
341,
286,
990,
6240,
486,
40998,
8693,
486,
4480,
22964,
2933,
4061,
11,
3660,
2315,
286,
1077,
69634,
284,
6240,
486,
49978,
7275,
341,
310,
5479,
25,
7486,
20703,
42473,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_next_rand_should_apply_rule_once() {
let mut lsys: LSystem = LSystem::new("AA".to_string());
let mut rule: HashMap<char, String> = HashMap::new();
rule.insert('A', "B".to_string());
lsys.push(rule);
let next: LSystem = lsys.next_rand();
assert!(nex... | rust_cleaned_test_functions.jsonl/101655 | {
"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,
11257,
33864,
43378,
36551,
21124,
7630,
368,
341,
286,
1077,
5206,
326,
7791,
25,
444,
2320,
284,
444,
2320,
486,
931,
445,
6029,
3263,
983,
3904,
1423,
286,
1077,
5206,
5912,
25,
10528,
21919,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_display_server_error() {
assert_eq!(
format!(
"{}",
ServerError::ConnectionError(ConnectionError::ConnectionClosed)
),
"Connection error: Connection closed."
);
assert_eq!(format!("{}", ServerError::Serve... | rust_cleaned_test_functions.jsonl/81001 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 305
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
14825,
12015,
4096,
368,
341,
286,
2060,
10714,
33673,
310,
3561,
33673,
394,
35503,
756,
394,
8422,
1454,
486,
4526,
1454,
47218,
1454,
486,
4526,
26884,
340,
310,
2837,
310,
330,
4526,
1465,
25,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_enrich_tf1x_audio() {
let v = SummaryValue(Box::new(Value::Audio(pb::summary::Audio {
sample_rate: 44100.0,
encoded_audio_string: Bytes::from_static(b"RIFFabcd"),
..Default::default()
})));
let md = v.initial_met... | rust_cleaned_test_functions.jsonl/6224 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 310
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6205,
13851,
47719,
16,
87,
29688,
368,
341,
310,
1077,
348,
284,
21517,
1130,
67758,
486,
931,
25346,
486,
14755,
76878,
486,
1708,
486,
14755,
341,
394,
6077,
9246,
25,
220,
19,
19,
16,
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_time_range() {
assert_eq!(
parse_time_range(b"-101010.123456789").ok(),
Some(TimeRange {
start: None,
end: Some(NaiveTime::from_hms_micro(10, 10, 10, 123_456))
})
);
assert_eq!(
parse_ti... | rust_cleaned_test_functions.jsonl/22051 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 992
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
3009,
9698,
368,
341,
286,
2060,
10714,
33673,
310,
4715,
3009,
9698,
1883,
34294,
16,
15,
16,
15,
16,
15,
13,
16,
17,
18,
19,
20,
21,
22,
23,
24,
1827,
562,
3148,
310,
4329,
36968,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_override() {
let withdrawer_pubkey = analog_sdk::pubkey::new_rand();
let stake_lamports = 42;
let stake_account = AccountSharedData::new_ref_data_with_space(
stake_lamports,
&StakeState::Initialized(Meta::auto(&withdrawer_pubkey)),
... | rust_cleaned_test_functions.jsonl/15309 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1517
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
22938,
551,
48576,
368,
341,
286,
1077,
14798,
261,
34014,
792,
284,
23400,
61783,
486,
9585,
792,
486,
931,
33864,
543,
286,
1077,
18279,
907,
309,
3394,
284,
220,
19,
17,
280,
286,
1077,
18279... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_extern_crate_string() {
let lib = ExternalLibrary {
namespace: "Gdk".to_owned(),
crate_name: "gdk".to_owned(),
};
assert_eq!(
get_extern_crate_string(&lib),
"extern crate gdk_sys as gdk;\n".to_owned()
);
... | rust_cleaned_test_functions.jsonl/101826 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 494
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
3062,
62,
4301,
666,
7698,
3904,
368,
341,
286,
1077,
3051,
284,
30936,
16915,
341,
310,
4473,
25,
330,
38,
7584,
3263,
983,
51973,
3148,
310,
17717,
1269,
25,
330,
70,
7584,
3263,
983,
51973,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_pipe_a_megabyte_of_data_from_another_thread() {
let data = vec![0xff; 1_000_000];
let data_copy = data.clone();
let (mut reader, mut writer) = crate::pipe().unwrap();
let joiner = thread::spawn(move || {
writer.write_all(&data_copy).unwrap();
... | rust_cleaned_test_functions.jsonl/1284 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 341
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
41862,
4306,
717,
791,
66711,
3575,
1769,
5673,
12008,
1575,
10814,
368,
341,
286,
1077,
821,
284,
7486,
20703,
15,
9020,
26,
220,
16,
62,
15,
15,
15,
62,
15,
15,
15,
935,
286,
1077,
821,
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... | 2 |
#[test]
fn test_split_isolation() {
let mut cluster = new_node_cluster(0, 2);
// Use long election timeout and short lease.
configure_for_hibernate(&mut cluster);
configure_for_lease_read(&mut cluster, Some(200), Some(10));
cluster.cfg.raft_store.raft_log_gc_count_limit = 11;
let pd_clie... | rust_cleaned_test_functions.jsonl/100490 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1029
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
17052,
6892,
34962,
368,
341,
262,
1077,
5206,
10652,
284,
501,
5084,
28441,
7,
15,
11,
220,
17,
317,
262,
442,
5443,
1293,
6223,
9632,
323,
2805,
25064,
624,
262,
14411,
5478,
1523,
18818,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 8 |
#[test]
fn test_response_struct_creation_200() {
let response_actual = HttpResponse::new(
"200",
None,
Some("xxxx".into()),
);
let response_expected = HttpResponse {
version: "HTTP/1.1",
status_code: "200",
status_text: "OK",
headers: {
let mut h = ... | rust_cleaned_test_functions.jsonl/109135 | {
"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,
9655,
15126,
46163,
62,
17,
15,
15,
368,
341,
262,
1077,
2033,
40149,
284,
17580,
486,
931,
1006,
414,
330,
17,
15,
15,
756,
414,
2240,
345,
414,
4329,
445,
18516,
3263,
18122,
14702,
262,
347... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_memo() -> Result<(), Error> {
let memo = Memo::new(&random_string());
let test = MemoTest { memo };
run_binary_channel_test(&test)
} | rust_cleaned_test_functions.jsonl/28239 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 69
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
717,
6726,
368,
1464,
5714,
68843,
4600,
29,
341,
262,
1077,
21438,
284,
56201,
486,
931,
2099,
11463,
3904,
1423,
262,
1077,
1273,
284,
56201,
2271,
314,
21438,
2605,
262,
1598,
31761,
14571,
445... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_basic_email_html() {
let email = Email::new("test-from@email.org", "test-to@email.org", "Body text")
.with_html("<html><h1>Header</h1></html>");
assert_eq!(email.to_string(), "{\"from\":\"test-from@email.org\",\"to\":\"test-to@email.org\",\"htmlbody\":\"<html><h1>Header</h1></htm... | rust_cleaned_test_functions.jsonl/67591 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 143
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
34729,
9172,
9564,
368,
341,
262,
1077,
2551,
284,
8299,
486,
931,
445,
1944,
38051,
71776,
2659,
497,
330,
1944,
4686,
71776,
2659,
497,
330,
5444,
1467,
1138,
286,
659,
4197,
9564,
9639,
1551,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_raw_condition_tree() {
let expected_sql =
"SELECT `naukio`.* FROM `naukio` WHERE (NOT ((`word` = ? OR `age` < ?) AND `paw` = ?))";
let expected_params = vec![
ParameterizedValue::Text(Cow::from("meow")),
ParameterizedValue::Integer(10),
... | rust_cleaned_test_functions.jsonl/80612 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 371
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6615,
16067,
27656,
11663,
368,
341,
286,
1077,
3601,
18063,
4035,
310,
330,
4858,
1565,
77,
2863,
74,
815,
63,
4908,
4295,
1565,
77,
2863,
74,
815,
63,
5288,
320,
14065,
1781,
63,
1158,
63,
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_mut_message() {
let mut m = TestTypesSingular::new();
{
let message_field_field = m.descriptor().get_field_by_name("message_field").unwrap();
let sub_m = message_field_field.mut_message(&mut m);
let n_field = sub_m.descriptor().get_field_by_name("n").unwrap();
... | rust_cleaned_test_functions.jsonl/74908 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 220
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
29523,
6462,
368,
341,
262,
1077,
5206,
296,
284,
3393,
4173,
50,
41880,
486,
931,
543,
262,
341,
286,
1077,
1943,
5013,
5013,
284,
296,
94802,
1005,
455,
5013,
3710,
1269,
445,
1994,
5013,
1827... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_set() {
loom::model(|| {
let rt = Builder::new_multi_thread()
.worker_threads(1)
.build()
.unwrap();
let mut set = JoinSet::new();
rt.block_on(async {
assert_eq!(set.len(), 0);
set.spawn(async { () });
... | rust_cleaned_test_functions.jsonl/39905 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 534
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
31017,
2602,
368,
341,
262,
775,
316,
486,
2528,
79453,
341,
286,
1077,
16677,
284,
20626,
486,
931,
25133,
10814,
741,
310,
659,
21462,
29725,
7,
16,
340,
310,
659,
5834,
741,
310,
659,
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... | 2 |
#[test]
fn test_termfreq() -> crate::Result<()> {
let mut schema_builder = Schema::builder();
let text_field = schema_builder.add_text_field("text", TEXT);
let schema = schema_builder.build();
let index = Index::create_in_ram(schema);
{
// writing the segment
... | rust_cleaned_test_functions.jsonl/12723 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 661
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
17464,
33540,
368,
1464,
17717,
486,
2077,
71698,
341,
286,
1077,
5206,
10802,
28532,
284,
12539,
486,
17850,
543,
286,
1077,
1467,
5013,
284,
10802,
28532,
1364,
4326,
5013,
445,
1318,
497,
15762,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_random_aggregate_public_keys() {
let control_kp = Keypair::random(&mut rand::thread_rng());
let signing_kps = vec![
Keypair::random(&mut rand::thread_rng()),
Keypair::random(&mut rand::thread_rng()),
Keypair::random(&mut rand::thread_rng()),
... | rust_cleaned_test_functions.jsonl/112216 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 460
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
22644,
20587,
14240,
27074,
12631,
368,
341,
286,
1077,
2524,
4698,
79,
284,
6569,
1082,
1310,
486,
11463,
2099,
6984,
10382,
486,
4528,
66849,
1423,
286,
1077,
15971,
4698,
1690,
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... | 1 |
#[test]
fn test_str_to_limbs() {
let (is_positive, limbs) = str_to_limbs("-5");
assert!(!is_positive);
assert_eq!(&limbs, &["5u64".to_string()]);
let (is_positive, limbs) = str_to_limbs("100");
assert!(is_positive);
assert_eq!(&limbs, &["100u64".to_string()]);
let large_num = -((1i... | rust_cleaned_test_functions.jsonl/38552 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 502
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
2895,
2346,
58191,
1279,
368,
341,
262,
1077,
320,
285,
54160,
11,
48595,
8,
284,
607,
2346,
58191,
1279,
13645,
20,
797,
262,
2060,
0,
3471,
285,
54160,
317,
262,
2060,
10714,
0,
2099,
4659,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_adaptive() {
const TEST_LEN: usize = 5000;
// by cloning we get maps with the same hasher seed
let mut first = HashMap::new();
let mut second = first.clone();
first.extend((0..TEST_LEN).map(|i| (i, i)));
second.extend((TEST_LEN..TEST_LEN * 2).map(|... | rust_cleaned_test_functions.jsonl/59552 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 336
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
10027,
27781,
368,
341,
286,
733,
13602,
15536,
25,
22301,
284,
220,
20,
15,
15,
15,
280,
286,
442,
553,
77866,
582,
633,
14043,
448,
279,
1852,
90819,
10320,
198,
286,
1077,
5206,
1156,
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... | 4 |
#[test]
fn test_runnables_module() {
let (analysis, pos) = analysis_and_position(
r#"
//- /lib.rs
<|> //empty
mod test_mod {
#[test]
fn test_foo1() {}
}
"#,
);
let runnables = analysis.runnables(pos.file_id).unwr... | rust_cleaned_test_functions.jsonl/56180 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 383
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
14007,
77,
4788,
10750,
368,
341,
286,
1077,
320,
34484,
11,
1133,
8,
284,
6358,
8378,
9661,
1006,
310,
435,
2,
698,
286,
78406,
608,
2740,
25638,
198,
286,
82639,
29,
442,
3194,
198,
286,
146... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_ipv4_remote_no_rfc1191() {
// Test receiving an IPv4 Dest Unreachable Fragmentation
// Required from a node that does not implement RFC 1191.
let dummy_config = get_dummy_config::<Ipv4Addr>();
let mut ctx = DummyEventDispatcherBuilder::from_conf... | rust_cleaned_test_functions.jsonl/94417 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1860
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
49378,
19,
36425,
6536,
1710,
8316,
16,
16,
24,
16,
368,
341,
1789,
286,
442,
3393,
12308,
458,
31560,
19,
28531,
1230,
46550,
19034,
367,
198,
286,
442,
12659,
504,
264,
2436,
429,
1558,
537,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_arrow_schema_roundtrip_lists() -> Result<()> {
let metadata: HashMap<String, String> =
[("Key".to_string(), "Value".to_string())]
.iter()
.cloned()
.collect();
let schema = Schema::new_with_metadata(
vec![
... | rust_cleaned_test_functions.jsonl/130374 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1483
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
46566,
25371,
29896,
32981,
37288,
368,
1464,
5714,
71698,
341,
286,
1077,
11160,
25,
10528,
3464,
11,
923,
29,
4035,
310,
84019,
1592,
3263,
983,
3904,
1507,
330,
1130,
3263,
983,
3904,
2140,
921... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_check_vote_threshold_without_votes() {
let tower = Tower::new_for_tests(1, 0.67);
let stakes = vec![(0, 1)].into_iter().collect();
assert!(tower.check_vote_stake_threshold(0, &stakes, 2));
} | rust_cleaned_test_functions.jsonl/61125 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 111
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
7200,
54360,
21858,
39904,
65116,
368,
341,
286,
1077,
21271,
284,
21938,
486,
931,
5478,
32509,
7,
16,
11,
220,
15,
13,
21,
22,
317,
286,
1077,
44425,
284,
7486,
0,
9697,
15,
11,
220,
16,
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_hmac_md5() {
// [Page 8] Test Vectors
let b16 = [0x0b; 16]; // 0x0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b
let aa16 = [0xaa; 16]; // 0xAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
let dd50 = [0xdd; 50];
let suites: &[(&[u8], &[u8], &str)] = &[
(b"key", b"The quick brown fox jum... | rust_cleaned_test_functions.jsonl/12662 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 387
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
1523,
11948,
32994,
20,
368,
341,
262,
442,
508,
2665,
220,
23,
60,
3393,
647,
10605,
7213,
262,
1077,
293,
16,
21,
220,
284,
508,
15,
87,
15,
65,
26,
220,
16,
21,
5265,
442,
220,
15,
87,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_mint_transfer_block_metadata() {
let (env, client) = setup_swarm_and_client_proxy(1, 0);
// This script does 4 transactions
check_create_mint_transfer(client);
// assert committed version > # of user transactions
let mut vclient = env.get_validator_client(0, Non... | rust_cleaned_test_functions.jsonl/81626 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 207
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
8657,
717,
396,
35403,
7113,
22220,
368,
341,
262,
1077,
320,
3160,
11,
2943,
8,
284,
6505,
32581,
2178,
8378,
8179,
29712,
7,
16,
11,
220,
15,
626,
262,
442,
1096,
5316,
1558,
220,
19,
14131,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_invalid_ip() {
let documents = load_document("../tests/Soft_Job_M.1519661420.A.098.html");
assert_eq!(
parse_ip(&documents),
Err(Error::FieldNotFound("ip".to_owned()))
);
} | rust_cleaned_test_functions.jsonl/87161 | {
"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,
21039,
31433,
10385,
368,
341,
286,
1077,
9293,
284,
2795,
26231,
17409,
23841,
14,
30531,
10598,
674,
1245,
13,
16,
20,
16,
24,
21,
21,
16,
19,
17,
15,
875,
13,
15,
24,
23,
2564,
797,
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_statsd_client_historgram_duration() {
let client = StatsdClient::from_sink("prefix", NopMetricSink);
let res = client.histogram_duration("key", Duration::from_nanos(210));
assert_eq!("prefix.key:210|h", res.unwrap().as_metric_str());
} | rust_cleaned_test_functions.jsonl/48381 | {
"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,
15381,
67,
8179,
1523,
5323,
1520,
25454,
368,
341,
286,
1077,
2943,
284,
29927,
67,
2959,
486,
1499,
51567,
445,
11849,
497,
451,
453,
54310,
45094,
317,
286,
1077,
592,
284,
2943,
94184,
25454,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_illegal_node_actions() -> Result<(), Error> {
let mut info = Data::new();
// Parent must exist
assert!(info.apply(&create_node!(parent: 42, id: 1, name: "child")).is_err());
// Can't reuse node IDs
info = Data::new();
info.apply(&create_node!(paren... | rust_cleaned_test_functions.jsonl/10363 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 329
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
26743,
6428,
5084,
25368,
368,
1464,
5714,
68843,
4600,
29,
341,
286,
1077,
5206,
3546,
284,
2885,
486,
931,
543,
286,
442,
17022,
1969,
3000,
198,
286,
2060,
10297,
2733,
13045,
2099,
3182,
5084,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_decode_ack_frame() {
let res = Frame::decode_ack_frame(7, 2, vec![AckRange { gap: 0, range: 3 }]);
assert!(res.is_ok());
assert_eq!(res.unwrap(), vec![(7, 5), (3, 0)]);
} | rust_cleaned_test_functions.jsonl/30435 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 116
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
15227,
48447,
8929,
368,
341,
286,
1077,
592,
284,
16321,
486,
18196,
48447,
8929,
7,
22,
11,
220,
17,
11,
7486,
20703,
55559,
6046,
314,
12929,
25,
220,
15,
11,
2088,
25,
220,
18,
88853,
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_extract_html5_not_valid_xml() {
let input = load_fixture("TEST_HTML5.html");
let links: HashSet<Uri> =
extract_links(&InputContent::from_string(&input, FileType::Html), None)
.into_iter()
.map(|r| r.uri)
.collect();
... | rust_cleaned_test_functions.jsonl/93893 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 383
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
39123,
9564,
20,
7913,
8337,
23855,
368,
341,
286,
1077,
1946,
284,
2795,
74409,
445,
10033,
56726,
20,
2564,
797,
286,
1077,
7746,
25,
18931,
27,
13899,
29,
4035,
310,
8649,
25258,
2099,
2505,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_addition() {
let a = Fp([
0x5360_bb59_7867_8032,
0x7dd2_75ae_799e_128e,
0x5c5b_5071_ce4f_4dcf,
0xcdb2_1f93_078d_bb3e,
0xc323_65c5_e73f_474a,
0x115a_2a54_89ba_be5b,
]);
let b = Fp([
0x9fd2_8773_3d23_dda0,
0xb16b_f2af_738b... | rust_cleaned_test_functions.jsonl/23230 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 520
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
2891,
680,
368,
341,
262,
1077,
264,
284,
434,
79,
8956,
286,
220,
15,
87,
20,
18,
21,
15,
50255,
20,
24,
62,
22,
23,
21,
22,
62,
23,
15,
18,
17,
345,
286,
220,
15,
87,
22,
631,
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... | 1 |
#[test]
fn test_underscored_namespace_for_inner_type() {
let hdr = indoc! {"
namespace __foo {
struct daft {
struct bob {
int a;
};
int a;
};
}
inline void bar(__foo::daft::bob) {}
"};
... | rust_cleaned_test_functions.jsonl/9909 | {
"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,
62,
53933,
67,
41571,
5478,
34345,
1819,
368,
341,
262,
1077,
36615,
284,
1257,
509,
0,
314,
698,
286,
4473,
1304,
7975,
341,
310,
2036,
2994,
723,
341,
394,
2036,
35192,
341,
503,
526,
264,
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_can_cast_types() {
// this function attempts to ensure that can_cast_types stays
// in sync with cast. It simply tries all combinations of
// types and makes sure that if `can_cast_types` returns
let all_types = get_all_types();
for array in ge... | rust_cleaned_test_functions.jsonl/45442 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 731
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
27421,
5303,
9763,
368,
341,
286,
442,
419,
729,
13553,
311,
5978,
429,
646,
5303,
9763,
26558,
198,
286,
442,
304,
12811,
448,
6311,
13,
220,
1084,
4936,
16297,
678,
27459,
315,
198,
286,
442,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_ecdsa_p256_pkcs8() {
generic_test(
confg_toml(),
"tests/named_test_configs/dnssec/ecdsa_p256.pk8",
KeyFormat::Pkcs8,
Algorithm::ECDSAP256SHA256,
);
} | rust_cleaned_test_functions.jsonl/110029 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 123
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
36844,
96780,
620,
17,
20,
21,
33321,
4837,
23,
368,
341,
262,
13954,
4452,
1006,
286,
2335,
70,
528,
316,
75,
3148,
286,
330,
23841,
9612,
3606,
4452,
59150,
3446,
4412,
5024,
73058,
96780,
620... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_selector_pseudo_last_child() -> Result {
let html = r#"
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>:last-child</title>
</head>
<body>
<ul>
<li>item1</li>
<li>item2</li>
<li>item3</li>
<li>it... | rust_cleaned_test_functions.jsonl/58023 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 464
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
28890,
620,
21952,
12195,
17268,
368,
1464,
5714,
341,
10217,
5272,
284,
435,
2,
698,
262,
71341,
50139,
5272,
397,
262,
366,
1551,
8688,
428,
268,
881,
414,
366,
1983,
397,
286,
366,
5490,
1161... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_verify() {
let pvk = PreparedVerifyingKey::<DummyEngine> {
alpha_g1_beta_g2: Fr(Wrapping(18634)),
neg_gamma_g2: Fr(Wrapping(11181)),
neg_delta_g2: Fr(Wrapping(59032)),
ic: vec![Fr(Wrapping(14034)), Fr(Wrapping(58774))],
};
... | rust_cleaned_test_functions.jsonl/14322 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 334
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
35638,
368,
341,
286,
1077,
33491,
74,
284,
87167,
10141,
7766,
1592,
27638,
43344,
4571,
29,
341,
310,
8287,
1889,
16,
49292,
1889,
17,
25,
2869,
14031,
81,
3629,
7,
16,
23,
21,
18,
19,
6965,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_clear() {
let mut ll = LinkedList::<u8>::with_capacity(10);
ll.push_head(0);
ll.push_head(1);
ll.push_head(2);
assert_eq!(ll.len(), 3);
assert_eq!(ll.capacity(), 10);
ll.clear();
assert_eq!(ll.len(), 0);
assert_eq!(ll.capaci... | rust_cleaned_test_functions.jsonl/59893 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 185
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21811,
368,
341,
286,
1077,
5206,
9323,
284,
22917,
27638,
84,
23,
6831,
4197,
35603,
7,
16,
15,
317,
286,
9323,
2552,
13138,
7,
15,
317,
286,
9323,
2552,
13138,
7,
16,
317,
286,
9323,
2552,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_schema_promotion() {
// Each value represents the expected decoded value when promoting a value previously encoded with a promotable schema
let promotable_schemas = vec![r#""int""#, r#""long""#, r#""float""#, r#""double""#];
let promotable_values = vec![
Value::Int(219),... | rust_cleaned_test_functions.jsonl/129453 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 656
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
25371,
47877,
5956,
368,
341,
1066,
262,
442,
8886,
897,
10868,
279,
3601,
29213,
897,
979,
22136,
264,
897,
8597,
20498,
448,
264,
18408,
480,
10802,
198,
262,
1077,
18408,
480,
643,
31126,
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... | 3 |
#[test]
fn test_unreachable_not_reached_1() {
let working_config = r#"
e.Bar.filename = "blah"
"#;
let mut c = Config::default();
c.merge(File::from_str(working_config, FileFormat::Toml)).unwrap();
let c: CFG = c.try_into().unwrap();
} | rust_cleaned_test_functions.jsonl/125319 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 150
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
4907,
46550,
7913,
1288,
3854,
62,
16,
368,
341,
286,
1077,
3238,
5332,
284,
435,
2,
698,
310,
384,
40520,
30882,
284,
330,
70614,
698,
286,
5869,
401,
286,
1077,
5206,
272,
284,
5532,
486,
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_parsefail() {
test_parsefail_1("PT.S");
test_parsefail_1("PT.0S");
test_parsefail_1("PT0.S");
test_parsefail_1("PTS");
test_parsefail_1("PT-S");
test_parsefail_1("PT-.S");
test_parsefail_1("PT-0.S");
test_parsefail_1("PT-.0S");
test_parsefail_1("AT0S");
te... | rust_cleaned_test_functions.jsonl/60409 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 406
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
18403,
368,
341,
262,
1273,
21039,
18403,
62,
16,
445,
2828,
808,
797,
262,
1273,
21039,
18403,
62,
16,
445,
2828,
13,
15,
50,
797,
262,
1273,
21039,
18403,
62,
16,
445,
2828,
15,
808,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_astar_admissible_inconsistent() {
let mut g = Graph::new();
let a = g.add_node("A");
let b = g.add_node("B");
let c = g.add_node("C");
let d = g.add_node("D");
g.add_edge(a, b, 3);
g.add_edge(b, c, 3);
g.add_edge(c, d, 3);
g.add_edge(a, c, 8);
g.add_edge(a... | rust_cleaned_test_functions.jsonl/46744 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 328
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
48019,
277,
10027,
44064,
1243,
78399,
368,
341,
262,
1077,
5206,
342,
284,
12165,
486,
931,
543,
262,
1077,
264,
284,
342,
1364,
5084,
445,
32,
797,
262,
1077,
293,
284,
342,
1364,
5084,
445,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_dup_order_hashes() {
let hashes = vec![
Hasher::digest(Bytes::from("test1")),
Hasher::digest(Bytes::from("test2")),
Hasher::digest(Bytes::from("test3")),
Hasher::digest(Bytes::from("test4")),
Hasher::digest(Bytes::from("test2")),
];
assert!(che... | rust_cleaned_test_functions.jsonl/18544 | {
"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,
51932,
7869,
91616,
368,
341,
262,
1077,
50257,
284,
7486,
90515,
286,
6531,
261,
486,
36339,
76423,
486,
1499,
445,
1944,
16,
30154,
286,
6531,
261,
486,
36339,
76423,
486,
1499,
445,
1944,
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... | 1 |
#[test]
fn test_matmul_arcarray() {
let mut A = ArcArray::<usize, _>::zeros((2, 3));
for (i, elt) in A.iter_mut().enumerate() {
*elt = i;
}
let mut B = ArcArray::<usize, _>::zeros((3, 4));
for (i, elt) in B.iter_mut().enumerate() {
*elt = i;
}
let c = A.dot(&B);
... | rust_cleaned_test_functions.jsonl/92587 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 364
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
16610,
24160,
62914,
1653,
368,
341,
262,
1077,
5206,
362,
284,
19689,
1857,
27638,
51878,
11,
716,
6831,
35716,
1188,
17,
11,
220,
18,
1106,
262,
369,
320,
72,
11,
54139,
8,
304,
362,
19471,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_appl_ver_id() {
define_fixt_message!(TestMessage: b"9999" => {
REQUIRED, text: Text [FIX50..],
});
define_dictionary!(Logon, Reject, TestMessage,);
//appropriate Reject message and notification.
{
//Connect and logon.
let (mut test_server, mut c... | rust_cleaned_test_functions.jsonl/29 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1526
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21093,
500,
26042,
842,
368,
341,
262,
6979,
36060,
83,
6462,
10297,
2271,
2052,
25,
293,
1,
24,
24,
24,
24,
1,
589,
341,
286,
66577,
11,
1467,
25,
2918,
508,
39690,
20,
15,
496,
1259,
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... | 3 |
#[test]
fn test_authorized_authorize() {
let staker = Pubkey::new_rand();
let mut authorized = Authorized::auto(&staker);
let mut signers = HashSet::new();
assert_eq!(
authorized.authorize(&signers, &staker, StakeAuthorize::Staker),
Err(InstructionError::M... | rust_cleaned_test_functions.jsonl/39429 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 244
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
62,
19084,
22938,
551,
368,
341,
286,
1077,
357,
4407,
284,
22611,
792,
486,
931,
33864,
543,
286,
1077,
5206,
18630,
284,
90569,
486,
3902,
2099,
267,
4407,
317,
286,
1077,
5206,
1841,
388,
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... | 1 |
#[test]
fn test_write_channel_config_data_too_large() {
let config = OtaUpdateChannelConfig {
channel_name: "channel".repeat(1000),
tuf_config_name: "tuf".to_string(),
};
assert_matches!(write_channel_config(&config), Err(ChannelConfigError::DataLength(_)));
} | rust_cleaned_test_functions.jsonl/43612 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 141
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
9165,
14571,
5332,
1769,
2346,
78,
45228,
368,
341,
286,
1077,
2193,
284,
506,
2565,
4289,
9629,
2648,
341,
310,
5496,
1269,
25,
330,
10119,
3263,
30624,
7,
16,
15,
15,
15,
1326,
310,
259,
170... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_v_with_property_many_v2() {
let client = graph_serializer(GraphSON::V2);
drop_vertices(&client, "test_add_v_with_property_many").unwrap();
let g = traversal().with_remote(client.clone());
let results = g
.add_v("test_add_v_with_property_many")
.property_man... | rust_cleaned_test_functions.jsonl/26279 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 663
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
2891,
2273,
6615,
16638,
22101,
2273,
17,
368,
341,
262,
1077,
2943,
284,
4771,
67441,
63779,
2703,
486,
53,
17,
626,
262,
5943,
37720,
2099,
2972,
11,
330,
1944,
2891,
2273,
6615,
16638,
22101,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_null_offset() -> Result<()> {
let int_builder = Int64Builder::new(24);
let mut builder = ListBuilder::<Int64Builder>::new(int_builder);
builder.values().append_slice(&[1, 2, 3])?;
builder.append(true)?;
builder.values().append_slice(&[4, 5])?;
... | rust_cleaned_test_functions.jsonl/102338 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 454
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
2019,
15162,
6917,
368,
1464,
5714,
71698,
341,
286,
1077,
526,
28532,
284,
1333,
21,
19,
3297,
486,
931,
7,
17,
19,
317,
286,
1077,
5206,
7363,
284,
1759,
3297,
27638,
1072,
21,
19,
3297,
683... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 9 |
#[test]
fn test_primitive_array_modulus_scalar() {
let a = Int32Array::from(vec![15, 14, 9, 8, 1]);
let b = 3;
let c = modulus_scalar(&a, b).unwrap();
let expected = Int32Array::from(vec![0, 2, 0, 2, 1]);
assert_eq!(c, expected);
} | rust_cleaned_test_functions.jsonl/120271 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 147
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
84087,
3858,
7480,
19425,
41652,
368,
341,
286,
1077,
264,
284,
1333,
18,
17,
1857,
486,
1499,
25592,
20703,
16,
20,
11,
220,
16,
19,
11,
220,
24,
11,
220,
23,
11,
220,
16,
2558,
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_stat_and_fstat() {
let filename = b"target/foo.txt".as_ref();
let fd = open(filename, O_CREAT, S_IWUSR).unwrap(); // create empty file
let stat_result = stat(filename);
assert_stat_results(stat_result);
let fstat_result = fstat(fd);
assert_stat_results(fstat_result);
... | rust_cleaned_test_functions.jsonl/111022 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 155
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
16271,
8378,
761,
9878,
368,
341,
262,
1077,
3899,
284,
293,
1,
5657,
60555,
3909,
3263,
300,
7793,
543,
262,
1077,
12414,
284,
1787,
10961,
11,
506,
70802,
11,
328,
86421,
49558,
568,
15454,
21... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_should_process_or_forward_packets() {
let my_pubkey = solana_sdk::pubkey::new_rand();
let my_pubkey1 = solana_sdk::pubkey::new_rand();
assert_eq!(
BankingStage::consume_or_forward_packets(&my_pubkey, None, true, false,),
BufferedPacketsDecision::H... | rust_cleaned_test_functions.jsonl/5944 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 751
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
43378,
11305,
8734,
32121,
63569,
368,
341,
286,
1077,
847,
34014,
792,
284,
2048,
3362,
61783,
486,
9585,
792,
486,
931,
33864,
543,
286,
1077,
847,
34014,
792,
16,
284,
2048,
3362,
61783,
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_stream2() {
// generated by KERIOX
let stream = r#"{"vs":"KERI10JSON00012a_","pre":"E4_CHZxqydVAvJEI7beqk3TZwUR92nQydi1nI8UqUTxk","sn":"0","ilk":"icp","sith":"1","keys":["DLfozZ0uGvLED22X3K8lX6ciwhl02jdjt1DQ_EHnJro0","C6KROFI5gWRXhAiIMiHLCDa-Oj09kmVMr2btCE96k_3g"],"nxt":"E99mhvP0pLkGtxym... | rust_cleaned_test_functions.jsonl/105158 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 358
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
12673,
17,
368,
341,
262,
442,
7907,
553,
730,
640,
3810,
55,
198,
262,
1077,
4269,
284,
435,
55543,
4913,
11562,
3252,
79842,
40,
16,
15,
5370,
15,
15,
15,
16,
17,
64,
62,
2198,
1726,
3252,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_proto_user_host_port() {
let addr = "ssh://test-user@127.0.0.1:2222";
let parsed_addr = parse_user_host_port(addr).unwrap();
assert_eq!("ssh", parsed_addr.proto.unwrap());
assert_eq!("test-user", parsed_addr.user.unwrap());
assert_eq!("127.0.0.1", parsed_addr.host.unwra... | rust_cleaned_test_functions.jsonl/56552 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 165
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
37689,
3317,
12848,
8716,
368,
341,
262,
1077,
10789,
284,
330,
25537,
1110,
1944,
8694,
31,
16,
17,
22,
13,
15,
13,
15,
13,
16,
25,
17,
17,
17,
17,
876,
262,
1077,
15676,
7387,
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... | 1 |
#[test]
fn test_bootstrap() {
let path = Builder::new().prefix("var").tempdir().unwrap();
let raft_path = path.path().join("raft");
let kv_engine = engine_test::kv::new_engine(
path.path().to_str().unwrap(),
None,
&[CF_DEFAULT, CF_RAFT],
No... | rust_cleaned_test_functions.jsonl/52507 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1009
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
88424,
368,
341,
286,
1077,
1815,
284,
20626,
486,
931,
1005,
11849,
445,
947,
1827,
3888,
3741,
1005,
15454,
543,
286,
1077,
52455,
2638,
284,
1815,
3875,
1005,
5987,
445,
2944,
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_error_messages() {
assert_eq!(
format!(
"{}",
LoggerError::NeverInitialized(String::from("Bad Log Path Provided"))
),
"Bad Log Path Provided"
);
assert_eq!(
format!("{}", LoggerError::AlreadyI... | rust_cleaned_test_functions.jsonl/13481 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 419
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
4096,
23428,
368,
341,
286,
2060,
10714,
33673,
310,
3561,
33673,
394,
35503,
756,
394,
9514,
1454,
486,
26155,
22495,
2242,
486,
1499,
445,
17082,
2835,
7933,
53874,
5455,
310,
2837,
310,
330,
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... | 1 |
#[test]
fn test_filter_array_slice() {
let a = Int32Array::from_slice(&[5, 6, 7, 8, 9]).slice(1, 4);
let b = BooleanArray::from_slice(vec![true, true, false, false, true]).slice(1, 4);
let c = filter(&a, &b).unwrap();
let expected = Int32Array::from_slice(&[6, 9]);
asse... | rust_cleaned_test_functions.jsonl/64053 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 165
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
8727,
3858,
26488,
368,
341,
286,
1077,
264,
284,
1333,
18,
17,
1857,
486,
1499,
26488,
2099,
58,
20,
11,
220,
21,
11,
220,
22,
11,
220,
23,
11,
220,
24,
10697,
24963,
7,
16,
11,
220,
19,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_const_from_ref() {
const VALUE: &i32 = &1;
const SLICE: &[i32] = core::slice::from_ref(VALUE);
assert!(core::ptr::eq(VALUE, &SLICE[0]))
} | rust_cleaned_test_functions.jsonl/9713 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 84
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
13610,
5673,
7793,
368,
341,
262,
733,
26827,
25,
609,
72,
18,
17,
284,
609,
16,
280,
262,
733,
16797,
5487,
25,
44590,
72,
18,
17,
60,
284,
6200,
486,
24963,
486,
1499,
7793,
98893,
626,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
#[test]
fn test_install_mode_failing() {
let (at, mut ucmd) = at_and_ucmd!();
let dir = "target_dir";
let file = "source_file";
let mode_arg = "--mode=999";
at.touch(file);
at.mkdir(dir);
ucmd.arg(file)
.arg(dir)
.arg(mode_arg)
.fails()
.stderr_contai... | rust_cleaned_test_functions.jsonl/47022 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 240
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
34245,
7302,
761,
14277,
368,
341,
262,
1077,
320,
266,
11,
5206,
575,
8710,
8,
284,
518,
8378,
68887,
2277,
0,
543,
262,
1077,
5419,
284,
330,
5657,
4334,
876,
262,
1077,
1034,
284,
330,
2427... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_connect() {
use std::str::FromStr;
let socket_address = SocketAddr::from_str("18.34.3.4:7777").unwrap();
let time = Utc::now();
let (public_key, secret_key) = gen_keypair();
// write
let connect = Connect::new(
&public_key,
socket_address,
time,
... | rust_cleaned_test_functions.jsonl/118854 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 256
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
15720,
368,
341,
262,
990,
1460,
486,
495,
486,
3830,
2580,
401,
262,
1077,
7575,
6744,
284,
20954,
13986,
486,
1499,
2895,
445,
16,
23,
13,
18,
19,
13,
18,
13,
19,
25,
22,
22,
22,
22,
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_poly_map_consuming() {
let h = hlist![9000, "joe", 41f32, "schmoe", 50];
impl Func<i32> for P {
type Output = bool;
fn call(args: i32) -> Self::Output {
args > 100
}
}
impl<'a> Func<&'a str> for P {
t... | rust_cleaned_test_functions.jsonl/24760 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 428
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
36133,
5376,
3382,
61117,
368,
341,
286,
1077,
305,
284,
305,
1607,
20703,
24,
15,
15,
15,
11,
330,
73,
4644,
497,
220,
19,
16,
69,
18,
17,
11,
330,
21062,
76,
4644,
497,
220,
20,
15,
935,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_builder_i32_alloc_zero_bytes() {
let mut b = Int32BufferBuilder::new(0);
b.append(123).unwrap();
let a = b.finish();
assert_eq!(4, a.len());
} | rust_cleaned_test_functions.jsonl/30960 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 104
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
28532,
5318,
18,
17,
14802,
19359,
12524,
368,
341,
286,
1077,
5206,
293,
284,
1333,
18,
17,
4095,
3297,
486,
931,
7,
15,
317,
286,
293,
2057,
7,
16,
17,
18,
568,
15454,
543,
286,
1077,
264,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_mode() {
let f = |x: Gamma| x.mode().unwrap();
let test = [((1.0, 0.1), 0.0), ((1.0, 1.0), 0.0)];
for &(arg, res) in test.iter() {
test_case_special(arg, res, 10e-6, f);
}
let test = [((10.0, 10.0), 0.9), ((10.0, 1.0), 9.0), ((10.0, INF), 0.0)]... | rust_cleaned_test_functions.jsonl/39875 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 245
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
7302,
368,
341,
286,
1077,
282,
284,
760,
87,
25,
57682,
91,
856,
22981,
1005,
15454,
543,
286,
1077,
1273,
284,
508,
1188,
16,
13,
15,
11,
220,
15,
13,
16,
701,
220,
15,
13,
15,
701,
1781... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_parse_null() {
test_parse_err::<()>(
&[
("n", "expected ident at line 1 column 1"),
("nul", "expected ident at line 1 column 3"),
("nulla", "trailing characters at line 1 column 5"),
],
);
test_parse_ok(
vec![
("nul... | rust_cleaned_test_functions.jsonl/88643 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 177
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
15162,
368,
341,
262,
1273,
21039,
9266,
27638,
368,
17055,
286,
609,
9640,
310,
3489,
77,
497,
330,
7325,
3524,
518,
1555,
220,
16,
3250,
220,
16,
4461,
310,
3489,
77,
360,
497,
330,
7... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_split_record() {
let record = r#"2011-11-11T11:11:11.000000Z REDACTED_ELB_NAME 111.11.11.111:11111 11.1.1.1:11 0.00004 0.012272 0.000039 404 404 0 120 "GET https://11.11.111.111:111/login.action HTTP/1.1" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv" ECDHE-RSA-AES128-GCM-SHA256 TLSv1.2"#... | rust_cleaned_test_functions.jsonl/33952 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 947
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
17052,
14192,
368,
341,
262,
1077,
3255,
284,
435,
55543,
17,
15,
16,
16,
12,
16,
16,
12,
16,
16,
51,
16,
16,
25,
16,
16,
25,
16,
16,
13,
15,
15,
15,
15,
15,
15,
57,
25810,
6823,
1479,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_invalid_config() -> Result<()> {
let c = Config {
read_count: 10,
dir: None,
max_elements: None,
max_bytes: None,
flush_on_evnt: None,
};
let r = WalFactory::new().from_node(1, &NodeConfig::from_config("wal-test... | rust_cleaned_test_functions.jsonl/595 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 343
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
31433,
5332,
368,
1464,
5714,
71698,
341,
286,
1077,
272,
284,
5532,
341,
310,
1349,
3180,
25,
220,
16,
15,
345,
310,
5419,
25,
2240,
345,
310,
1932,
22801,
25,
2240,
345,
310,
1932,
12524,
25... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_convert_humidity() {
let test_data = [
(0x0000, 0),
// Datasheet setion 5.11 "Conversion of Sensor Output"
(((0b1010_0001 as u16) << 8) | 0b0011_0011, 62968),
];
for td in &test_data {
assert_eq!(convert_humidity(td.0), td.1... | rust_cleaned_test_functions.jsonl/6823 | {
"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,
34910,
1523,
73926,
368,
341,
286,
1077,
1273,
1769,
284,
2278,
310,
320,
15,
87,
15,
15,
15,
15,
11,
220,
15,
1326,
310,
442,
422,
19346,
3674,
738,
290,
220,
20,
13,
16,
16,
330,
48237,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_decoder_invalid_lone_lower_surrogate_partial() {
let mut d = UTF_16BE.decoder();
assert_feed_ok!(d, [], [0xdc], "");
assert_feed_err!(d, [], [0x00], [], "");
assert_feed_ok!(d, [0x12, 0x34], [0xdc], "\u1234");
assert_feed_err!(d, [], [0x00], [0x56, 0x78], ... | rust_cleaned_test_functions.jsonl/15683 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 345
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
49843,
31433,
907,
603,
30425,
49946,
48373,
52068,
368,
341,
286,
1077,
5206,
294,
284,
20076,
62,
16,
21,
11594,
74047,
543,
286,
2060,
42390,
19817,
10297,
67,
11,
10071,
508,
15,
48361,
1125,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_tcp_transport_mutual_auth() {
test_transport_success(
APTOS_TCP_TRANSPORT.clone(),
Auth::Mutual,
"/ip4/127.0.0.1/tcp/0",
expect_ip4_tcp_noise_addr,
);
} | rust_cleaned_test_functions.jsonl/15625 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 125
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
45562,
46398,
29523,
928,
14014,
368,
341,
262,
1273,
46398,
18632,
1006,
286,
362,
2828,
3126,
50614,
30967,
54800,
15997,
3148,
286,
7366,
486,
51440,
928,
345,
286,
3521,
573,
19,
14,
16,
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 |
#[test]
fn test_create() {
let path = Path::new("test.txt");
let mut mock = MockFileBackend::new();
mock.expect_create()
.with(eq(path))
.times(1)
.returning(|x| Err(Error::new(ErrorKind::Unsupported, "test-error")));
let fs = FileSystem {
... | rust_cleaned_test_functions.jsonl/100440 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 210
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
8657,
368,
341,
286,
1077,
1815,
284,
7933,
486,
931,
445,
1944,
3909,
797,
286,
1077,
5206,
7860,
284,
14563,
1703,
29699,
486,
931,
543,
286,
7860,
25952,
8657,
741,
310,
659,
4197,
69909,
558... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_cred_def_id_as_fully_qualified_with_schema_as_seq_no() {
_cred_def_id_qualified_with_schema_as_seq_no()
.validate()
.unwrap();
} | rust_cleaned_test_functions.jsonl/38096 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 124
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
42681,
73475,
7844,
842,
11898,
761,
21965,
62,
36335,
6615,
25371,
11898,
14486,
6536,
368,
341,
310,
716,
10844,
7844,
842,
62,
36335,
6615,
25371,
11898,
14486,
6536,
741,
394,
659,
7067,
741,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_no_quotes() -> Result<()> {
let rolling_stones = r#"
linenum,last_name,first_name
1,Jagger,Mick
2,O"Brian,Mary
3,Richards,Keith
4,L"Etoile,Bennet
5,Watts,Charlie
6,Smith,D"Shawn
7,Wyman,Bill
8,Woods,Ron
9,Jones,Brian
"#;
let file = Cursor::new(rolling_stones);
let df = C... | rust_cleaned_test_functions.jsonl/57582 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 218
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6536,
75637,
368,
1464,
5714,
71698,
341,
286,
1077,
20097,
1261,
3154,
284,
435,
2,
698,
3732,
9018,
92896,
1269,
11,
3896,
1269,
198,
16,
58862,
10114,
27014,
865,
198,
17,
74349,
1,
50088,
27... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_removes() {
let mut map: BiHashMap<String, usize> = BiHashMap::new();
map.insert("ONE".to_string(), 1);
map.insert("TWO".to_string(), 2);
map.insert("THREE".to_string(), 3);
let removed = map.remove_by_key("ONE");
assert_eq!(removed, Some(("ONE".t... | rust_cleaned_test_functions.jsonl/76189 | {
"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,
19194,
10088,
368,
341,
286,
1077,
5206,
2415,
25,
12100,
18497,
3464,
11,
22301,
29,
284,
12100,
18497,
486,
931,
543,
286,
2415,
7030,
445,
5225,
3263,
983,
3904,
1507,
220,
16,
317,
286,
2415... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_poll_returns_false_after_all_source_events_are_consumed() {
const EVENT: InternalEvent = InternalEvent::Event(Event::Resize(10, 10));
let source = FakeSource::with_events(&[EVENT, EVENT, EVENT]);
let mut reader = InternalEventReader {
events: VecDeque::new()... | rust_cleaned_test_functions.jsonl/101477 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 299
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
40002,
58900,
36015,
19844,
5705,
10347,
19691,
56855,
69870,
291,
368,
341,
286,
733,
12742,
25,
15412,
1556,
284,
15412,
1556,
486,
1556,
30469,
486,
30561,
7,
16,
15,
11,
220,
16,
15,
3237,
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_mem_mut_writer() {
let mut vec = Vec::new();
let mut writer = Cursor::new(&mut vec);
assert_eq!(writer.write(&[0]).unwrap(), 1);
assert_eq!(writer.write(&[1, 2, 3]).unwrap(), 3);
assert_eq!(writer.write(&[4, 5, 6, 7]).unwrap(), 4);
let b: &[_] = &[... | rust_cleaned_test_functions.jsonl/4219 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 204
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
12976,
29523,
28908,
368,
341,
286,
1077,
5206,
7486,
284,
11312,
486,
931,
543,
286,
1077,
5206,
6916,
284,
28067,
486,
931,
2099,
6984,
7486,
317,
286,
2060,
10714,
10297,
18189,
3836,
2099,
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_derive_encode() {
use binstruct_codegen::BinEncode;
#[derive(Debug, BinEncode, PartialEq)]
#[binstruct(mod_path = "crate::serialize")]
struct T {
_1: CString,
_2: u32,
_3: CString,
_4: CString,
_5: u16,
_6: CString,
}
let mut bytes: Vec<u8> = vec![];
T {
... | rust_cleaned_test_functions.jsonl/101530 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 368
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
35345,
533,
11224,
368,
341,
220,
990,
9544,
1235,
32018,
486,
28794,
32535,
280,
220,
11506,
27098,
42618,
11,
29344,
32535,
11,
55039,
5563,
220,
11506,
6863,
1235,
23351,
2638,
284,
330,
61711,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_syn_sent_rst_bad_ack() {
let mut s = socket_syn_sent();
send!(s, TcpRepr {
control: TcpControl::Rst,
seq_number: REMOTE_SEQ,
ack_number: Some(TcpSeqNumber(1234)),
..SEND_TEMPL
}, Err(Error::Dropped));
assert_eq!(s.st... | rust_cleaned_test_functions.jsonl/1718 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 195
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
51393,
24115,
1710,
267,
34199,
48447,
368,
341,
286,
1077,
5206,
274,
284,
7575,
51393,
24115,
543,
286,
3624,
10297,
82,
11,
64876,
693,
649,
341,
310,
2524,
25,
64876,
3273,
486,
49,
267,
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... | 1 |
#[test]
fn test_writer_version() {
assert_eq!(WriterVersion::PARQUET_1_0.as_num(), 1);
assert_eq!(WriterVersion::PARQUET_2_0.as_num(), 2);
} | rust_cleaned_test_functions.jsonl/56721 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 84
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
28908,
9438,
368,
341,
286,
2060,
10714,
10297,
6492,
5637,
486,
16567,
5757,
1348,
62,
16,
62,
15,
5357,
4273,
1507,
220,
16,
317,
286,
2060,
10714,
10297,
6492,
5637,
486,
16567,
5757,
1348,
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 |
#[test]
fn test_storage_returns_bogus_error_when_loading_module() {
let mut gas_status = GasStatus::new_unmetered();
let module_id = ModuleId::new(TEST_ADDR, Identifier::new("N").unwrap());
let fun_name = Identifier::new("bar").unwrap();
for error_code in LIST_OF_ERROR_CODES {
let stora... | rust_cleaned_test_functions.jsonl/48437 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 316
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
23310,
58900,
880,
538,
355,
4096,
47636,
57726,
10750,
368,
341,
262,
1077,
5206,
6819,
4773,
284,
20854,
2522,
486,
931,
4907,
59422,
291,
543,
262,
1077,
4688,
842,
284,
13711,
764,
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... | 2 |
#[test]
fn test_sign_verify_detached() {
use randombytes::randombytes;
for i in 0..256usize {
let (pk, sk) = gen_keypair();
let m = randombytes(i);
let sig = sign_detached(&m, &sk);
assert!(verify_detached(&sig, &m, &pk));
}
} | rust_cleaned_test_functions.jsonl/11394 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 170
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
11172,
35638,
24409,
3854,
368,
341,
286,
990,
4194,
9651,
486,
11463,
9651,
280,
286,
369,
600,
304,
220,
15,
496,
17,
20,
21,
51878,
341,
310,
1077,
320,
20819,
11,
1901,
8,
284,
4081,
3097,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_merge_sort() {
let mut v = vec![15, 6, 8, 10, 1, 3, 2, 0, -10, 4, -5];
v = merge_sort(v);
assert_eq!(v, vec![-10, -5, 0, 1, 2, 3, 4, 6, 8, 10, 15]);
} | rust_cleaned_test_functions.jsonl/122401 | {
"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,
20888,
18435,
368,
341,
286,
1077,
5206,
348,
284,
7486,
20703,
16,
20,
11,
220,
21,
11,
220,
23,
11,
220,
16,
15,
11,
220,
16,
11,
220,
18,
11,
220,
17,
11,
220,
15,
11,
481,
16,
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_resolve_module() {
let (analysis, pos) = analysis_and_position(
"
//- /lib.rs
mod <|>foo;
//- /foo.rs
// empty
",
);
let symbols = analysis.approximately_resolve_symbol(pos).unwrap().unwrap();
assert_eq_dbg(
r#"ReferenceResolut... | rust_cleaned_test_functions.jsonl/75846 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 494
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
77291,
10750,
368,
341,
262,
1077,
320,
34484,
11,
1133,
8,
284,
6358,
8378,
9661,
1006,
286,
6228,
286,
78406,
608,
2740,
25638,
198,
286,
1463,
82639,
29,
7975,
280,
286,
78406,
608,
7975,
256... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_hash_to_string() {
let s = "Hello world".hash_to_string();
assert_eq!(s, "2216321107127430384");
} | rust_cleaned_test_functions.jsonl/6487 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 72
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
8950,
2346,
3904,
368,
341,
286,
1077,
274,
284,
330,
9707,
1879,
3263,
8296,
2346,
3904,
543,
286,
2060,
10714,
10297,
82,
11,
330,
17,
17,
16,
21,
18,
17,
16,
16,
15,
22,
16,
17,
22,
19,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_smoke() {
let pid = thread::process_id();
let tc = ThreadsCollector::new(pid, "smoke");
tc.collect();
tc.desc();
monitor_threads("smoke").unwrap();
} | rust_cleaned_test_functions.jsonl/99556 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 107
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
15874,
4740,
368,
341,
286,
1077,
14814,
284,
4516,
486,
4630,
842,
543,
286,
1077,
17130,
284,
74742,
53694,
486,
931,
37844,
11,
330,
3563,
4740,
797,
286,
17130,
29124,
543,
286,
17130,
30514,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_mvcc_rollback_and_cleanup() {
let (_cluster, client, ctx) = must_new_cluster_and_kv_client();
let (k, v) = (b"key".to_vec(), b"value".to_vec());
let mut ts = 0;
// Prewrite
ts += 1;
let prewrite_start_version = ts;
let mut mutation = Mutation::default();
mutatio... | rust_cleaned_test_functions.jsonl/61685 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1545
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
73187,
638,
62,
33559,
8378,
42444,
368,
341,
262,
1077,
5453,
18855,
11,
2943,
11,
5635,
8,
284,
1969,
5921,
28441,
8378,
97066,
8179,
543,
262,
1077,
320,
74,
11,
348,
8,
284,
320,
65,
1,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_local_date_sanity_check() {
// issue #27
assert_eq!(Local.ymd(2999, 12, 28).day(), 28);
} | rust_cleaned_test_functions.jsonl/73877 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 70
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
13564,
4164,
643,
38270,
7200,
368,
341,
286,
442,
4265,
671,
17,
22,
198,
286,
2060,
10714,
10297,
7319,
13,
1600,
67,
7,
17,
24,
24,
24,
11,
220,
16,
17,
11,
220,
17,
23,
568,
1292,
1507... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_eval_nop() {
let cie = make_test_cie();
let ctx = UnwindContext::new();
let expected = ctx.clone();
let instructions = [(Ok(false), CallFrameInstruction::Nop)];
assert_eval(ctx, expected, cie, None, instructions);
} | rust_cleaned_test_functions.jsonl/9366 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 126
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21296,
1089,
453,
368,
341,
286,
1077,
272,
645,
284,
1281,
4452,
666,
645,
543,
286,
1077,
5635,
284,
1230,
19154,
1972,
486,
931,
543,
286,
1077,
3601,
284,
5635,
15997,
543,
286,
1077,
11221,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_24() {
assert_eq!(
Solution::swap_pairs(to_list(vec![1, 2, 3, 4])),
to_list(vec![2, 1, 4, 3])
);
assert_eq!(Solution::swap_pairs(to_list(vec![])), to_list(vec![]));
assert_eq!(
Solution::swap_pairs(to_list(vec![1, 2, 3])),
... | rust_cleaned_test_functions.jsonl/102724 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 268
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
62,
17,
19,
368,
341,
286,
2060,
10714,
33673,
310,
12478,
486,
25741,
36430,
12186,
2019,
25592,
20703,
16,
11,
220,
17,
11,
220,
18,
11,
220,
19,
87619,
310,
311,
2019,
25592,
20703,
17,
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_qf_to_pari_qf_to_qf() {
unsafe {
pari_init(10000000, 2);
}
let a: BigInt = str::parse("13473106641794685581473717279829601028053715749272527243991193432471829325384523045496097043503600584058279489765587220875593418592523380312580622889109846548142551998748164... | rust_cleaned_test_functions.jsonl/21403 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 408
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
8976,
69,
2346,
620,
2780,
8976,
69,
2346,
8976,
69,
368,
341,
286,
19860,
341,
310,
66982,
6137,
7,
16,
15,
15,
15,
15,
15,
15,
15,
11,
220,
17,
317,
286,
456,
286,
1077,
264,
25,
62608,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_contradiction() {
let mut puzzle = Puzzle::new();
let v0 = puzzle.new_var_with_candidates(&[3]);
let v1 = puzzle.new_var_with_candidates(&[0,1]);
puzzle.equals(v0 + 2 * v1, 4);
let search = puzzle.step();
assert!(search.is_none());
} | rust_cleaned_test_functions.jsonl/73197 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 149
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
3382,
47026,
2479,
368,
341,
286,
1077,
5206,
24626,
284,
60012,
486,
931,
543,
286,
1077,
348,
15,
284,
24626,
4618,
4612,
6615,
73553,
2099,
58,
18,
2558,
286,
1077,
348,
16,
284,
24626,
4618,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_bit_reader_get_value() {
let buffer = vec![255, 0];
let mut bit_reader = BitReader::from(buffer);
assert_eq!(bit_reader.get_value::<i32>(1), Some(1));
assert_eq!(bit_reader.get_value::<i32>(2), Some(3));
assert_eq!(bit_reader.get_value::<i32>(3), Some(7));... | rust_cleaned_test_functions.jsonl/115728 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 191
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
13996,
22306,
3062,
3142,
368,
341,
286,
1077,
4147,
284,
7486,
20703,
17,
20,
20,
11,
220,
15,
935,
286,
1077,
5206,
2699,
22306,
284,
6495,
5062,
486,
1499,
12584,
317,
286,
2060,
10714,
10297... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_diff_highlight_respects_gitconfig() {
let git_config_contents = b"
[color \"diff\"]
old = red bold
new = green bold
[color \"diff-highlight\"]
oldNormal = ul red bold
oldHighlight = red bold 52
newNormal = ul green bold
newHighlight = green bold 22
";
let... | rust_cleaned_test_functions.jsonl/18159 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 449
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
15850,
74546,
4918,
7973,
68801,
1676,
368,
341,
286,
1077,
16345,
5332,
16682,
284,
293,
698,
84111,
7245,
13490,
2105,
921,
262,
2310,
284,
2518,
13939,
198,
262,
501,
284,
6176,
13939,
271,
841... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_pow_overflow() {
let tests = vec![(ScalarFuncSig::Pow, Datum::F64(2.0), Datum::F64(300000000.0))];
let mut ctx = EvalContext::default();
for (sig, arg0, arg1) in tests {
let arg0 = datum_expr(arg0);
let arg1 = datum_expr(arg1);
let mut ... | rust_cleaned_test_functions.jsonl/125533 | {
"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,
56183,
79073,
368,
341,
286,
1077,
7032,
284,
7486,
0,
9697,
20639,
9626,
47246,
486,
66584,
11,
68459,
486,
37,
21,
19,
7,
17,
13,
15,
701,
68459,
486,
37,
21,
19,
7,
18,
15,
15,
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... | 2 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.