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_create_poly_from_macro() {
let poly = univar_polynomial!(
FieldElement::one(),
FieldElement::zero(),
FieldElement::from(87u64),
-FieldElement::one(),
FieldElement::from(300u64)
);
assert_eq!(poly.degree(), 4);
... | rust_cleaned_test_functions.jsonl/51310 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 291
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
8657,
36133,
5673,
58810,
368,
341,
286,
1077,
9861,
284,
650,
56398,
47323,
25358,
33673,
310,
8601,
1691,
486,
603,
3148,
310,
8601,
1691,
486,
14154,
3148,
310,
8601,
1691,
486,
1499,
7,
23,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_stop_client_connections_succeeds() {
let mut test_values = test_setup();
// Request a scan
let stop_fut = test_values.iface_manager.stop_client_connections(
client_types::DisconnectReason::FidlStopClientConnectionsRequest,
);
pin_mut!(stop_fut... | rust_cleaned_test_functions.jsonl/59190 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 513
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
19039,
8179,
56402,
643,
29264,
82,
368,
341,
286,
1077,
5206,
1273,
9146,
284,
1273,
21363,
1428,
286,
442,
6145,
264,
8569,
198,
286,
1077,
2936,
761,
332,
284,
1273,
9146,
35431,
578,
12144,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_unexpected_support_from_node() {
ic_test_utilities::artifact_pool_config::with_test_pool_config(|pool_config| {
with_test_replica_logger(|logger| {
let (mut ecdsa_pool, pre_signer) =
create_pre_signer_dependencies(pool_config, logger)... | rust_cleaned_test_functions.jsonl/86723 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 764
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
36844,
96780,
4907,
7325,
25827,
5673,
5084,
368,
341,
286,
17902,
4452,
94044,
486,
63722,
15709,
5332,
486,
4197,
4452,
15709,
5332,
22428,
10285,
5332,
91,
341,
310,
448,
4452,
25533,
15317,
2741... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_unescape_byte_str_good() {
fn check(literal_text: &str, expected: &[u8]) {
let mut buf = Ok(Vec::with_capacity(literal_text.len()));
unescape_byte_str(literal_text, &mut |range, c| {
if let Ok(b) = &mut buf {
match c {
... | rust_cleaned_test_functions.jsonl/61424 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 486
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
4907,
12998,
19737,
2895,
44781,
368,
341,
286,
5168,
1779,
2333,
9953,
4326,
25,
609,
495,
11,
3601,
25,
44590,
84,
23,
2467,
341,
310,
1077,
5206,
6607,
284,
7622,
49923,
486,
4197,
35603,
233... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_head_mut() {
let mut a = vec![];
assert_eq!(a.as_mut_slice().head_mut(), None);
a = vec![11i];
assert_eq!(*a.as_mut_slice().head_mut().unwrap(), 11);
a = vec![11i, 12];
assert_eq!(*a.as_mut_slice().head_mut().unwrap(), 11);
} | rust_cleaned_test_functions.jsonl/108280 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 161
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
13138,
29523,
368,
341,
286,
1077,
5206,
264,
284,
7486,
0,
15078,
286,
2060,
10714,
10297,
64,
5357,
29523,
26488,
1005,
1983,
29523,
1507,
2240,
317,
286,
264,
284,
7486,
20703,
16,
16,
72,
93... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_proposals_removes_execute_nns_function_payload() {
// ARRANGE
let proposal_id = ProposalId { id: 2 };
let payload = iter::repeat(42)
.take(EXECUTE_NNS_FUNCTION_PAYLOAD_LISTING_BYTES_MAX + 1)
.collect();
let driver = fake::FakeDriver::default();
let gov = ... | rust_cleaned_test_functions.jsonl/1173 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 451
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
2019,
21663,
85975,
19194,
10088,
44329,
1089,
4412,
9174,
32813,
368,
341,
262,
442,
82079,
11503,
198,
262,
1077,
13734,
842,
284,
65890,
764,
314,
877,
25,
220,
17,
2605,
262,
1077,
7729,
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_not_found() {
let c = make();
let res = c.get::<bool>("not_found");
assert!(res.is_err());
assert_eq!(
res.unwrap_err().to_string(),
"configuration property \"not_found\" not found".to_string()
);
} | rust_cleaned_test_functions.jsonl/39921 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 119
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
7913,
21480,
368,
341,
262,
1077,
272,
284,
1281,
543,
262,
1077,
592,
284,
272,
670,
27638,
2641,
13211,
1921,
21480,
3071,
262,
2060,
10297,
416,
2079,
9266,
1423,
262,
2060,
10714,
33673,
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_is_valid_incorrect_required_hash() {
let (tx_out_store, env) = init_tx_out_store();
let num_tx_outs: u32 = 8;
let tx_outs = get_tx_outs(num_tx_outs);
{
// Populate the tx_out_store.
let mut rw_transaction = env.begin_rw_txn().unwrap();
... | rust_cleaned_test_functions.jsonl/5264 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 683
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6892,
8337,
1243,
19928,
18743,
8950,
368,
341,
286,
1077,
320,
3998,
6068,
14809,
11,
6105,
8,
284,
2930,
17805,
6068,
14809,
543,
286,
1077,
1629,
17805,
6068,
82,
25,
575,
18,
17,
284,
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... | 2 |
#[test]
fn test_deserialize_numeric() {
#[derive(Debug, PartialEq)]
enum FloatOrInteger {
Float(f64),
Integer(u64),
}
impl<'de> de::Deserialize<'de> for FloatOrInteger {
fn deserialize<D>(de: D) -> Result<FloatOrInteger, D::Error>
where D: de::Deserializer<'d... | rust_cleaned_test_functions.jsonl/13678 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 721
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
15768,
9050,
29418,
368,
341,
262,
11506,
27098,
42618,
11,
55039,
5563,
262,
7618,
13001,
2195,
3486,
341,
286,
13001,
955,
21,
19,
1326,
286,
4440,
8154,
21,
19,
1326,
262,
555,
262,
11605,
18... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_stdin_all_repeated() {
new_ucmd!()
.args(&["--all-repeated"]).pipe_in_fixture(INPUT)
.run().stdout_is_fixture("sorted-all-repeated.expected");
} | rust_cleaned_test_functions.jsonl/23101 | {
"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,
15656,
258,
5705,
1288,
41954,
368,
341,
262,
501,
68887,
2277,
0,
741,
286,
659,
2116,
2099,
1183,
313,
541,
5504,
41954,
45014,
13768,
1243,
74409,
57911,
340,
286,
659,
6108,
1005,
36358,
6892,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_timeout_tokio_timeout() {
let runtime = tokio::runtime::Builder::new_multi_thread()
.enable_all()
.build()
.unwrap();
runtime.block_on(timeout_test_tokio(true));
} | rust_cleaned_test_functions.jsonl/3115 | {
"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,
20537,
76162,
815,
20537,
368,
341,
73363,
286,
1077,
15592,
284,
9628,
815,
486,
22255,
486,
3297,
486,
931,
25133,
10814,
741,
310,
659,
12552,
5705,
741,
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 |
#[test]
fn test_local_cluster_start_and_exit_with_config() {
solana_logger::setup();
const NUM_NODES: usize = 1;
let mut config = ClusterConfig {
validator_configs: make_identical_validator_configs(
&ValidatorConfig::default(),
NUM_NODES,
... | rust_cleaned_test_functions.jsonl/24681 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 384
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
13564,
28441,
4906,
8378,
16880,
6615,
5332,
368,
341,
286,
2048,
3362,
27413,
486,
15188,
543,
286,
733,
15943,
92948,
25,
22301,
284,
220,
16,
280,
286,
1077,
5206,
2193,
284,
35380,
2648,
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_parse_empty_string() {
let text = "";
let parsed_input = parse_message(text);
assert_eq!(parsed_input.description, None);
assert_eq!(parsed_input.object_info, None);
assert_eq!(parsed_input.object_type, ObjectType::Other);
} | rust_cleaned_test_functions.jsonl/97562 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 134
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21039,
15124,
3904,
368,
341,
286,
1077,
1467,
284,
5438,
286,
1077,
15676,
5898,
284,
4715,
6462,
7235,
626,
286,
2060,
10714,
10297,
41030,
5898,
13178,
11,
2240,
317,
286,
2060,
10714,
10297,
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 |
#[test]
fn test_nirmala() {
run_test(
&TEST_DATA,
"directwrite/good-nirmala.ta",
"indic/Nirmala.ttf",
&[JOINER_GLYPH_INDEX],
353,
);
} | rust_cleaned_test_functions.jsonl/91211 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 213
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
1089,
2853,
6053,
368,
341,
394,
1598,
4452,
1006,
503,
609,
10033,
7896,
345,
503,
330,
19798,
4934,
4846,
1386,
5279,
2853,
6053,
72160,
756,
503,
330,
85084,
20290,
2853,
6053,
45192,
756,
503,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_frozen_duplicate_confirmed() {
// Common state
let slot = 0;
let is_slot_duplicate = false;
let is_dead = false;
// No cluster duplicate_confirmed hash yet
let mut cluster_duplicate_confirmed_hash = None;
// no actionabl... | rust_cleaned_test_functions.jsonl/48608 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 933
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
761,
42240,
70434,
16059,
8434,
368,
341,
286,
442,
7718,
1584,
198,
286,
1077,
9446,
284,
220,
15,
280,
286,
1077,
374,
27563,
70434,
284,
895,
280,
286,
1077,
374,
53427,
284,
895,
401,
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_get_default_branch_with_memo() -> Result<()> {
let gh_token = env::github_token(&None::<String>)?;
let mut memo = HashMap::new();
get_default_branch(&gh_token, "suecharo", "gh-trs", Some(&mut memo))?;
get_default_branch(&gh_token, "suecharo", "gh-trs", Some(&mut m... | rust_cleaned_test_functions.jsonl/6702 | {
"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,
3062,
9993,
28031,
6615,
717,
6726,
368,
1464,
5714,
71698,
341,
286,
1077,
36124,
6458,
284,
6105,
486,
5204,
6458,
2099,
4064,
27638,
703,
9231,
37445,
286,
1077,
5206,
21438,
284,
10528,
486,
9... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_sample_below_prng() {
use rand::{thread_rng};
let q: u64 = 18014398492704769;
let q_scalar = Scalar::new_modulus(q);
let mut rng = thread_rng();
for _ in 0..10 {
assert!(Scalar::sample_below_from_rng(&q_scalar, &mut rng).rep < q);
}
... | rust_cleaned_test_functions.jsonl/1926 | {
"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,
17491,
82750,
5294,
968,
368,
341,
286,
990,
10382,
22964,
4528,
66849,
2440,
286,
1077,
2804,
25,
575,
21,
19,
284,
220,
16,
23,
15,
16,
19,
18,
24,
23,
19,
24,
17,
22,
15,
19,
22,
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... | 2 |
#[test]
fn test_scan_values_in_default() {
let path = TempDir::new("_test_scan_values_in_default").expect("");
let path = path.path().to_str().unwrap();
let engine = engine::new_local_engine(path, ALL_CFS).unwrap();
must_prewrite_put(
engine.as_ref(),
&[2... | rust_cleaned_test_functions.jsonl/23339 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 980
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
28857,
9146,
1243,
9993,
368,
341,
286,
1077,
1815,
284,
19944,
6184,
486,
931,
16975,
1944,
28857,
9146,
1243,
9993,
1827,
17119,
13056,
286,
1077,
1815,
284,
1815,
3875,
1005,
983,
2895,
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... | 1 |
#[test]
fn test_do_hmac() {
let key = String::from("mysecret");
let message = String::from("hellothere");
let mac = do_hmac(key, message);
assert_eq!(
format!(
"{}{}",
"b8558314f515931c8d9b329805978fe77b9bb020b05406c0e",
... | rust_cleaned_test_functions.jsonl/73503 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 270
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
26309,
1523,
11948,
368,
341,
286,
1077,
1376,
284,
923,
486,
1499,
445,
2408,
20474,
797,
286,
1077,
1943,
284,
923,
486,
1499,
445,
14990,
18532,
797,
286,
1077,
8978,
284,
653,
1523,
11948,
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_check_transfer_success_with_source_only() {
// create a genesis account.
let account = GenesisAccount::account(
DEFAULT_ACCOUNT_PUBLIC_KEY.clone(),
Motes::new(U512::from(DEFAULT_ACCOUNT_INITIAL_BALANCE)),
None,
);
// add the account to the genesis config.... | rust_cleaned_test_functions.jsonl/123010 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 902
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
7200,
35403,
18632,
6615,
10347,
18410,
368,
341,
262,
442,
1855,
264,
59366,
2692,
624,
262,
1077,
2692,
284,
40788,
7365,
486,
4608,
1006,
286,
11955,
38831,
36209,
6600,
15997,
3148,
286,
386,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_valid_relative_path() {
expect_ok!(RelativePath, "foo");
expect_ok!(RelativePath, "foo/bar");
expect_ok!(RelativePath, &format!("{}", repeat("x").take(1024).collect::<String>()));
} | rust_cleaned_test_functions.jsonl/98667 | {
"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,
8337,
29286,
2638,
368,
341,
286,
1720,
19817,
10297,
28442,
1820,
11,
330,
7975,
797,
286,
1720,
19817,
10297,
28442,
1820,
11,
330,
7975,
49513,
797,
286,
1720,
19817,
10297,
28442,
1820,
11,
60... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_prepare_schema_success() {
let _setup = SetupMocks::init();
let cb = return_types_u32::Return_U32_U32_STR::new().unwrap();
assert_eq!(vcx_schema_prepare_for_endorser(cb.command_handle,
CString::new("Test Source ID").... | rust_cleaned_test_functions.jsonl/118209 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 714
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
2273,
25844,
47460,
25371,
18632,
368,
341,
286,
1077,
716,
15188,
284,
18626,
72577,
486,
2327,
1428,
286,
1077,
9858,
284,
470,
9763,
7300,
18,
17,
486,
5598,
6665,
18,
17,
6665,
18,
17,
7159,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_process_store_without_config_signer() {
solana_logger::setup();
let pubkey = Pubkey::new_unique();
let signer0_pubkey = Pubkey::new_unique();
let keys = vec![(pubkey, false), (signer0_pubkey, true)];
let (config_keypair, _) = create_config_account(keys.clo... | rust_cleaned_test_functions.jsonl/74376 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 447
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
11305,
14809,
39904,
5332,
11172,
261,
368,
341,
286,
2048,
3362,
27413,
486,
15188,
543,
286,
1077,
95116,
284,
22611,
792,
486,
931,
21218,
543,
286,
1077,
70039,
15,
34014,
792,
284,
22611,
792... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_mock_command_wait() {
let client = Client::new_num(1);
let mut creator = MockCommandCreator::new(&client);
creator.next_command_spawns(Ok(MockChild::new(exit_status(0), "hello", "error")));
assert_eq!(
0,
spawn_wait_command(&mut creator, "f... | rust_cleaned_test_functions.jsonl/89703 | {
"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,
34134,
10811,
18760,
368,
341,
286,
1077,
2943,
284,
8423,
486,
931,
4273,
7,
16,
317,
286,
1077,
5206,
19919,
284,
14563,
4062,
31865,
486,
931,
2099,
2972,
317,
286,
19919,
4529,
10811,
10123,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_fd_sync() {
assert_wasi_output!(
"../../wasitests/fd_sync.wasm",
"fd_sync",
vec![],
vec![(
".".to_string(),
::std::path::PathBuf::from("wasitests/test_fs/temp")
),],
vec![],
"../../wasitests/fd_sync.out"
);
} | rust_cleaned_test_functions.jsonl/106799 | {
"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,
17676,
23008,
368,
341,
262,
2060,
1670,
10215,
7645,
33673,
286,
10208,
16123,
275,
17966,
6663,
67,
23008,
1418,
10530,
756,
286,
330,
6902,
23008,
756,
286,
7486,
20703,
1259,
286,
7486,
20703,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_vec4_accessors() {
let mut a = Vec4::zero();
a.x = 1.0;
a.y = 2.0;
a.z = 3.0;
a.w = 4.0;
assert_eq!(1.0, a.x);
assert_eq!(2.0, a.y);
assert_eq!(3.0, a.z);
assert_eq!(4.0, a.w);
assert_eq!((1.0, 2.0, 3.0, 4.0), a.into());
let mut a = Vec4::zero();
... | rust_cleaned_test_functions.jsonl/68860 | {
"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,
13251,
19,
12759,
1087,
368,
341,
262,
1077,
5206,
264,
284,
11312,
19,
486,
14154,
543,
262,
264,
1993,
284,
220,
16,
13,
15,
280,
262,
264,
2384,
284,
220,
17,
13,
15,
280,
262,
264,
3938,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_ignore_garbage() {
for ignore_garbage_param in vec!["-i", "--ignore-garbage"] {
let input = "JBSWY\x013DPFQ\x02QFO33SNRSCC===\n";
new_ucmd!()
.arg("-d")
.arg(ignore_garbage_param)
.pipe_in(input)
.succeeds()
.stdout_... | rust_cleaned_test_functions.jsonl/39846 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 202
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
58493,
1889,
277,
20652,
368,
341,
262,
369,
10034,
1889,
277,
20652,
4090,
304,
7486,
0,
1183,
12,
72,
497,
14482,
13130,
2371,
277,
20652,
1341,
341,
286,
1077,
1946,
284,
330,
41,
7347,
54,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_blake2b() {
use crate::encoding::hex;
// Appendix A. Example of BLAKE2b Computation
assert_eq!(
&blake2b_512(b"abc"),
&[
0xBA, 0x80, 0xA5, 0x3F, 0x98, 0x1C, 0x4D, 0x0D, 0x6A, 0x27, 0x97, 0xB6, 0x9F, 0x12,
0xF6, 0xE9, 0x4C, 0x21, 0x2F, 0x... | rust_cleaned_test_functions.jsonl/38421 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1405
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
13141,
726,
17,
65,
368,
341,
262,
990,
17717,
486,
17159,
486,
17308,
401,
262,
442,
64714,
362,
13,
220,
13383,
315,
14850,
25474,
17,
65,
1198,
13320,
7213,
262,
2060,
10714,
33673,
286,
609,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_small_binary() -> Result<()> {
let frames = Frame::from_payload(SIMPLE_BIN);
assert_eq!(frames[0].header.frame_num, 0);
assert_eq!(frames[0].header.flash_offset, 0x80000);
assert_eq!(
hex::encode(frames[0].header.hash),
"4e31bfd8b3be32358f... | rust_cleaned_test_functions.jsonl/85132 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 370
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
31966,
31761,
368,
1464,
5714,
71698,
341,
286,
1077,
14087,
284,
16321,
486,
1499,
32813,
3759,
1791,
9515,
55720,
626,
286,
2060,
10714,
10297,
23719,
58,
15,
936,
2708,
9140,
4273,
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_send_append_for_progress_probe() {
let l = default_logger();
let mut r = new_test_raft(1, vec![1, 2], 10, 1, new_storage(), &l);
r.become_candidate();
r.become_leader();
r.read_messages();
r.mut_prs().get_mut(2).unwrap().become_probe();
// each round is a heartbeat
... | rust_cleaned_test_functions.jsonl/19135 | {
"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,
13565,
26041,
5478,
27200,
49108,
368,
341,
262,
1077,
326,
284,
1638,
27413,
543,
262,
1077,
5206,
435,
284,
501,
4452,
62,
2944,
7,
16,
11,
7486,
20703,
16,
11,
220,
17,
1125,
220,
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... | 5 |
#[test]
fn test_get_input_file_api_version() {
assert_eq!(
Some("2019-05-05-preview".to_owned()),
get_input_file_api_version("Microsoft.AlertsManagement/preview/2019-05-05-preview/ActionRules.json")
);
} | rust_cleaned_test_functions.jsonl/58214 | {
"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,
3062,
5898,
2458,
11697,
9438,
368,
341,
286,
2060,
10714,
33673,
310,
4329,
445,
17,
15,
16,
24,
12,
15,
20,
12,
15,
20,
50881,
3263,
983,
51973,
14702,
310,
633,
5898,
2458,
11697,
9438,
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... | 1 |
#[test]
fn test_find_installed_version_path() {
// add it here.
let _lock = LOCK.lock();
let ver = "0.8.6";
let version = Version::from_str(ver).unwrap();
if utils::installed_versions(svm::SVM_HOME.as_path())
.map(|versions| !versions.contains(&versio... | rust_cleaned_test_functions.jsonl/50530 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 315
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21814,
79065,
9438,
2638,
368,
341,
1789,
286,
442,
912,
432,
1588,
624,
286,
1077,
716,
1023,
284,
49463,
21003,
543,
286,
1077,
2739,
284,
330,
15,
13,
23,
13,
21,
876,
286,
1077,
2319,
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_day5_part2() {
let program = Program::from_file("../day05/input.txt").expect("Failed to read input");
assert_run(&program, VecDeque::from(vec![5]), &[15486302]);
} | rust_cleaned_test_functions.jsonl/119111 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 91
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
16763,
20,
10495,
17,
368,
341,
286,
1077,
2025,
284,
6687,
486,
1499,
2458,
17409,
1292,
15,
20,
39990,
3909,
1827,
17119,
445,
9408,
311,
1349,
1946,
797,
286,
2060,
14007,
2099,
14906,
11,
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 |
#[test]
fn test_ja_simple() {
let orig = "The quick (\"brown\") fox can't jump 32.3 feet, right? Brr, it's 29.3°F!";
let processed = ProcessedText {
original: orig,
processed: Cow::Borrowed(orig),
};
let en_tokens = Lindera { normal_mode: true, d... | rust_cleaned_test_functions.jsonl/24091 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 620
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
5374,
64,
30015,
368,
341,
286,
1077,
2713,
284,
330,
785,
3974,
320,
2105,
64461,
62705,
38835,
646,
944,
7784,
220,
18,
17,
13,
18,
7541,
11,
1290,
30,
425,
634,
11,
432,
594,
220,
17,
24,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_timed_send() {
use crate::packet::pull_resp::TxPk;
let json = "{\"codr\":\"4/5\",\"data\":\"IHLF2EA+n8BFY1vrCU1k/Vg=\",\"datr\":\"SF10BW500\",\"freq\":926.9000244140625,\"imme\":false,\"ipol\":true,\"modu\":\"LORA\",\"powe\":27,\"rfch\":0,\"size\":17,\"tmst\":727050748}";
let txpk: ... | rust_cleaned_test_functions.jsonl/62773 | {
"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,
29087,
291,
13565,
368,
341,
262,
990,
17717,
486,
24829,
486,
23441,
35160,
486,
31584,
58415,
280,
262,
1077,
2951,
284,
54734,
20116,
81,
23488,
19,
14,
20,
34333,
691,
23488,
40,
13485,
37,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_propagate_new_leaf() {
let mut heaviest_subtree_fork_choice = setup_forks();
heaviest_subtree_fork_choice
.add_new_leaf_slot((10, Hash::default()), Some((4, Hash::default())));
let ancestors = heaviest_subtree_fork_choice
.ancestor_iterat... | rust_cleaned_test_functions.jsonl/85867 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 2006
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
21663,
46836,
5921,
38909,
368,
341,
286,
1077,
5206,
566,
98362,
5228,
9344,
761,
669,
31936,
284,
6505,
761,
73302,
1428,
1789,
286,
566,
98362,
5228,
9344,
761,
669,
31936,
198,
310,
659,
718,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_quoted_unicode_chars() {
let mut args = Arguments::new(r#""𝓒𝓢𝓐 | CSA" amazing try"#);
assert_eq!(Some("𝓒𝓢𝓐 | CSA"), args.next());
assert_eq!(Some("amazing"), args.next());
assert_eq!(Some("try"), args.next());
assert_eq!(None, args.next());
} | rust_cleaned_test_functions.jsonl/53185 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 161
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
11280,
9253,
54662,
37418,
368,
341,
286,
1077,
5206,
2827,
284,
27702,
486,
931,
2601,
2,
3014,
151316,
151318,
123871,
238,
760,
93407,
1,
7897,
1430,
57676,
317,
286,
2060,
10714,
10297,
8373,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_pending_snapshot() {
let mut cluster = new_node_cluster(0, 3);
configure_for_snapshot(&mut cluster);
let election_timeout = configure_for_lease_read(&mut cluster, None, Some(15));
let gc_limit = cluster.cfg.raft_store.raft_log_gc_count_limit();
cluster.cfg.raft_store.pd_heart... | rust_cleaned_test_functions.jsonl/30710 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1057
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
37861,
53265,
368,
341,
262,
1077,
5206,
10652,
284,
501,
5084,
28441,
7,
15,
11,
220,
18,
317,
262,
14411,
5478,
53265,
2099,
6984,
10652,
317,
262,
1077,
6223,
20537,
284,
14411,
5478,
62,
162... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_ord() {
let cases = vec![
("2", 50),
("23", 50),
("2.3", 50),
("", 0),
("你好", 14990752),
("にほん", 14909867),
("한국", 15570332),
("👍", 4036989325),
("א", 55184),
];
... | rust_cleaned_test_functions.jsonl/44153 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 414
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
67324,
368,
341,
286,
1077,
5048,
284,
7486,
90515,
310,
3489,
17,
497,
220,
20,
15,
1326,
310,
3489,
17,
18,
497,
220,
20,
15,
1326,
310,
3489,
17,
13,
18,
497,
220,
20,
15,
1326,
310,
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... | 2 |
#[test]
fn test_compile_shift_right_c() {
let compiled = bitwise::compile_shift_right("C".to_string());
assert_eq!(compiled.len(), 1);
assert_eq!(compiled[0], 0b01011110);
} | rust_cleaned_test_functions.jsonl/100615 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 86
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
74170,
22230,
10539,
666,
368,
341,
262,
1077,
19697,
284,
97970,
486,
20433,
22230,
10539,
445,
34,
3263,
983,
3904,
5231,
262,
2060,
10714,
10297,
50845,
19406,
1507,
220,
16,
317,
262,
2060,
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 |
#[test]
fn test_terminate() {
let location = TempLocation::new();
request_stream_test(
location.to_persistent_lifetime(),
Arc::new(Inspector::new()),
|proxy, ahc_client_end| {
async move {
proxy.create_account(ahc_client_end... | rust_cleaned_test_functions.jsonl/36825 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 668
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
62,
48061,
368,
341,
286,
1077,
3728,
284,
19944,
4707,
486,
931,
543,
286,
1681,
12673,
4452,
1006,
310,
3728,
2389,
620,
13931,
98827,
3148,
310,
19689,
486,
931,
7,
46230,
486,
931,
14702,
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... | 6 |
#[test]
fn test_ssh_files() -> Result<()> {
let mut mock = MockFuchsiaPaths::new();
let data = format!(
"/usr/local/home/foo/.ssh/fuchsia_ed25519
/usr/local/home/foo/.ssh/fuchsia_authorized_keys
",
);
let tmp_dir = Builder::new().prefix("fvdl_tests_").tempdir()?;
... | rust_cleaned_test_functions.jsonl/77517 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 533
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
82805,
10931,
368,
1464,
5714,
71698,
341,
286,
1077,
5206,
7860,
284,
14563,
37,
73391,
26901,
486,
931,
543,
286,
1077,
821,
284,
3561,
33673,
310,
3521,
7063,
22270,
18215,
60555,
11930,
25537,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_traditional() {
// note gnu od does not align both lines
let input = "abcdefghijklmnopq"; // spell-checker:disable-line
new_ucmd!()
.arg("--traditional")
.arg("-a")
.arg("-c")
.arg("-")
.arg("10")
.arg("0")
.run_piped_stdin(inpu... | rust_cleaned_test_functions.jsonl/48828 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 373
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
3547,
329,
3005,
368,
341,
262,
442,
5185,
342,
8933,
10785,
1558,
537,
5285,
2176,
5128,
198,
262,
1077,
1946,
284,
330,
65102,
80,
5123,
442,
12845,
15934,
261,
42066,
8447,
198,
262,
501,
688... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_to_uppercase() {
let mut output = String::new();
let method = StringMethod {
method: "to_uppercase",
variable: "\"Ford Prefect\"",
pattern: "",
selection: Select::All,
};
method.handle(&mut output, &VariableExp... | rust_cleaned_test_functions.jsonl/85278 | {
"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,
2346,
34445,
5638,
368,
341,
286,
1077,
5206,
2550,
284,
923,
486,
931,
543,
286,
1077,
1714,
284,
923,
3523,
341,
310,
1714,
25,
262,
330,
983,
34445,
5638,
756,
310,
3890,
25,
220,
15898,
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_server_survives_30_rpc_errors() -> Result<()> {
let server = make_arc_test_server();
for _ in 0..30 {
let server_clone = server.clone();
let _ =
dispatch(server_clone, Aborting.name(), RequestMessage::new());
}
let reply =... | rust_cleaned_test_functions.jsonl/112199 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 272
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
12015,
49946,
85,
1886,
62,
18,
15,
60799,
20196,
368,
1464,
5714,
71698,
341,
286,
1077,
3538,
284,
1281,
62914,
4452,
12015,
1428,
286,
369,
716,
304,
220,
15,
496,
18,
15,
341,
310,
1077,
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... | 3 |
#[test]
fn test_authorize_url_redirect_url_override() {
let client = new_client()
.set_redirect_uri(RedirectUrl::new("http://localhost:8888/".to_string()).unwrap());
let flow = CoreAuthenticationFlow::AuthorizationCode;
fn new_csrf() -> CsrfToken {
CsrfToken::ne... | rust_cleaned_test_functions.jsonl/73892 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 887
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
22938,
551,
2903,
30043,
2903,
48576,
368,
341,
286,
1077,
2943,
284,
501,
8179,
741,
310,
659,
746,
30043,
15572,
2785,
291,
1226,
2864,
486,
931,
445,
1254,
1110,
8301,
25,
23,
23,
23,
23,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_type_based_or_pruning() {
let schema = prepopulated_schema();
let known = Known::for_schema(&schema);
// This simplifies to:
// [:find ?x
// :where [?a :some/int ?x]
// [_ :some/otherint ?x]]
let query = r#"
[:find ?x
... | rust_cleaned_test_functions.jsonl/44233 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 382
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
1819,
66679,
8734,
5294,
37202,
368,
341,
286,
1077,
10802,
284,
855,
8374,
7757,
25371,
543,
286,
1077,
3881,
284,
48286,
486,
1958,
25371,
2099,
17349,
317,
286,
442,
1096,
15491,
9606,
311,
510... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_chacha_true_values_c() {
// Test vector 4 from
let seed = [0, 0xff, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0];
let expected = [0xfb4dd572, 0x4bc42ef1, 0xdf... | rust_cleaned_test_functions.jsonl/113001 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1026
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
4138,
51576,
16082,
9146,
666,
368,
341,
286,
442,
3393,
4621,
220,
19,
504,
8945,
286,
1077,
10320,
284,
508,
15,
11,
220,
15,
9020,
11,
220,
15,
11,
220,
15,
11,
220,
15,
11,
220,
15,
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... | 4 |
#[test]
fn test_call_simple_does_not_enqueue_request_if_err() {
with_hypervisor(|hypervisor, tmp_path| {
let (canister, _, action, _) = execute_update(
&hypervisor,
r#"(module
(import "ic0" "call_simple"
(func $ic0_call_simple
... | rust_cleaned_test_functions.jsonl/57855 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1313
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
13429,
30015,
96374,
7913,
28395,
7893,
11119,
9266,
368,
341,
262,
448,
1523,
1082,
31396,
22428,
78243,
31396,
11,
4174,
2638,
91,
341,
286,
1077,
320,
4814,
1571,
11,
8358,
1917,
11,
27439,
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_command() {
let ts = Target::Selected;
let ta = Target::All;
// Should succeed
assert_eq!(commands("q"), Ok(("", vec![Command::Quit])));
assert_eq!(commands("quit"), Ok(("", vec![Command::Quit])));
assert_eq!(commands("c"), Ok(("", vec![Command::C... | rust_cleaned_test_functions.jsonl/320 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1390
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
10811,
368,
341,
286,
1077,
10591,
284,
13483,
486,
6316,
280,
286,
1077,
9450,
284,
13483,
486,
2403,
401,
286,
442,
12260,
11996,
198,
286,
2060,
10714,
10297,
24270,
445,
80,
3975,
7622,
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... | 1 |
#[test]
fn test_partition() {
assert_eq!((box []).partition(|x: &int| *x < 3), (vec![], vec![]));
assert_eq!((box [1, 2, 3]).partition(|x: &int| *x < 4), (vec![1, 2, 3], vec![]));
assert_eq!((box [1, 2, 3]).partition(|x: &int| *x < 2), (vec![1], vec![2, 3]));
assert_eq!((box [1, ... | rust_cleaned_test_functions.jsonl/75612 | {
"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,
43840,
368,
341,
286,
2060,
10714,
0,
1188,
2011,
61556,
40998,
22428,
87,
25,
609,
396,
91,
353,
87,
366,
220,
18,
701,
320,
4083,
0,
12995,
7486,
0,
1294,
1106,
286,
2060,
10714,
0,
1188,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_parameter() {
// Mocked dwarf data //
// Base types
let b0 = Rc::new(Type::Base { name: "short unsigned int".to_owned(), size: 2 });
let b1 = Rc::new(Type::Base { name: "unsigned int".to_owned(), size: 4 });
let b2 = Rc::new(Type::Base { name: "char... | rust_cleaned_test_functions.jsonl/58821 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 769
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
5673,
24899,
368,
1476,
286,
442,
14563,
291,
49461,
821,
34985,
286,
442,
5351,
4494,
198,
286,
1077,
293,
15,
284,
81463,
486,
931,
22498,
486,
3978,
314,
829,
25,
330,
8676,
3774,
526,
3263,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_load_valid_config_data() {
let mut setting = DefaultSetting::new(
Some(TestConfigData { value: 3 }),
"/config/data/fake_config_data.json",
None,
true,
);
assert_eq!(
setting.get_default_value().expect("Failed to... | rust_cleaned_test_functions.jsonl/113471 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 200
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
12411,
8337,
5332,
1769,
368,
341,
286,
1077,
5206,
6243,
284,
7899,
15400,
486,
931,
1006,
310,
4329,
31159,
2648,
1043,
314,
897,
25,
220,
18,
11973,
310,
3521,
1676,
13167,
6663,
726,
5332,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_str_with_data_after_header() {
let s = r#"##fileformat=VCFv4.3
#CHROM POS ID REF ALT QUAL FILTER INFO
##contig=<ID=sq0,length=8>
"#;
assert_eq!(parse(s), Err(ParseError::ExpectedEof));
} | rust_cleaned_test_functions.jsonl/62672 | {
"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,
5673,
2895,
6615,
1769,
19844,
8757,
368,
341,
286,
1077,
274,
284,
435,
55543,
565,
1192,
2243,
28,
53,
9650,
85,
19,
13,
18,
198,
2,
2149,
3361,
197,
17456,
29580,
197,
5996,
197,
35830,
197... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_small_signature_get_field() {
let mut registry = PredicateSignatureSmallRegistry::new();
let signature = PredicateSignatureSmall::new(&"hi".to_owned(), &vec![1, 2, 3], &mut registry);
assert_eq!(signature.get_field(0), 1);
assert_eq!(signature.get_field(1), 2);
assert_eq!(sig... | rust_cleaned_test_functions.jsonl/119999 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 160
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
31966,
39859,
3062,
5013,
368,
341,
262,
1077,
5206,
19424,
284,
49827,
25088,
25307,
15603,
486,
931,
543,
262,
1077,
11957,
284,
49827,
25088,
25307,
486,
931,
2099,
1,
6023,
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... | 1 |
#[test]
fn test_secure_join() {
assert_eq!(
secure_join(Path::new("/tmp/rootfs"), Path::new("path")).unwrap(),
PathBuf::from("/tmp/rootfs/path")
);
assert_eq!(
secure_join(Path::new("/tmp/rootfs"), Path::new("more/path")).unwrap(),
PathBuf:... | rust_cleaned_test_functions.jsonl/51831 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 773
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
73088,
31017,
368,
341,
286,
2060,
10714,
33673,
310,
9767,
31017,
33030,
486,
931,
4283,
5173,
72074,
3848,
3975,
7933,
486,
931,
445,
2343,
15197,
15454,
3148,
310,
7933,
15064,
486,
1499,
4283,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_load1() {
let mut vm = VirtualMachine::new();
vm.add_external_function(
FunctionDeclaration::with_external(
"set_point_x".to_owned(), vec![TypeId::Class("Point".to_owned()), TypeId::Int32], TypeId::Void,
set_point_x as *mut std::ffi::c_void
)
... | rust_cleaned_test_functions.jsonl/17392 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 600
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
12411,
16,
368,
341,
262,
1077,
5206,
10995,
284,
20721,
21605,
486,
931,
1428,
262,
10995,
1364,
47432,
9174,
1006,
286,
5712,
24489,
486,
4197,
47432,
1006,
310,
330,
746,
6085,
3212,
3263,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
#[test]
fn test_docs() {
// Make sure that scripts have non-empty documentation.
for script in StdlibScript::all() {
assert!(
!script.abi().doc().is_empty(),
"The main function in language/stdlib/transaction_scripts/{}.move does not have a `///` inline... | rust_cleaned_test_functions.jsonl/5632 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 209
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
49692,
368,
341,
286,
442,
7405,
2704,
429,
19502,
614,
2477,
39433,
9705,
624,
286,
369,
5316,
304,
42517,
2740,
5910,
486,
541,
368,
341,
310,
2060,
33673,
394,
753,
2282,
22048,
72,
1005,
523... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_vect_add() {
let vec1 = vec![1.0, 2.0, 3.0, 4.0];
let vec2 = vec![1.0, 2.0, 3.0, 4.0];
let vectors = Vectors::new(vec1, vec2).unwrap();
let vec_add = vectors.add();
assert_eq!(vec_add, vec![2.0, 4.0, 6.0, 8.0])
} | rust_cleaned_test_functions.jsonl/60424 | {
"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,
59402,
2891,
368,
341,
286,
1077,
7486,
16,
284,
7486,
20703,
16,
13,
15,
11,
220,
17,
13,
15,
11,
220,
18,
13,
15,
11,
220,
19,
13,
15,
935,
286,
1077,
7486,
17,
284,
7486,
20703,
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... | 1 |
#[test]
fn test_system_time_bounds_assumptions() {
assert_eq!(
::PositiveTimestamp::from_unix_timestamp(::MAX_TIMESTAMP + 1),
Err(::CreationError::TimestampOutOfBounds)
);
} | rust_cleaned_test_functions.jsonl/86633 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 88
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
17687,
3009,
36878,
12083,
372,
1300,
368,
341,
197,
6948,
10714,
33673,
298,
197,
486,
35490,
20812,
486,
1499,
80572,
23073,
38732,
10586,
47854,
488,
220,
16,
1326,
298,
197,
7747,
38732,
32701,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_request_with_normal_priority() {
let builder = PlainNotificationBuilder::new("test");
let payload = builder.build(
"a_test_id",
NotificationOptions {
apns_priority: Some(Priority::Normal),
..Default::default()
}... | rust_cleaned_test_functions.jsonl/109650 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 264
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
7893,
6615,
13973,
38161,
368,
341,
286,
1077,
7363,
284,
43199,
11196,
3297,
486,
931,
445,
1944,
3071,
286,
1077,
7729,
284,
7363,
13239,
1006,
310,
330,
64,
4452,
842,
756,
310,
16571,
3798,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_start_clients_fails() {
let mut exec = fuchsia_async::Executor::new().expect("failed to create an executor");
// Create a configured ClientIfaceContainer.
let test_values = test_setup(&mut exec);
let (mut iface_manager, _) = create_iface_manager_with_client(&test... | rust_cleaned_test_functions.jsonl/62708 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 279
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
4906,
56899,
761,
6209,
368,
341,
286,
1077,
5206,
3883,
284,
282,
73391,
28346,
486,
25255,
486,
931,
1005,
17119,
445,
16091,
311,
1855,
458,
31558,
3071,
286,
442,
4230,
264,
19755,
8423,
40,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_systemtime_overflow() {
assert_de_tokens_error::<SystemTime>(
&[
Token::Seq { len: Some(2) },
Token::U64(u64::max_value()),
Token::U32(0),
Token::SeqEnd,
],
"overflow deserializing SystemTime",
);
} | rust_cleaned_test_functions.jsonl/129553 | {
"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,
17687,
1678,
79073,
368,
341,
262,
2060,
2259,
28838,
4096,
27638,
2320,
1462,
17055,
286,
609,
9640,
310,
9660,
486,
20183,
314,
2422,
25,
4329,
7,
17,
8,
1153,
310,
9660,
486,
52,
21,
19,
81... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_sum() {
let b = Star5Group120 {
list: vec![1, 2, 3, 5, 6, 7, 8],
};
assert_eq!(b.sum(), 21);
let result = &vec![8, 7, 5, 1, 2];
let m = Outcome::new(result, lotto5::transform::all);
let r = b.bin2go(&m);
assert!(r);
} | rust_cleaned_test_functions.jsonl/60046 | {
"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,
10160,
368,
341,
286,
1077,
293,
284,
7679,
20,
2808,
16,
17,
15,
341,
310,
1140,
25,
7486,
20703,
16,
11,
220,
17,
11,
220,
18,
11,
220,
20,
11,
220,
21,
11,
220,
22,
11,
220,
23,
1259,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_supermajority_root_from_vote_accounts() {
let convert_to_vote_accounts =
|roots_stakes: Vec<(Slot, u64)>| -> Vec<(Pubkey, (u64, Account))> {
roots_stakes
.into_iter()
.map(|(root, stake)| {
let mu... | rust_cleaned_test_functions.jsonl/118178 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1063
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
38886,
36505,
487,
12993,
5673,
54360,
55665,
368,
341,
286,
1077,
5508,
2346,
54360,
55665,
4035,
310,
760,
37165,
1261,
2050,
25,
11312,
28706,
19877,
11,
575,
21,
19,
16018,
91,
1464,
11312,
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_execute_detects_invalid_opcode() {
let mut machine = Machine::new(vec![55]);
assert_eq!(machine.execute(), Err(Error::InvalidOpcode {opcode: 55, ip: 0}));
} | rust_cleaned_test_functions.jsonl/43092 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 73
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
44329,
56457,
82,
31433,
71319,
368,
341,
10217,
5206,
5662,
284,
12960,
486,
931,
25592,
20703,
20,
20,
2558,
6948,
10714,
10297,
32056,
7769,
1507,
15495,
37396,
486,
7928,
44189,
314,
48128,
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 |
#[test]
fn test_hover_test_mod_has_action() {
check_actions(
r#"
mod tests$0 {
#[test]
fn foo_test() {}
}
"#,
expect![[r#"
[
Runnable(
Runnable {
nav: NavigationTarget {
... | rust_cleaned_test_functions.jsonl/117788 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 718
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
53445,
4452,
7480,
21778,
7931,
368,
341,
286,
1779,
25368,
1006,
310,
435,
2,
698,
2593,
7032,
3,
15,
341,
262,
11506,
1944,
921,
262,
5168,
15229,
4452,
368,
5613,
532,
57676,
345,
310,
1720,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_quenya() {
quenya("quenya:");
quenya(
"tinco parma calma qessë ando umbar anga ungwë\
\nþúlë formen harma hwesta anto ampa anca unqë\
\nnúmen malta ngoldo ngwalmë orë vala anna wilya\
\nrómen arda lambë alda silmë ázë essë\
\nhyarmen yanta úrë ossë... | rust_cleaned_test_functions.jsonl/54410 | {
"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,
11280,
268,
7755,
368,
341,
262,
922,
268,
7755,
445,
446,
268,
7755,
24305,
262,
922,
268,
7755,
1006,
286,
330,
55971,
1015,
1346,
1728,
1620,
1728,
2804,
433,
12179,
323,
78,
4443,
2257,
6454... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_full_house_ranks() {
test(
&vec!["4H 4S 4D 9S 9D", "5H 5S 5D 8S 8D"],
&vec!["5H 5S 5D 8S 8D"],
)
} | rust_cleaned_test_functions.jsonl/121279 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 98
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
16372,
64270,
1710,
4039,
368,
341,
1066,
262,
1273,
1006,
286,
609,
4083,
0,
1183,
19,
39,
220,
19,
50,
220,
19,
35,
220,
24,
50,
220,
24,
35,
497,
330,
20,
39,
220,
20,
50,
220,
20,
35... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_and_with_multiple_in_to_string() {
let name1 = _random_vector(10);
let value1 = _random_string(10);
let name2 = _random_vector(10);
let value2 = _random_string(10);
let name3 = _random_vector(10);
let value3 = _random_string(10);
let query... | rust_cleaned_test_functions.jsonl/11905 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 762
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
8378,
6615,
45233,
1243,
2346,
3904,
368,
341,
286,
1077,
829,
16,
284,
716,
11463,
12247,
7,
16,
15,
317,
286,
1077,
897,
16,
284,
716,
11463,
3904,
7,
16,
15,
317,
286,
1077,
829,
17,
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_decimal_as_duration() {
test_none_with_ctx_and_extra(cast_decimal_as_duration);
let cs = vec![
Decimal::from(i64::MIN),
Decimal::from(i64::MAX),
Decimal::from(u64::MAX),
Decimal::zero(),
Decimal::from_bytes(b"-922337203... | rust_cleaned_test_functions.jsonl/1993 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 1165
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
74429,
11898,
25454,
368,
341,
286,
1273,
31488,
6615,
15147,
8378,
31858,
1337,
559,
74429,
11898,
25454,
626,
286,
1077,
10532,
284,
7486,
90515,
310,
26728,
486,
1499,
1956,
21,
19,
486,
16413,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_fully_yanked_crate_404s() {
wrapper(|env| {
env.fake_release()
.name("dummy")
.version("1.0.0")
.yanked(true)
.create()?;
assert_eq!(
env.frontend().get("/crate/dummy").send()?.status... | rust_cleaned_test_functions.jsonl/13868 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 352
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
761,
21965,
4178,
40772,
666,
7698,
62,
19,
15,
19,
82,
368,
341,
286,
13261,
22428,
3160,
91,
341,
310,
6105,
94624,
24577,
741,
394,
659,
606,
445,
31390,
1138,
394,
659,
4366,
445,
16,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
#[test]
fn test_step() {
let memory = parse(r#"3,15,3,16,1002,16,10,16,1,16,15,15,4,15,99,0,0"#);
let mut cpu = CPU::new(memory.to_owned(), 0, None);
loop {
match cpu.step() {
Ok(Step::NeedInput) => break,
Ok(Step::Continue) => {}
... | rust_cleaned_test_functions.jsonl/85144 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 274
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
11946,
368,
341,
286,
1077,
4938,
284,
4715,
2601,
55543,
18,
11,
16,
20,
11,
18,
11,
16,
21,
11,
16,
15,
15,
17,
11,
16,
21,
11,
16,
15,
11,
16,
21,
11,
16,
11,
16,
21,
11,
16,
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... | 2 |
#[test]
fn test_color() {
let mut buf = MaybeUninit::uninit();
let string = Color(0xA0A0A0).as_str(&mut buf);
assert_eq!(string, "A0A0A0");
} | rust_cleaned_test_functions.jsonl/23346 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 78
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6714,
368,
341,
262,
1077,
5206,
6607,
284,
10696,
1806,
2327,
486,
359,
2327,
543,
262,
1077,
914,
284,
3478,
7,
15,
14673,
15,
32,
15,
32,
15,
568,
300,
2895,
2099,
6984,
6607,
317,
262,
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 |
#[test]
fn test_try_from_u8_slice() -> Result<(), TryFromByteArrayError> {
let codes = [0x93, 0x1b, 0x6c, 0xb1, 0xc6];
let matrix = SubstitutionMatrix::try_from(codes)?;
let actual = &matrix.substitutions;
let expected = &[
[Base::T, Base::G, Base::C, Base::N],
... | rust_cleaned_test_functions.jsonl/34295 | {
"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,
53283,
5673,
7300,
23,
26488,
368,
1464,
5714,
68843,
9735,
3830,
18394,
1454,
29,
341,
286,
1077,
13912,
284,
508,
15,
87,
24,
18,
11,
220,
15,
87,
16,
65,
11,
220,
15,
87,
21,
66,
11,
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... | 2 |
#[test]
fn test_bytewise_backspace_is_not_word_boundary() {
new_ucmd!()
.args(&["-w10", "-s", "-b"])
.pipe_in("foobar\x0889abcdef")
.succeeds()
.stdout_is("foobar\x0889a\nbcdef");
} | rust_cleaned_test_functions.jsonl/23316 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 129
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
3710,
83,
24350,
3895,
8746,
6892,
7913,
13533,
54004,
368,
341,
262,
501,
68887,
2277,
0,
741,
286,
659,
2116,
2099,
1183,
12,
86,
16,
15,
497,
6523,
82,
497,
6523,
65,
14108,
286,
659,
13768... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_api_public_get_lect_nonexistent_validator() {
let testkit = AnchoringTestKit::default();
let api = testkit.api();
api.current_lect_of_validator(100);
} | rust_cleaned_test_functions.jsonl/80046 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 76
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
11697,
27074,
3062,
62,
767,
21637,
64085,
64959,
368,
341,
262,
1077,
1273,
8226,
284,
71484,
5503,
2271,
7695,
486,
2258,
543,
262,
1077,
6330,
284,
1273,
8226,
6183,
543,
262,
6330,
4952,
62,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_take_i32() {
let cxx = indoc! {"
uint32_t take_int(uint32_t a) {
return a + 3;
}
"};
let hdr = indoc! {"
#include <cstdint>
uint32_t take_int(uint32_t a);
"};
let rs = quote! {
assert_eq!(ffi::take_int(3), 6);
};
run... | rust_cleaned_test_functions.jsonl/9721 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 208
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
73261,
5318,
18,
17,
368,
341,
262,
1077,
272,
4146,
284,
1257,
509,
0,
314,
698,
286,
2622,
18,
17,
528,
1896,
4042,
8488,
18,
17,
528,
264,
8,
341,
310,
470,
264,
488,
220,
18,
280,
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_query_state_hash() {
let sandbox = timestamping_sandbox();
let sandbox_state = SandboxState::new();
//we do not change the state hash in between blocks for TimestampingService for now
for _ in 0..2 {
let state_hash = sandbox.last_state_hash();
let configs_rh = san... | rust_cleaned_test_functions.jsonl/8875 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 714
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
5738,
4387,
8950,
368,
341,
262,
1077,
42754,
284,
11441,
287,
643,
31536,
543,
262,
1077,
42754,
4387,
284,
96860,
1397,
486,
931,
543,
262,
442,
896,
653,
537,
2297,
279,
1584,
5175,
304,
1948... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_with_input() {
use std::env::var;
let path = var("RASTER").expect("env: RASTER not found");
let t = transform_from_dataset(&Dataset::open(Path::new(&path)).unwrap());
for i in 0..3 {
eprint!("[");
for j in 0..3 {
eprint!("{:... | rust_cleaned_test_functions.jsonl/88916 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 297
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6615,
5898,
368,
341,
286,
990,
1460,
486,
3160,
486,
947,
280,
286,
1077,
1815,
284,
762,
445,
5609,
37923,
1827,
17119,
445,
3160,
25,
431,
29651,
537,
1730,
797,
286,
1077,
259,
284,
5165,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_perfect_matching() {
let haystack = "111 a 111b";
let needle = "111 a 111b";
rsearch_test!(haystack, needle, Some(0));
} | rust_cleaned_test_functions.jsonl/19414 | {
"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,
5678,
3751,
70763,
368,
341,
286,
1077,
88447,
284,
330,
16,
16,
16,
264,
220,
16,
16,
16,
65,
876,
286,
1077,
30309,
284,
330,
16,
16,
16,
264,
220,
16,
16,
16,
65,
876,
286,
435,
1836,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_remove_dbg_not_applicable() {
check_assist_not_applicable(remove_dbg, "<|>vec![1, 2, 3]");
check_assist_not_applicable(remove_dbg, "<|>dbg(5, 6, 7)");
check_assist_not_applicable(remove_dbg, "<|>dbg!(5, 6, 7");
} | rust_cleaned_test_functions.jsonl/72614 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 142
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
18193,
44124,
7913,
8191,
46114,
368,
341,
286,
1779,
12083,
380,
7913,
8191,
46114,
67709,
44124,
11,
4055,
91,
29,
4083,
20703,
16,
11,
220,
17,
11,
220,
18,
37389,
286,
1779,
12083,
380,
7913... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_modulation() {
let mut rfm = setup_rfm(Vec::new(), vec![0, 0]);
rfm.modulation(Modulation {
data_mode: DataMode::Packet,
modulation_type: ModulationType::Fsk,
shaping: ModulationShaping::Shaping00,
})
.ok()
.unwrap();
assert_eq!(
rfm.spi.r... | rust_cleaned_test_functions.jsonl/3689 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 716
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
7480,
2914,
368,
341,
262,
1077,
5206,
435,
21112,
284,
6505,
1710,
21112,
49923,
486,
931,
1507,
7486,
20703,
15,
11,
220,
15,
10149,
262,
435,
21112,
10929,
2914,
71956,
2914,
341,
286,
821,
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_is_send_sync() {
let data = ArrayVec::<[Vec<i32>; 5]>::new();
&data as &dyn Send;
&data as &dyn Sync;
} | rust_cleaned_test_functions.jsonl/36767 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 73
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6892,
13565,
23008,
368,
341,
262,
1077,
821,
284,
2910,
10050,
27638,
58,
10050,
21897,
18,
17,
65795,
220,
20,
60,
6831,
931,
543,
262,
609,
691,
438,
609,
43085,
11000,
280,
262,
609,
691,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_treeseq_new_from_tables() {
let tables = make_small_table_collection();
let treeseq = TreeSequence::new(tables, TreeSequenceFlags::default()).unwrap();
let samples = treeseq.sample_nodes();
assert_eq!(samples.len(), 2);
for i in 1..3 {
a... | rust_cleaned_test_functions.jsonl/23022 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 187
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
8657,
528,
265,
2367,
80,
5921,
5673,
35632,
368,
341,
286,
1077,
12632,
284,
1281,
31966,
5237,
25019,
543,
286,
1077,
4258,
2367,
80,
284,
8942,
14076,
486,
931,
1155,
4788,
11,
8942,
14076,
9... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_font_regexp_order1() {
let reg = init_font_regexp();
let caps = reg.captures("bold italic 50px Arial, sans-serif");
assert!(caps.is_some());
let caps = caps.unwrap();
assert_eq!(caps.get(2).map(|m| m.as_str()), Some("italic")); // style
assert_eq!(caps.get(3), None); // variant
ass... | rust_cleaned_test_functions.jsonl/15473 | {
"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,
17451,
4920,
4580,
7869,
16,
368,
341,
220,
1077,
1217,
284,
2930,
17451,
4920,
4580,
543,
220,
1077,
18568,
284,
1217,
520,
2689,
1413,
445,
14824,
60763,
220,
20,
15,
1767,
52771,
11,
15510,
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_refractions() {
let mut world = World::default();
let s1 = Sphere::new(
Matrix::identity(4),
Material::new(
Some(Color::new(0.8, 1.0, 0.6)),
None,
0.1, 0.7, 0.2, 200.0, 0.0, 0.0, 1.0
),
)... | rust_cleaned_test_functions.jsonl/45915 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 744
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
7793,
956,
5136,
368,
341,
286,
1077,
5206,
1879,
284,
4337,
486,
2258,
1428,
286,
1077,
274,
16,
284,
54499,
486,
931,
1006,
310,
11631,
486,
16912,
7,
19,
1326,
310,
10230,
486,
931,
1006,
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_proof_path_len() {
let b = ProofPath::from_raw(*b"\x01qwertyuiopasdfghjklzxcvbnm123456\x00");
assert_eq!(b.len(), 256);
} | rust_cleaned_test_functions.jsonl/25538 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 78
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
86757,
2638,
6043,
368,
341,
262,
1077,
293,
284,
36991,
1820,
486,
1499,
16067,
4071,
65,
11934,
87,
15,
16,
69291,
1344,
1963,
453,
76615,
866,
73,
10561,
89,
8148,
85,
11081,
76,
16,
17,
18... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_dollar_var() {
test_statement(b"select $a+b; $ test; $a+b; $ ;", 12);
test_statement(b"select $a b; $ test; $a b; $ ;", 12);
} | rust_cleaned_test_functions.jsonl/44563 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 77
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
814,
21295,
4612,
368,
341,
262,
1273,
37404,
1883,
1,
1742,
400,
64,
35093,
26,
400,
1273,
26,
400,
64,
35093,
26,
400,
2587,
497,
220,
16,
17,
317,
262,
1273,
37404,
1883,
1,
1742,
400,
64... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_n_peers_for_sanity() {
let a_0 = agent::ZeroAgent::new("tcp://127.0.0.1:5004".to_string());
a_0.activate();
let a_1 = agent::ZeroAgent::new("tcp://127.0.0.1:5005".to_string());
a_1.add_peer("tcp://127.0.0.1:5004".to_string());
a_1.activate();
... | rust_cleaned_test_functions.jsonl/104682 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 327
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
3062,
1089,
36367,
388,
5478,
643,
38270,
368,
341,
286,
1077,
264,
62,
15,
284,
8315,
486,
17999,
16810,
486,
931,
445,
27161,
1110,
16,
17,
22,
13,
15,
13,
15,
13,
16,
25,
20,
15,
15,
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_fold_step_v2() {
let client = graph_serializer(GraphSON::V2);
drop_vertices(&client, "test_fold_step").unwrap();
create_vertex_with_label(&client, "test_fold_step", "Count");
let g = traversal().with_remote(client);
let results = g
.v(())
.has_label("test_... | rust_cleaned_test_functions.jsonl/26292 | {
"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,
61187,
11946,
2273,
17,
368,
341,
262,
1077,
2943,
284,
4771,
67441,
63779,
2703,
486,
53,
17,
626,
262,
5943,
37720,
2099,
2972,
11,
330,
1944,
61187,
11946,
1827,
15454,
1428,
262,
1855,
26611,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_pool_max_idle_per_host() {
let pool = pool_max_idle_no_timer(2);
let key = host_key("foo");
pool.pooled(c(key.clone()), Uniq(41));
pool.pooled(c(key.clone()), Uniq(5));
pool.pooled(c(key.clone()), Uniq(99));
assert_eq!(
pool.... | rust_cleaned_test_functions.jsonl/122373 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 228
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
15709,
6345,
47810,
5678,
12848,
368,
341,
286,
1077,
7314,
284,
7314,
6345,
47810,
6536,
16255,
7,
17,
317,
286,
1077,
1376,
284,
3468,
3097,
445,
7975,
3071,
286,
7314,
556,
45073,
1337,
4857,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_deref_mut_rc() {
let str_pool : Pool<String> = Pool::with_size(1);
let mut rstring = str_pool.new_rc_from("cat");
rstring.push_str("s love eating mice");
assert_eq!("cats love eating mice", *rstring);
} | rust_cleaned_test_functions.jsonl/121186 | {
"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,
814,
43970,
29523,
30299,
368,
341,
414,
1077,
607,
15709,
549,
22728,
3464,
29,
284,
22728,
486,
4197,
2368,
7,
16,
317,
414,
1077,
5206,
435,
917,
284,
607,
15709,
4618,
30299,
5673,
445,
4616... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_write_padded_offset() {
let rng = &mut XorShiftRng::from_seed(crate::TEST_SEED);
let len = 1016;
let mut data: Vec<u8> = (0..len).map(|_| rng.gen()).collect();
let buf = Vec::new();
let mut cursor = Cursor::new(buf);
write_padded(&mut data[..... | rust_cleaned_test_functions.jsonl/33001 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 572
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
6443,
9165,
620,
16828,
6917,
368,
341,
286,
1077,
28422,
284,
609,
6984,
1599,
269,
24841,
49,
968,
486,
1499,
33809,
54907,
486,
10033,
3620,
1479,
626,
286,
1077,
2422,
284,
220,
16,
15,
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_60bit_stream_id() {
// Create new codec object for encoding and decoding our frame.
let mut codec = Codec::new();
// Create a u64 stream ID.
let id: u64 = u32::MAX as u64 + 1;
let stream_id = LocalStreamId {
num: id,
role: Endpoint:... | rust_cleaned_test_functions.jsonl/90009 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 438
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
62,
21,
15,
4489,
12673,
842,
368,
341,
286,
442,
4230,
501,
34647,
1633,
369,
11170,
323,
47116,
1039,
4034,
624,
286,
1077,
5206,
34647,
284,
67077,
486,
931,
543,
286,
442,
4230,
264,
575,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_load_save() {
let spec = Spec {
..Default::default()
};
let test_dir = tempfile::tempdir().expect("failed to create tmp test dir");
let spec_path = test_dir.into_path().join("config.json");
// The before and after should be the same.
... | rust_cleaned_test_functions.jsonl/63325 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 267
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
12411,
15376,
368,
341,
286,
1077,
1398,
284,
10956,
341,
310,
5241,
3675,
486,
2258,
741,
286,
2605,
286,
1077,
1273,
4334,
284,
54819,
486,
3888,
3741,
1005,
17119,
445,
16091,
311,
1855,
4174,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_1() {
let (_temp_dir, deno_dir) = test_setup();
let test_cases = [
(
"./subdir/print_hello.ts",
add_root!("/Users/rld/go/src/github.com/denoland/deno/testdata/006_url_imports.ts"),
add_root!("/Users/rld/go/src/github.com/denoland/deno/testdat... | rust_cleaned_test_functions.jsonl/72752 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 735
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
77291,
10750,
62,
16,
368,
341,
262,
1077,
5453,
3888,
4334,
11,
3371,
78,
4334,
8,
284,
1273,
21363,
1428,
262,
1077,
1273,
41427,
284,
2278,
414,
2399,
286,
5924,
1966,
3741,
92221,
96724,
212... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_file_desc() {
// Run this test with some pipes so we don't have to mess around with
// opening or closing files.
let os::Pipe { reader, writer } = unsafe { os::pipe().unwrap() };
let mut reader = FileDesc::new(reader, true);
let mut writer = FileDesc::new(... | rust_cleaned_test_functions.jsonl/32126 | {
"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,
2458,
10986,
368,
341,
286,
442,
6452,
419,
1273,
448,
1045,
31175,
773,
582,
1513,
944,
614,
311,
9435,
2163,
448,
198,
286,
442,
8568,
476,
15316,
3542,
624,
286,
1077,
2643,
486,
34077,
314,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_method_complex_lex() {
let j_method = "public final Response requestData(String[] arg, Type<String> param, int anotherOne) throws IOException {";
let tokens = lex_contents(&j_method.to_string());
assert_eq!(Token::LineNumber(String::from("1")), tokens[0]);
assert_eq!(Token::Key... | rust_cleaned_test_functions.jsonl/62780 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 506
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
9032,
41522,
74547,
368,
341,
262,
1077,
502,
9032,
284,
330,
888,
1590,
5949,
97264,
2242,
1294,
1392,
11,
3990,
3464,
29,
1685,
11,
526,
2441,
3966,
8,
3787,
9346,
314,
3302,
262,
1077,
11211,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_host_localhost_change_dir() {
let mut host: Localhost = Localhost::new(PathBuf::from("/dev")).ok().unwrap();
let new_dir: PathBuf = PathBuf::from("/dev");
assert!(host.change_wrkdir(new_dir.as_path()).is_ok());
// Verify new files
// Scan dir
let e... | rust_cleaned_test_functions.jsonl/53624 | {
"file_path": "/home/dung/Code/Cross_test_gen (Copy)/clean_data_rust/data/rust_cleaned_test_functions.jsonl",
"token_count": 259
} | [
262,
11506,
1944,
921,
262,
5168,
1273,
12848,
62,
8301,
15947,
4334,
368,
341,
286,
1077,
5206,
3468,
25,
8774,
3790,
284,
8774,
3790,
486,
931,
33030,
15064,
486,
1499,
4283,
3583,
15197,
562,
1005,
15454,
543,
286,
1077,
501,
4334,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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.