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 |
|---|---|---|---|---|---|
func TestAgent_ServiceMaintenance_Disable(t *testing.T) {
t.Parallel()
a := NewTestAgent(t.Name(), "")
defer a.Shutdown()
// Register the service
service := &structs.NodeService{
ID: "test",
Service: "test",
}
if err := a.AddService(service, nil, false, ""); err != nil {
t.Fatalf("err: %v", err)
}
... | explode_data.jsonl/33640 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 362
} | [
2830,
3393,
16810,
52548,
92735,
45525,
480,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
11323,
1669,
1532,
2271,
16810,
1155,
2967,
1507,
14676,
16867,
264,
10849,
18452,
2822,
197,
322,
8451,
279,
2473,
198,
52934,
1669,
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... | 6 |
func TestInjectClient(t *testing.T) {
r := &reconciler{}
orig := r.client
n := fake.NewFakeClient()
if orig == n {
t.Errorf("Original and new clients are identical: %v", orig)
}
err := r.InjectClient(n)
if err != nil {
t.Errorf("Unexpected error injecting the client: %v", err)
}
if n != r.client {
t.Erro... | explode_data.jsonl/7296 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 159
} | [
2830,
3393,
13738,
2959,
1155,
353,
8840,
836,
8,
341,
7000,
1669,
609,
265,
40446,
5769,
16094,
197,
4670,
1669,
435,
6581,
198,
9038,
1669,
12418,
7121,
52317,
2959,
741,
743,
2713,
621,
308,
341,
197,
3244,
13080,
445,
18395,
323,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestStepClock(t *testing.T) {
now := time.Now()
step := time.Second
clock := NewStepClock(now, step)
N := 100
for i := 0; i < N; i++ {
assert.Equal(t, now, clock())
now = now.Add(step)
}
} | explode_data.jsonl/8551 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 88
} | [
2830,
3393,
8304,
26104,
1155,
353,
8840,
836,
8,
341,
80922,
1669,
882,
13244,
741,
77093,
1669,
882,
32435,
198,
84165,
1669,
1532,
8304,
26104,
32263,
11,
3019,
340,
18317,
1669,
220,
16,
15,
15,
198,
2023,
600,
1669,
220,
15,
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... | 2 |
func TestQueryAccount(t *testing.T) {
app, ctx := createTestApp(true)
cdc := app.Codec()
req := abci.RequestQuery{
Path: "",
Data: []byte{},
}
path := []string{types.QueryAccount}
querier := keep.NewQuerier(app.AccountKeeper)
bz, err := querier(ctx, []string{"other"}, req)
require.Error(t, err)
require.... | explode_data.jsonl/73025 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 506
} | [
2830,
3393,
2859,
7365,
1155,
353,
8840,
836,
8,
341,
28236,
11,
5635,
1669,
1855,
2271,
2164,
3715,
340,
1444,
7628,
1669,
906,
20274,
66,
2822,
24395,
1669,
668,
5855,
9659,
2859,
515,
197,
69640,
25,
8324,
197,
40927,
25,
3056,
378... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestMPLS(t *testing.T) {
p := gopacket.NewPacket(testMPLS, LinkTypeEthernet, testDecodeOptions)
if p.ErrorLayer() != nil {
t.Error("Failed to decode packet:", p.ErrorLayer().Error())
}
checkLayers(p, []gopacket.LayerType{LayerTypeEthernet, LayerTypeMPLS, LayerTypeIPv4, LayerTypeICMPv4, gopacket.LayerTypePayl... | explode_data.jsonl/42262 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 145
} | [
2830,
3393,
44,
2916,
50,
1155,
353,
8840,
836,
8,
341,
3223,
1669,
342,
453,
5709,
7121,
16679,
8623,
44,
2916,
50,
11,
5948,
929,
98006,
11,
1273,
32564,
3798,
340,
743,
281,
6141,
9188,
368,
961,
2092,
341,
197,
3244,
6141,
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 |
func TestOnDeactivate(t *testing.T) {
testAPI := &plugintest.API{}
p := NewPlugin(
config.BuildConfig{
Manifest: manifest,
BuildHash: BuildHash,
BuildHashShort: BuildHashShort,
BuildDate: BuildDate,
},
)
p.API = testAPI
mm := pluginapi.NewClient(p.API, p.Driver)
p.conf = config.N... | explode_data.jsonl/13316 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 223
} | [
2830,
3393,
1925,
1912,
16856,
1155,
353,
8840,
836,
8,
341,
18185,
7082,
1669,
609,
47474,
396,
477,
24922,
16094,
3223,
1669,
1532,
11546,
1006,
197,
25873,
25212,
2648,
515,
298,
197,
38495,
25,
981,
14455,
345,
298,
197,
11066,
6370... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestELF32Hash(t *testing.T) {
data := []byte{}
hash := ELF32Hash(data)
if hash != 0 {
t.Logf("Got hash of 0x%08x for no data (expected 0).\n", hash)
t.Fail()
}
data = []byte("Hi there lol")
hash = ELF32Hash(data)
if hash != 0x086c29bc {
t.Logf("Got incorrect PJW hash: 0x%08x\n", hash)
t.Fail()
}
} | explode_data.jsonl/56511 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 148
} | [
2830,
3393,
2749,
37,
18,
17,
6370,
1155,
353,
8840,
836,
8,
341,
8924,
1669,
3056,
3782,
16094,
50333,
1669,
72568,
18,
17,
6370,
2592,
340,
743,
5175,
961,
220,
15,
341,
197,
3244,
98954,
445,
32462,
5175,
315,
220,
15,
87,
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... | 3 |
func Test_Number_LT(t *testing.T) {
testNumberLT(t, "Number", []testNumberValue{
{"1", Number(0), 0, false}, // test zero
{"2", Number(0), -10, false}, // not required
{"3", Number(0).Required(), -10, true}, // required
{"4", Number(1), 1, true}, // smaller than 1
{"5", Num... | explode_data.jsonl/57516 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 842
} | [
2830,
3393,
51799,
65917,
1155,
353,
8840,
836,
8,
341,
18185,
2833,
27404,
1155,
11,
330,
2833,
497,
3056,
1944,
2833,
1130,
515,
197,
197,
4913,
16,
497,
5624,
7,
15,
701,
220,
15,
11,
895,
2137,
1797,
442,
1273,
7168,
198,
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 |
func TestMultipleReplacementSameKey(t *testing.T) {
input := "[name] should say '[name]'"
replacements := map[string]string{
"name": "test",
}
replacer := defaultReplacer{}
assert.Equal(t, "test should say 'test'", replacer.replace(replacements, input), "[name] should be replaced by test")
} | explode_data.jsonl/76421 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 99
} | [
2830,
3393,
32089,
68569,
19198,
1592,
1155,
353,
8840,
836,
8,
341,
22427,
1669,
10545,
606,
60,
1265,
1977,
18309,
606,
30651,
698,
17200,
63535,
1669,
2415,
14032,
30953,
515,
197,
197,
31486,
788,
330,
1944,
756,
197,
532,
17200,
90... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestInsertingProceduralData(t *testing.T) {
//First connect to the cluster. In BTrDB v4 we are advocating that all
//programs use environment variables to specify the endpoint rather
//than assuming specific addresses:
//Set $BTRDB_ENDPOINTS to
//"server1:4410;server2:4410..."
//Note that not all endpoints n... | explode_data.jsonl/64719 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 728
} | [
2830,
3393,
13780,
287,
1336,
1998,
4176,
1043,
1155,
353,
8840,
836,
8,
341,
197,
322,
5338,
4564,
311,
279,
10652,
13,
758,
425,
1282,
3506,
348,
19,
582,
525,
58316,
429,
678,
198,
197,
322,
72953,
990,
4573,
7332,
311,
13837,
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... | 6 |
func TestEntryPointOverride_ToStringSlice(t *testing.T) {
testCases := map[string]struct {
inEntryPointOverride EntryPointOverride
wantedSlice []string
wantedError error
}{
"Both fields are empty": {
inEntryPointOverride: EntryPointOverride{
String: nil,
StringSlice: nil,
},
wantedSlice... | explode_data.jsonl/79727 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 393
} | [
2830,
3393,
97416,
2177,
38346,
703,
33236,
1155,
353,
8840,
836,
8,
341,
18185,
37302,
1669,
2415,
14032,
60,
1235,
341,
197,
17430,
97416,
2177,
72685,
2177,
271,
197,
6692,
7566,
33236,
3056,
917,
198,
197,
6692,
7566,
1454,
1465,
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 |
func TestDisassociateGroupFromUser(t *testing.T) {
ts := httptest.NewTLSServer(
http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
fmt.Fprintln(w, associateGroupWithUserResponse)
}),
)
defer ts.Close()
duo := buildAdminClient(ts.URL, nil)
result, err := duo.DisassociateGroupFromUser("DU3RP9I2... | explode_data.jsonl/61409 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 214
} | [
2830,
3393,
4839,
71531,
2808,
3830,
1474,
1155,
353,
8840,
836,
8,
341,
57441,
1669,
54320,
70334,
7121,
13470,
1220,
2836,
1006,
197,
28080,
89164,
18552,
3622,
1758,
37508,
11,
435,
353,
1254,
9659,
8,
341,
298,
11009,
991,
33655,
36... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestFound(t *testing.T) {
req, rec := setup()
req.SetBasicAuth(user, pass)
wraph(makeFoundAPI(t)).ServeHTTP(rec, req)
res := rec.Result()
if res.StatusCode != http.StatusFound {
t.Error("wrong status code:", res.StatusCode)
}
if res.Header.Get("Location") != location {
t.Error("wrong redirect location... | explode_data.jsonl/21809 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 121
} | [
2830,
3393,
6650,
1155,
353,
8840,
836,
8,
341,
24395,
11,
1395,
1669,
6505,
741,
24395,
4202,
15944,
5087,
4277,
11,
1494,
692,
6692,
1935,
36944,
6650,
7082,
1155,
4579,
60421,
9230,
20635,
11,
4232,
340,
10202,
1669,
1395,
18456,
282... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func Test_SN(t *testing.T) {
// skipInContainer(t)
// sn := SN()
// if sn == "" {
// t.Fatalf("get sn fatal")
// }
// t.Logf("SN:%s", sn)
} | explode_data.jsonl/73745 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 71
} | [
2830,
3393,
47260,
1155,
353,
8840,
836,
8,
341,
197,
322,
10706,
641,
4502,
1155,
340,
197,
322,
4131,
1669,
17924,
741,
197,
322,
421,
4131,
621,
1591,
341,
197,
322,
220,
3244,
30762,
445,
455,
4131,
18582,
1138,
197,
322,
456,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
func TestJQWithArrayQueryProducesRequiredArray(t *testing.T) {
t.Parallel()
input := `{"timestamp": 1649264191, "iss_position": {"longitude": "52.8439", "latitude": "10.8107"}, "message": "success"}`
want := `["10.8107","52.8439"]` + "\n"
got, err := script.Echo(input).JQ("[.iss_position.latitude, .iss_position.lon... | explode_data.jsonl/51485 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 187
} | [
2830,
3393,
41,
48,
2354,
1857,
2859,
49112,
8164,
1857,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
22427,
1669,
1565,
4913,
13035,
788,
220,
16,
21,
19,
24,
17,
21,
19,
16,
24,
16,
11,
330,
1038,
9661,
788,
5212,
25446... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestRangeCacheCoalescedRequests(t *testing.T) {
defer leaktest.AfterTest(t)()
defer log.Scope(t).Close(t)
db := initTestDescriptorDB(t)
ctx := context.Background()
pauseLookupResumeAndAssert := func(key string, expected int64) {
var wg sync.WaitGroup
db.pauseRangeLookups()
// We're going to perform 3 ... | explode_data.jsonl/28185 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 575
} | [
2830,
3393,
6046,
8233,
7339,
3831,
1998,
35295,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
36892,
2271,
1155,
8,
741,
16867,
1487,
77940,
1155,
568,
7925,
1155,
340,
20939,
1669,
2930,
2271,
11709,
3506,
1155,
340,
20985,
1669,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestIsStorageReference(t *testing.T) {
type args struct {
link string
}
tests := []struct {
name string
args args
want bool
}{
{
name: "Simple ID",
args: args{
link: "f4d71508-bec6-4db9-9694-d2d028db6cef",
},
want: true,
},
{
name: "Storage Prefix + ID",
args: args{
link... | explode_data.jsonl/79921 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 608
} | [
2830,
3393,
3872,
5793,
8856,
1155,
353,
8840,
836,
8,
341,
13158,
2827,
2036,
341,
197,
54238,
914,
198,
197,
532,
78216,
1669,
3056,
1235,
341,
197,
11609,
914,
198,
197,
31215,
2827,
198,
197,
50780,
1807,
198,
197,
59403,
197,
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... | 2 |
func TestCryptionHandlerGet(t *testing.T) {
req := httptest.NewRequest(http.MethodGet, "/any", nil)
handler := CryptionHandler(aesKey)(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
_, err := w.Write([]byte(respText))
w.Header().Set("X-Test", "test")
assert.Nil(t, err)
}))
recorder := httptes... | explode_data.jsonl/24316 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 251
} | [
2830,
3393,
34,
15597,
3050,
1949,
1155,
353,
8840,
836,
8,
341,
24395,
1669,
54320,
70334,
75274,
19886,
20798,
1949,
11,
3521,
3767,
497,
2092,
340,
53326,
1669,
356,
15597,
3050,
2877,
288,
1592,
2376,
1254,
89164,
18552,
3622,
1758,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestGetContainerUsageNanoCores(t *testing.T) {
var value0 uint64
var value1 uint64 = 10000000000
// Test with a large container of 100+ CPUs
var value2 uint64 = 188427786383
tests := []struct {
desc string
cpuUsageCache map[string]*cpuUsageRecord
stats *runtimeapi.ContainerStats
exp... | explode_data.jsonl/7537 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1696
} | [
2830,
3393,
1949,
4502,
14783,
83819,
34,
4589,
1155,
353,
8840,
836,
8,
341,
2405,
897,
15,
2622,
21,
19,
198,
2405,
897,
16,
2622,
21,
19,
284,
220,
16,
15,
15,
15,
15,
15,
15,
15,
15,
15,
15,
271,
197,
322,
3393,
448,
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,
1,
1,
1,
1... | 2 |
func TestLess(t *testing.T) {
t.Parallel()
if id2.Less(id1) {
t.Errorf("'%s'.Less(%s) should be true", id2.PublicKeyHex(), id1.PublicKeyHex())
}
if !id1.Less(id2) {
t.Errorf("'%s'.Less(%s) should be false", id1.PublicKeyHex(), id2.PublicKeyHex())
}
if !id1.Less(id3) {
t.Errorf("'%s'.Less(%s) should be fa... | explode_data.jsonl/7128 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 178
} | [
2830,
3393,
27451,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
743,
877,
17,
1214,
433,
3724,
16,
8,
341,
197,
3244,
13080,
445,
36165,
82,
4427,
27451,
15238,
82,
8,
1265,
387,
830,
497,
877,
17,
49139,
1592,
20335,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
func TestMultiClusterUpdateCanUpdateCluster(t *testing.T) {
mc := newMultiCluster()
ci := pb.ClusterInfo{
ClusterId: 1,
NodeId: 2,
IsLeader: true,
Nodes: map[uint64]string{1: "a1", 2: "a2", 3: "a3"},
ConfigChangeIndex: 1,
}
nhi := pb.NodeHostInfo{
RaftAddress: "a2... | explode_data.jsonl/24609 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 936
} | [
2830,
3393,
20358,
28678,
4289,
6713,
4289,
28678,
1155,
353,
8840,
836,
8,
341,
97662,
1669,
501,
20358,
28678,
741,
1444,
72,
1669,
17310,
72883,
1731,
515,
197,
197,
28678,
764,
25,
260,
220,
16,
345,
197,
30217,
764,
25,
310,
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... | 9 |
func TestMetaWorker_HandleRequest(t *testing.T) {
formatStr := "RadioChecker API (C) %d The RadioChecker Authors. All rights reserved. " +
"(Version: %s / Build: %s / Revision: %s)"
expectedResult := fmt.Sprintf(formatStr, time.Now().Year(), Version, Build, Revision)
result, err := MetaWorker{}.HandleRequest()
if... | explode_data.jsonl/24721 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 165
} | [
2830,
3393,
12175,
21936,
42714,
1900,
1155,
353,
8840,
836,
8,
341,
59416,
2580,
1669,
330,
28203,
35188,
5333,
320,
34,
8,
1018,
67,
576,
13484,
35188,
24124,
13,
2009,
3188,
4591,
13,
330,
3610,
197,
197,
29209,
5637,
25,
1018,
82,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestPatch(t *testing.T) {
program, err := expr.Compile(
`Ticket == "$100" and "$90" != Ticket + "0"`,
expr.Env(mockEnv{}),
expr.Patch(&stringerPatcher{}),
)
require.NoError(t, err)
env := mockEnv{
Ticket: &ticket{Price: 100},
}
output, err := expr.Run(program, env)
require.NoError(t, err)
require.... | explode_data.jsonl/36912 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 150
} | [
2830,
3393,
43622,
1155,
353,
8840,
836,
8,
341,
197,
14906,
11,
1848,
1669,
15169,
89323,
1006,
197,
197,
63,
34058,
621,
5201,
16,
15,
15,
1,
323,
5201,
24,
15,
1,
961,
28397,
488,
330,
15,
1,
12892,
197,
8122,
649,
81214,
30389... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestDeleteMigrationsNoMigrationName(t *testing.T) {
cmdArgs := []string{"delete", "migrations"}
var migrationList storkv1.MigrationList
expected := "error: At least one argument needs to be provided for migration name"
testCommon(t, cmdArgs, &migrationList, expected, true)
} | explode_data.jsonl/18259 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 86
} | [
2830,
3393,
6435,
44,
17824,
2753,
20168,
675,
1155,
353,
8840,
836,
8,
341,
25920,
4117,
1669,
3056,
917,
4913,
4542,
497,
330,
76,
17824,
63159,
2405,
11906,
852,
357,
669,
85,
16,
1321,
5033,
852,
198,
42400,
1669,
330,
841,
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 |
func TestMakeParentDir(t *testing.T) {
type args struct {
p string
}
tests := []struct {
name string
args args
wantParentDir string
wantErr bool
}{
{name: "valid", args: args{p: "/tmp/gg/hh"},
wantParentDir: "/tmp/gg",
wantErr: false},
{name: "perm_denied", args: ar... | explode_data.jsonl/46406 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 373
} | [
2830,
3393,
8078,
8387,
6184,
1155,
353,
8840,
836,
8,
341,
13158,
2827,
2036,
341,
197,
3223,
914,
198,
197,
532,
78216,
1669,
3056,
1235,
341,
197,
11609,
688,
914,
198,
197,
31215,
688,
2827,
198,
197,
50780,
8387,
6184,
914,
198,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestRelease_MirrorDelete(t *testing.T) {
assert.NoError(t, models.PrepareTestDatabase())
user := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
repoPath := models.RepoPath(user.Name, repo.Name)
o... | explode_data.jsonl/68215 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 874
} | [
2830,
3393,
16077,
1245,
28812,
6435,
1155,
353,
8840,
836,
8,
341,
6948,
35699,
1155,
11,
4119,
28770,
3380,
2271,
5988,
12367,
19060,
1669,
4119,
11711,
15575,
3036,
5879,
10437,
1155,
11,
609,
6507,
7344,
90,
915,
25,
220,
17,
16630,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestTimeoutHandlerSuccess(t *testing.T) {
ln := fasthttputil.NewInmemoryListener()
h := func(ctx *RequestCtx) {
if string(ctx.Path()) == "/" {
ctx.Success("aaa/bbb", []byte("real response"))
}
}
s := &Server{
Handler: TimeoutHandler(h, 10*time.Second, "timeout!!!"),
}
serverCh := make(chan struct{})... | explode_data.jsonl/73298 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 535
} | [
2830,
3393,
7636,
3050,
7188,
1155,
353,
8840,
836,
8,
341,
197,
2261,
1669,
4937,
96336,
628,
321,
7121,
641,
17269,
2743,
741,
9598,
1669,
2915,
7502,
353,
1900,
23684,
8,
341,
197,
743,
914,
7502,
17474,
2140,
621,
16891,
341,
298,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestBindTupleCons(t *testing.T) {
env := environment(map[string]interface{}{
"a": NewOutputType(StringType),
"b": NewPromiseType(StringType),
"c": NewUnionType(StringType, BoolType),
})
scope := env.scope()
cases := []exprTestCase{
{x: `["foo", "bar", "baz"]`, t: NewTupleType(StringType, StringType, S... | explode_data.jsonl/42573 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 403
} | [
2830,
3393,
9950,
28681,
15220,
1155,
353,
8840,
836,
8,
341,
57538,
1669,
4573,
9147,
14032,
31344,
67066,
197,
197,
56693,
788,
1532,
5097,
929,
2242,
929,
1326,
197,
197,
1,
65,
788,
1532,
21041,
929,
2242,
929,
1326,
197,
197,
969... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestWriteError(t *testing.T) {
testRecorder := httptest.NewRecorder()
writeError(testRecorder, testKind, testMessage)
if testRecorder.Code != statusNotOk {
t.Fail()
t.Logf(fmt.Sprint("expected: ", statusNotOk, ", found: ", testRecorder.Code))
}
var errors ErrorDeclarations
json.NewDecoder(testRecorder.... | explode_data.jsonl/48434 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 267
} | [
2830,
3393,
7985,
1454,
1155,
353,
8840,
836,
8,
341,
18185,
47023,
1669,
54320,
70334,
7121,
47023,
741,
24945,
1454,
8623,
47023,
11,
1273,
10629,
11,
1273,
2052,
692,
743,
1273,
47023,
20274,
961,
2639,
2623,
11578,
341,
197,
3244,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 5 |
func Test_UpdateBatchByCache(t *testing.T) {
helper := sysutil.NewFileTestUtil(t)
absFile := path.Join(helper.TempDir, commonTestFile)
tests := []struct {
name string
initCache []ResourceUpdater
initFiles []ResourceUpdater
reconcileInfos []reconcileInfo
}{
{
name: "test_cache_equ... | explode_data.jsonl/56862 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1908
} | [
2830,
3393,
47393,
21074,
1359,
8233,
1155,
353,
8840,
836,
8,
1476,
9598,
2947,
1669,
5708,
1314,
7121,
1703,
2271,
2742,
1155,
692,
197,
3435,
1703,
1669,
1815,
22363,
80434,
65009,
6184,
11,
4185,
2271,
1703,
692,
78216,
1669,
3056,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestUsingExternalCA(t *testing.T) {
tests := []struct {
setupFuncs []func(cfg *kubeadmapi.InitConfiguration) error
expected bool
}{
{
setupFuncs: []func(cfg *kubeadmapi.InitConfiguration) error{
CreatePKIAssets,
},
expected: false,
},
{
setupFuncs: []func(cfg *kubeadmapi.InitConfigura... | explode_data.jsonl/58626 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 493
} | [
2830,
3393,
16429,
25913,
5049,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
1235,
341,
197,
84571,
9626,
82,
3056,
2830,
28272,
353,
74,
392,
3149,
76,
2068,
26849,
7688,
8,
1465,
198,
197,
42400,
256,
1807,
198,
197,
59403,
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 |
func TestMultiWindowProcessing(t *testing.T) {
// Set up our SDF to block on the second window of four, at the second
// position of the restriction. (i.e. window at 0.5 progress, full element
// at 0.375 progress)
blockW := 1
wsdf := WindowBlockingSdf{
block: make(chan struct{}),
claim: 1,
w: testMultiW... | explode_data.jsonl/51817 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1224
} | [
2830,
3393,
20358,
4267,
28892,
1155,
353,
8840,
836,
8,
341,
197,
322,
2573,
705,
1039,
328,
5262,
311,
2504,
389,
279,
2086,
3241,
315,
3040,
11,
518,
279,
2086,
198,
197,
322,
2309,
315,
279,
19455,
13,
320,
72,
1734,
13,
3241,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestTerminateAnalysisRun(t *testing.T) {
newRun := StartTerminatingAnalysisRun(t, false)
assert.Equal(t, v1alpha1.AnalysisPhaseSuccessful, newRun.Status.Phase)
assert.Equal(t, "Run Terminated", newRun.Status.Message)
} | explode_data.jsonl/75850 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 78
} | [
2830,
3393,
62519,
26573,
6727,
1155,
353,
8840,
836,
8,
341,
8638,
6727,
1669,
5145,
21209,
64283,
26573,
6727,
1155,
11,
895,
340,
6948,
12808,
1155,
11,
348,
16,
7141,
16,
8624,
9092,
30733,
36374,
11,
501,
6727,
10538,
35989,
519,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
func TestPathManifestReader_Read(t *testing.T) {
_ = apiextv1.AddToScheme(scheme.Scheme)
testCases := map[string]struct {
manifests map[string]string
namespace string
expectedObjs []object.ObjMetadata
expectedErrMsg string
}{
"Empty package is ok": {
manifests: map[string]string{},
nam... | explode_data.jsonl/23155 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1896
} | [
2830,
3393,
1820,
38495,
5062,
38381,
1155,
353,
8840,
836,
8,
341,
197,
62,
284,
6330,
427,
85,
16,
1904,
1249,
28906,
1141,
8058,
92719,
340,
18185,
37302,
1669,
2415,
14032,
60,
1235,
341,
197,
197,
42315,
82,
414,
2415,
14032,
309... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestOrderingServiceConnFailure(t *testing.T) {
testOrderingServiceConnFailure(t, blockDelivererConsumerWithRecv)
testOrderingServiceConnFailure(t, blockDelivererConsumerWithSend)
connWG.Wait()
} | explode_data.jsonl/60870 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 64
} | [
2830,
3393,
4431,
287,
1860,
9701,
17507,
1155,
353,
8840,
836,
8,
341,
18185,
4431,
287,
1860,
9701,
17507,
1155,
11,
2504,
16532,
1524,
261,
29968,
2354,
63483,
340,
18185,
4431,
287,
1860,
9701,
17507,
1155,
11,
2504,
16532,
1524,
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 |
func TestPipelineRunDescribe_without_start_time(t *testing.T) {
clock := clockwork.NewFakeClock()
pipelineRuns := []*v1alpha1.PipelineRun{
tb.PipelineRun("pipeline-run", "ns",
cb.PipelineRunCreationTimestamp(clock.Now()),
tb.PipelineRunLabel("tekton.dev/pipeline", "pipeline"),
tb.PipelineRunSpec("pipeline... | explode_data.jsonl/7908 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 518
} | [
2830,
3393,
34656,
6727,
74785,
39904,
4906,
3009,
1155,
353,
8840,
836,
8,
341,
84165,
1669,
8866,
1778,
7121,
52317,
26104,
2822,
3223,
8790,
73920,
1669,
29838,
85,
16,
7141,
16,
1069,
8790,
6727,
515,
197,
62842,
1069,
8790,
6727,
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... | 3 |
func TestPFlagProvider(t *testing.T) {
const schema = `
{
"type": "object",
"properties": {
"foo": {
"type": "string"
}
}
}
`
ctx := context.Background()
s, err := jsonschema.CompileString(ctx, "", schema)
require.NoError(t, err)
t.Run("only parses known flags", func(t *testing.T) {
flags := pflag.Ne... | explode_data.jsonl/36280 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 296
} | [
2830,
3393,
47,
12135,
5179,
1155,
353,
8840,
836,
8,
341,
4777,
10802,
284,
22074,
515,
220,
330,
1313,
788,
330,
1700,
756,
220,
330,
13193,
788,
341,
197,
1,
7975,
788,
341,
3677,
330,
1313,
788,
330,
917,
698,
197,
532,
220,
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 |
func TestSCRAMSASLPrep(t *testing.T) {
type stringStruct struct {
password string
expected string
}
// some of the testing methodology for this is borrowed from:
//
// https://github.com/MagicStack/asyncpg/blob/master/tests/test_connect.py#L276-L287
tests := []stringStruct{
stringStruct{password: "hippo", ... | explode_data.jsonl/28542 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 356
} | [
2830,
3393,
3540,
33905,
50,
1911,
43,
4703,
79,
1155,
353,
8840,
836,
8,
341,
13158,
914,
9422,
2036,
341,
197,
58199,
914,
198,
197,
42400,
914,
198,
197,
630,
197,
322,
1045,
315,
279,
7497,
37052,
369,
419,
374,
45564,
504,
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... | 2 |
func TestInjectionEnabled(t *testing.T) {
type testCase struct {
name string
annotations map[string]string
expect bool
}
testcases := []testCase{
{
name: "enable_Injection_done",
annotations: map[string]string{
common.InjectSidecarDone: "true",
},
expect: true,
}, {
name: "d... | explode_data.jsonl/35575 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 339
} | [
2830,
3393,
36653,
5462,
1155,
353,
8840,
836,
8,
341,
13158,
54452,
2036,
341,
197,
11609,
286,
914,
198,
197,
197,
39626,
2415,
14032,
30953,
198,
197,
24952,
414,
1807,
198,
197,
630,
18185,
23910,
1669,
3056,
66194,
515,
197,
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... | 3 |
func TestBQDatasetFromMetadata(t *testing.T) {
dm := DatasetMetadataToUpdate{
Description: "desc",
Name: "name",
DefaultTableExpiration: time.Hour,
}
dm.SetLabel("label", "value")
dm.DeleteLabel("del")
got := bqDatasetFromMetadata(&dm)
want := &bq.Dataset{
Description: "desc",
Frien... | explode_data.jsonl/70126 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 284
} | [
2830,
3393,
33,
48,
33363,
3830,
14610,
1155,
353,
8840,
836,
8,
341,
2698,
76,
1669,
39183,
14610,
93919,
515,
197,
47414,
25,
330,
8614,
756,
197,
21297,
25,
286,
330,
606,
756,
197,
91084,
2556,
66301,
25,
882,
73550,
345,
197,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestServerlessRecordCustomMetric(t *testing.T) {
cfgFn := func(cfg *Config) { cfg.ServerlessMode.Enabled = true }
app := testApp(nil, cfgFn, t)
app.RecordCustomMetric("myMetric", 123.0)
app.expectSingleLoggedError(t, "unable to record custom metric", map[string]interface{}{
"metric-name": "myMetric",
"reas... | explode_data.jsonl/52867 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 139
} | [
2830,
3393,
5475,
1717,
6471,
10268,
54310,
1155,
353,
8840,
836,
8,
341,
50286,
24911,
1669,
2915,
28272,
353,
2648,
8,
314,
13286,
22997,
1717,
3636,
13690,
284,
830,
456,
28236,
1669,
1273,
2164,
27907,
11,
13286,
24911,
11,
259,
340... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestPruneFiles(t *testing.T) {
// Create temp dir to test in
dir := t.TempDir()
files := []string{
"file1.txt",
"file2.png",
}
// Create our test files
for _, file := range files {
path := filepath.Join(dir, file)
f, err := os.Create(path)
if err != nil {
t.Fatalf("error creating test file: %s... | explode_data.jsonl/30985 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 234
} | [
2830,
3393,
3533,
2886,
10809,
1155,
353,
8840,
836,
8,
341,
197,
322,
4230,
2730,
5419,
311,
1273,
304,
198,
48532,
1669,
259,
65009,
6184,
2822,
74075,
1669,
3056,
917,
515,
197,
197,
1,
1192,
16,
3909,
756,
197,
197,
1,
1192,
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... | 5 |
func TestJSONValuesMessage(t *testing.T) {
timestamp := time.Unix(1, 0)
values := []float64{
-0.5182926829268293,
-0.3582317073170732,
0.1753048780487805,
0.20599365234375,
-0.050048828125,
1.03582763671875,
}
msg := fmt.Sprintf(`{"ax": %v, "ay": %v, "az": %v, "gx": %v, "gy": %v, "gz": %v}`,
values[0]... | explode_data.jsonl/79407 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 392
} | [
2830,
3393,
5370,
6227,
2052,
1155,
353,
8840,
836,
8,
341,
3244,
4702,
1669,
882,
10616,
941,
7,
16,
11,
220,
15,
340,
45939,
1669,
3056,
3649,
21,
19,
515,
197,
197,
12,
15,
13,
20,
16,
23,
17,
24,
17,
21,
23,
17,
24,
17,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestWorker_DoTask_Err(t *testing.T) {
// setup
nopProducer, _ := bus.NewProducer(bus.NewOptions("nop"))
cnclCtx, cncl := context.WithCancel(context.Background())
cncl()
pths := []string{
"./test/test.json",
}
createdDates := []time.Time{
time.Date(2016, 01, 01, 00, 00, 00, 00, time.UTC),
time.Date(2... | explode_data.jsonl/77120 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1490
} | [
2830,
3393,
21936,
93481,
6262,
93623,
1155,
353,
8840,
836,
8,
341,
197,
322,
6505,
198,
9038,
453,
45008,
11,
716,
1669,
5828,
7121,
45008,
60872,
7121,
3798,
445,
62813,
5455,
1444,
77,
564,
23684,
11,
13665,
564,
1669,
2266,
26124,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestClient_UpdateServer_validation(t *testing.T) {
var err error
_, err = testClient.UpdateServer(&UpdateServerInput{
ServiceID: "",
})
if err != ErrMissingServiceID {
t.Errorf("bad error: %s", err)
}
_, err = testClient.UpdateServer(&UpdateServerInput{
ServiceID: "foo",
PoolID: "",
})
if err !... | explode_data.jsonl/8322 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 225
} | [
2830,
3393,
2959,
47393,
5475,
19416,
1155,
353,
8840,
836,
8,
341,
2405,
1848,
1465,
198,
197,
6878,
1848,
284,
1273,
2959,
16689,
5475,
2099,
4289,
5475,
2505,
515,
197,
91619,
915,
25,
8324,
197,
3518,
743,
1848,
961,
15495,
25080,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestDuplicateKeys(t *testing.T) {
// this is vaild jsonStr according to the JSON spec
var jsonStr = `{"name": "Alex","name": "Peter"}`
if Parse(jsonStr).Get("name").String() !=
Parse(jsonStr).Map()["name"].String() {
t.Fatalf("expected '%v', got '%v'",
Parse(jsonStr).Get("name").String(),
Parse(jsonSt... | explode_data.jsonl/43458 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 168
} | [
2830,
3393,
53979,
8850,
1155,
353,
8840,
836,
8,
341,
197,
322,
419,
374,
348,
604,
67,
2951,
2580,
4092,
311,
279,
4718,
1398,
198,
2405,
2951,
2580,
284,
1565,
4913,
606,
788,
330,
27387,
2198,
606,
788,
330,
36559,
9207,
3989,
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... | 3 |
func TestList(t *testing.T) {
/*
Create the following structure:
mytestfiles
mytestfiles/foo.js
mytestfiles/subdir/bar.js
*/
dir := fs.NewDir(t, "mytestfiles",
fs.WithFile("foo.js", "foo", fs.WithMode(0755)),
fs.WithDir("mysubdir", fs.WithFile("bar.js", "bar", fs.WithMode(0755))),
)
defer dir.Remove... | explode_data.jsonl/72031 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 526
} | [
2830,
3393,
852,
1155,
353,
8840,
836,
8,
341,
197,
3284,
197,
75569,
279,
2701,
5944,
510,
298,
13624,
1944,
7198,
198,
298,
13624,
1944,
7198,
60555,
2857,
198,
298,
13624,
1944,
7198,
37885,
3741,
49513,
2857,
198,
197,
3276,
48532,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestMapProxy_SetWithNilValue(t *testing.T) {
err := mp.Set("test", nil)
AssertErrorNotNil(t, err, "set did not return an error for nil value")
mp.Clear()
} | explode_data.jsonl/57008 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 62
} | [
2830,
3393,
2227,
16219,
14812,
2354,
19064,
1130,
1155,
353,
8840,
836,
8,
341,
9859,
1669,
10490,
4202,
445,
1944,
497,
2092,
340,
18017,
1454,
96144,
1155,
11,
1848,
11,
330,
746,
1521,
537,
470,
458,
1465,
369,
2092,
897,
1138,
53... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
func TestJobSpecsController_Create(t *testing.T) {
t.Parallel()
app, cleanup := cltest.NewApplication()
defer cleanup()
client := app.NewHTTPClient()
resp, cleanup := client.Post("/v2/specs", bytes.NewBuffer(cltest.LoadJSON("../internal/fixtures/web/hello_world_job.json")))
defer cleanup()
cltest.AssertServerR... | explode_data.jsonl/53686 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 480
} | [
2830,
3393,
12245,
8327,
82,
2051,
34325,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
28236,
11,
21290,
1669,
1185,
1944,
7121,
4988,
741,
16867,
21290,
741,
25291,
1669,
906,
7121,
9230,
2959,
2822,
34653,
11,
21290,
1669,
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 |
func TestModifyOrder(t *testing.T) {
t.Parallel()
_, err := b.ModifyOrder(context.Background(),
&order.Modify{AssetType: asset.Spot})
if err == nil {
t.Error("ModifyOrder() error cannot be nil")
}
} | explode_data.jsonl/76673 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 80
} | [
2830,
3393,
44427,
4431,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
197,
6878,
1848,
1669,
293,
23127,
1437,
4431,
5378,
19047,
3148,
197,
197,
5,
1358,
23127,
1437,
90,
16604,
929,
25,
9329,
808,
19099,
3518,
743,
1848,
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,
1,
1,
1,
1,
1,
1,
1,
1
] | 2 |
func TestVisitor(t *testing.T) {
d := ABData{A: 111, B: 222}
add := &AddVisitor{}
sub := &SubVisitor{}
d.Accept(add)
d.Accept(sub)
} | explode_data.jsonl/24667 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 65
} | [
2830,
3393,
16796,
1155,
353,
8840,
836,
8,
341,
2698,
1669,
14137,
1043,
90,
32,
25,
220,
16,
16,
16,
11,
425,
25,
220,
17,
17,
17,
532,
12718,
1669,
609,
2212,
16796,
16094,
28624,
1669,
609,
3136,
16796,
16094,
2698,
52265,
25906... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
func TestEtcdGetController(t *testing.T) {
ctx := api.NewDefaultContext()
fakeClient := tools.NewFakeEtcdClient(t)
key, _ := makeControllerKey(ctx, "foo")
fakeClient.Set(key, runtime.EncodeOrDie(latest.Codec, &api.ReplicationController{TypeMeta: api.TypeMeta{ID: "foo"}}), 0)
registry := NewTestEtcdRegistry(fakeCli... | explode_data.jsonl/8158 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 196
} | [
2830,
3393,
31860,
4385,
1949,
2051,
1155,
353,
8840,
836,
8,
341,
20985,
1669,
6330,
7121,
3675,
1972,
741,
1166,
726,
2959,
1669,
7375,
7121,
52317,
31860,
4385,
2959,
1155,
340,
23634,
11,
716,
1669,
1281,
2051,
1592,
7502,
11,
330,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestMulInt(t *testing.T) {
tests := []struct {
in1 string //
in2 uint //
expected string //预期十六进制编码值
}{
{"0", 0, "0"},
{"1", 0, "0"},
{"0", 1, "0"},
{"1", 1, "1"},
//
{
"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2e",
2,
"fffffffffffffffffffffffffffffffffffffffff... | explode_data.jsonl/366 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 862
} | [
2830,
3393,
59155,
1072,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
1235,
341,
258,
16,
414,
914,
6475,
258,
17,
414,
2622,
256,
6475,
7325,
914,
442,
104394,
102853,
41299,
43316,
112950,
25511,
198,
197,
59403,
197,
197,
4913,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestInstallConfigGenerate(t *testing.T) {
cases := []struct {
name string
platformContents []string
expectedPlatformYaml string
}{
{
name: "aws",
platformContents: []string{
"aws",
"test-region",
},
expectedPlatformYaml: ` aws:
region: test-region
vpcCIDRB... | explode_data.jsonl/75055 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1380
} | [
2830,
3393,
24690,
2648,
31115,
1155,
353,
8840,
836,
8,
341,
1444,
2264,
1669,
3056,
1235,
341,
197,
11609,
338,
914,
198,
197,
197,
15734,
14803,
257,
3056,
917,
198,
197,
42400,
17296,
56,
9467,
914,
198,
197,
59403,
197,
197,
515,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestReportWorkflowResource_ScheduledWorkflowIDNotEmpty_Success(t *testing.T) {
store, manager, job := initWithJob(t)
defer store.Close()
// report workflow
workflow := util.NewWorkflow(&v1alpha1.Workflow{
ObjectMeta: v1.ObjectMeta{
Name: "MY_NAME",
Namespace: "MY_NAMESPACE",
UID: "WORKFL... | explode_data.jsonl/28390 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 796
} | [
2830,
3393,
10361,
62768,
4783,
1098,
26644,
62768,
915,
27416,
87161,
1155,
353,
8840,
836,
8,
341,
57279,
11,
6645,
11,
2618,
1669,
13864,
12245,
1155,
340,
16867,
3553,
10421,
2822,
197,
322,
1895,
28288,
198,
197,
56249,
1669,
4094,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestFindAllPasswords(t *testing.T) {
t.Run("check FindAllPasswords", func(t *testing.T) {
got := FindAllPasswords("111111", "111112")
want := 2
if got != want {
log.Fatalf("want: %d, got: %d", want, got)
}
})
t.Run("check hasAdjacentNumber", func(t *testing.T) {
got := hasAdjacentNumber(111111)
... | explode_data.jsonl/28614 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 230
} | [
2830,
3393,
9885,
2403,
84546,
1155,
353,
8840,
836,
8,
341,
3244,
16708,
445,
2028,
7379,
2403,
84546,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
3174,
354,
1669,
7379,
2403,
84546,
445,
16,
16,
16,
16,
16,
16,
497,
330,
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... | 2 |
func TestOptRuleBlacklist(t *testing.T) {
store, clean := testkit.CreateMockStore(t)
defer clean()
tk := testkit.NewTestKit(t, store)
tk.MustQuery(`select * from mysql.opt_rule_blacklist`).Check(testkit.Rows())
} | explode_data.jsonl/65491 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 82
} | [
2830,
3393,
21367,
11337,
14417,
1607,
1155,
353,
8840,
836,
8,
341,
57279,
11,
4240,
1669,
1273,
8226,
7251,
11571,
6093,
1155,
340,
16867,
4240,
2822,
3244,
74,
1669,
1273,
8226,
7121,
2271,
7695,
1155,
11,
3553,
340,
3244,
74,
50463,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
func TestCommitBeforeApply(t *testing.T) {
ctrl := gomock.NewController(t)
defer ctrl.Finish()
rangeManager := mock.NewMockentryCataloger(ctrl)
rocks := onboard.NewCatalogRepoActions(&onboard.Config{
CommitUsername: committer,
RepositoryID: repoID,
DefaultBranchID: "master",
EntryCatalog: rangeManag... | explode_data.jsonl/31617 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 195
} | [
2830,
3393,
33441,
10227,
28497,
1155,
353,
8840,
836,
8,
341,
84381,
1669,
342,
316,
1176,
7121,
2051,
1155,
340,
16867,
23743,
991,
18176,
741,
75087,
2043,
1669,
7860,
7121,
11571,
4085,
41606,
261,
62100,
692,
197,
299,
14553,
1669,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestNewLRUCache(t *testing.T) {
t.Parallel()
size := 2000
c, _ := lru.New(2000)
type args struct {
size int
}
tests := []struct {
name string
args args
want *LRU
}{
{
name: "Test_NewLRUCache_OK",
args: args{size: size},
want: &LRU{
Cache: c,
},
},
}
for _, tt := range tests {... | explode_data.jsonl/46945 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 267
} | [
2830,
3393,
3564,
20117,
5459,
1777,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
13832,
1669,
220,
17,
15,
15,
15,
198,
1444,
11,
716,
1669,
326,
2672,
7121,
7,
17,
15,
15,
15,
692,
13158,
2827,
2036,
341,
197,
13832,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestFilterMatchDefault(t *testing.T) {
p, err := graphite.NewParser([]string{"servers.localhost .host.measurement*"}, nil)
if err != nil {
t.Fatalf("unexpected error creating parser, got %v", err)
}
exp := models.MustNewPoint("miss.servers.localhost.cpu_load",
models.NewTags(map[string]string{}),
models... | explode_data.jsonl/32177 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 237
} | [
2830,
3393,
5632,
8331,
3675,
1155,
353,
8840,
836,
8,
341,
3223,
11,
1848,
1669,
94173,
7121,
6570,
10556,
917,
4913,
67696,
13,
8301,
659,
3790,
17326,
24359,
9,
14345,
2092,
340,
743,
1848,
961,
2092,
341,
197,
3244,
30762,
445,
53... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestFlowAggregator_sendFlowKeyRecord(t *testing.T) {
ctrl := gomock.NewController(t)
defer ctrl.Finish()
mockIPFIXExpProc := ipfixtest.NewMockIPFIXExportingProcess(ctrl)
mockIPFIXRegistry := ipfixtest.NewMockIPFIXRegistry(ctrl)
mockDataSet := ipfixentitiestesting.NewMockSet(ctrl)
mockRecord := ipfixentities... | explode_data.jsonl/24304 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1358
} | [
2830,
3393,
18878,
9042,
58131,
13565,
18878,
1592,
6471,
1155,
353,
8840,
836,
8,
341,
84381,
1669,
342,
316,
1176,
7121,
2051,
1155,
340,
16867,
23743,
991,
18176,
2822,
77333,
3298,
39690,
8033,
24508,
1669,
5997,
5743,
1944,
7121,
115... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestLookupLonger(t *testing.T) {
tbl := NewTable(bgp.RF_IPv4_UC)
tbl.setDestination(NewDestination(bgp.NewIPAddrPrefix(23, "11.0.0.0"), 0))
tbl.setDestination(NewDestination(bgp.NewIPAddrPrefix(24, "11.0.0.0"), 0))
tbl.setDestination(NewDestination(bgp.NewIPAddrPrefix(32, "11.0.0.4"), 0))
tbl.setDestination(... | explode_data.jsonl/6673 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 371
} | [
2830,
3393,
34247,
6583,
261,
1155,
353,
8840,
836,
8,
341,
3244,
2024,
1669,
1532,
2556,
1883,
21888,
2013,
37,
16607,
85,
19,
80314,
692,
3244,
2024,
980,
33605,
35063,
33605,
1883,
21888,
7121,
3298,
13986,
14335,
7,
17,
18,
11,
33... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestEmptyProperties(t *testing.T) {
pomStr := `<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0... | explode_data.jsonl/41670 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 418
} | [
2830,
3393,
3522,
7903,
1155,
353,
8840,
836,
8,
341,
3223,
316,
2580,
1669,
1565,
1316,
6455,
2319,
428,
16,
13,
15,
1,
11170,
428,
8561,
12,
23,
85990,
27,
4987,
24967,
428,
1254,
1110,
76,
5276,
5096,
2659,
16341,
1898,
14,
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... | 3 |
func TestContainerNaming(t *testing.T) {
podUID := "12345678"
verifyPackUnpack(t, "file", podUID, "name", "container")
verifyPackUnpack(t, "file", podUID, "name-with-dashes", "container")
// UID is same as pod name
verifyPackUnpack(t, "file", podUID, podUID, "container")
// No Container name
verifyPackUnpack(t, ... | explode_data.jsonl/11443 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 360
} | [
2830,
3393,
4502,
85410,
1155,
353,
8840,
836,
8,
341,
3223,
347,
6463,
1669,
330,
16,
17,
18,
19,
20,
21,
22,
23,
698,
93587,
30684,
1806,
4748,
1155,
11,
330,
1192,
497,
7509,
6463,
11,
330,
606,
497,
330,
3586,
1138,
93587,
306... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestIsNeedQuoted(t *testing.T) {
if !token.IsNeedQuoted("true") {
t.Fatal("failed to quoted judge for boolean")
}
if !token.IsNeedQuoted("1.234") {
t.Fatal("failed to quoted judge for number")
}
if !token.IsNeedQuoted("1:1") {
t.Fatal("failed to quoted judge for time")
}
if !token.IsNeedQuoted("hoge #... | explode_data.jsonl/9940 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 217
} | [
2830,
3393,
3872,
23657,
2183,
9253,
1155,
353,
8840,
836,
8,
341,
743,
753,
5839,
4506,
23657,
2183,
9253,
445,
1866,
899,
341,
197,
3244,
26133,
445,
16091,
311,
23237,
11651,
369,
2710,
1138,
197,
532,
743,
753,
5839,
4506,
23657,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestPingRegistryEndpoint(t *testing.T) {
ep, err := NewEndpoint(makeURL("/v1/"), false)
if err != nil {
t.Fatal(err)
}
regInfo, err := ep.Ping()
if err != nil {
t.Fatal(err)
}
assertEqual(t, regInfo.Standalone, true, "Expected standalone to be true (default)")
} | explode_data.jsonl/78253 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 116
} | [
2830,
3393,
69883,
15603,
27380,
1155,
353,
8840,
836,
8,
341,
96626,
11,
1848,
1669,
1532,
27380,
36944,
3144,
4283,
85,
16,
14,
3975,
895,
340,
743,
1848,
961,
2092,
341,
197,
3244,
26133,
3964,
340,
197,
532,
37013,
1731,
11,
1848,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestBdevBackendUpdate(t *testing.T) {
numCtrlrs := 4
controllers := make(storage.NvmeControllers, 0, numCtrlrs)
for i := 0; i < numCtrlrs; i++ {
c := mockSpdkController(int32(i))
controllers = append(controllers, &c)
}
for name, tc := range map[string]struct {
pciAddr string
mec spdk.MockEnvCfg
... | explode_data.jsonl/28413 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 684
} | [
2830,
3393,
33,
3583,
29699,
4289,
1155,
353,
8840,
836,
8,
341,
22431,
15001,
5428,
1669,
220,
19,
198,
197,
21611,
1669,
1281,
52463,
2067,
85,
2660,
14353,
11,
220,
15,
11,
1629,
15001,
5428,
340,
2023,
600,
1669,
220,
15,
26,
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,
1,
1... | 1 |
func TestCancelSwapOrders(t *testing.T) {
t.Parallel()
if !areTestAPIKeysSet() || !canManipulateRealOrders {
t.Skip("skipping test, either api keys or manipulaterealorders isnt set correctly")
}
_, err := c.CancelSwapOrders([]string{"578639816552972288", "578639902896914432"})
if err != nil {
t.Error(err)
}
... | explode_data.jsonl/42951 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 128
} | [
2830,
3393,
9269,
46179,
24898,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
743,
753,
546,
2271,
7082,
8850,
1649,
368,
1369,
753,
4814,
92876,
6334,
12768,
24898,
341,
197,
3244,
57776,
445,
4886,
5654,
1273,
11,
2987,
6330,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestReportWorkflowResource_WorkflowCompleted_FinalStatePersisted_DeleteFailed(t *testing.T) {
store, manager, run := initWithOneTimeRun(t)
manager.argoClient = client.NewFakeArgoClientWithBadWorkflow()
defer store.Close()
// report workflow
workflow := util.NewWorkflow(&v1alpha1.Workflow{
ObjectMeta: v1.Obj... | explode_data.jsonl/77062 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 276
} | [
2830,
3393,
10361,
62768,
4783,
87471,
4965,
22724,
77072,
1397,
61267,
291,
57418,
9408,
1155,
353,
8840,
836,
8,
341,
57279,
11,
6645,
11,
1598,
1669,
13864,
3966,
1462,
6727,
1155,
340,
92272,
13,
12088,
2959,
284,
2943,
7121,
52317,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestDomains_GetRecordforDomainName(t *testing.T) {
setup()
defer teardown()
mux.HandleFunc("/v2/domains/example.com/records/1", func(w http.ResponseWriter, r *http.Request) {
testMethod(t, r, http.MethodGet)
fmt.Fprint(w, `{"domain_record":{"id":1}}`)
})
record, _, err := client.Domains.Record(ctx, "exa... | explode_data.jsonl/22676 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 225
} | [
2830,
3393,
74713,
13614,
6471,
1958,
13636,
675,
1155,
353,
8840,
836,
8,
341,
84571,
741,
16867,
49304,
2822,
2109,
2200,
63623,
4283,
85,
17,
71344,
1735,
65182,
905,
14,
26203,
14,
16,
497,
2915,
3622,
1758,
37508,
11,
435,
353,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestDeciding_ExecuteInbound(t *testing.T) {
ctrl := gomock.NewController(t)
defer ctrl.Finish()
t.Run("handles inbound message", func(t *testing.T) {
messenger := serviceMocks.NewMockMessenger(ctrl)
messenger.EXPECT().ReplyTo(gomock.Any(), gomock.Any()).Return(nil)
followup, action, err := (&deciding{})... | explode_data.jsonl/66252 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 753
} | [
2830,
3393,
4900,
6577,
83453,
641,
10891,
1155,
353,
8840,
836,
8,
341,
84381,
1669,
342,
316,
1176,
7121,
2051,
1155,
340,
16867,
23743,
991,
18176,
2822,
3244,
16708,
445,
43931,
64943,
1943,
497,
2915,
1155,
353,
8840,
836,
8,
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 |
func TestLocale(t *testing.T) {
trans := New()
expected := "nl_CW"
if trans.Locale() != expected {
t.Errorf("Expected '%s' Got '%s'", expected, trans.Locale())
}
} | explode_data.jsonl/45056 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 70
} | [
2830,
3393,
19231,
1155,
353,
8840,
836,
8,
1476,
72453,
1669,
1532,
741,
42400,
1669,
330,
15643,
920,
54,
1837,
743,
1356,
59094,
368,
961,
3601,
341,
197,
3244,
13080,
445,
18896,
7677,
82,
6,
24528,
7677,
82,
22772,
3601,
11,
1356... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestAccessReviewCheckOnMissingNamespace(t *testing.T) {
namespace := "test/test"
mockClient := newMockClientForTest(map[string]v1.NamespacePhase{}, map[string]v1.TenantPhase{})
mockClient.AddReactor("get", "namespaces", func(action core.Action) (bool, runtime.Object, error) {
return true, nil, fmt.Errorf("nop... | explode_data.jsonl/69155 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 324
} | [
2830,
3393,
6054,
19432,
3973,
1925,
25080,
22699,
1155,
353,
8840,
836,
8,
341,
56623,
1669,
330,
1944,
12697,
698,
77333,
2959,
1669,
501,
11571,
2959,
2461,
2271,
9147,
14032,
60,
85,
16,
46011,
30733,
22655,
2415,
14032,
60,
85,
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 |
func TestMultipleRegions(t *testing.T) {
t.Parallel()
g := gomega.NewGomegaWithT(t)
// Set the logger to development mode for verbose logs.
logf.SetLogger(zap.New(zap.UseDevMode(true)))
namespaced := types.NamespacedName{
Name: "read-test",
Namespace: "default",
}
application := &app.FybrikApplication{... | explode_data.jsonl/45022 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1375
} | [
2830,
3393,
32089,
79284,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
3174,
1669,
342,
32696,
7121,
38,
32696,
2354,
51,
1155,
340,
197,
322,
2573,
279,
5925,
311,
4401,
3856,
369,
13694,
18422,
624,
6725,
69,
4202,
7395,
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... | 1 |
func TestReflectNullValueArgument(t *testing.T) {
rt := New()
rt.Set("fn", func(v Value) {
if v == nil {
t.Error("null becomes nil")
}
if !IsNull(v) {
t.Error("null is not null")
}
})
rt.RunString(`fn(null);`)
} | explode_data.jsonl/10500 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 107
} | [
2830,
3393,
72789,
3280,
1130,
9171,
1155,
353,
8840,
836,
8,
341,
55060,
1669,
1532,
741,
55060,
4202,
445,
8822,
497,
2915,
3747,
5162,
8,
341,
197,
743,
348,
621,
2092,
341,
298,
3244,
6141,
445,
2921,
9044,
2092,
1138,
197,
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... | 3 |
func TestBuildIDs(t *testing.T) {
testfile := filepath.Join(*testDataDir, "libc.elf.section-only")
f, err := os.Open(testfile)
if err != nil {
t.Fatal("from os.Open: ", err)
}
buildIDs, err := GetBuildIDs(testfile, f)
if err != nil {
t.Fatal("from GetBuildIDs: ", err)
}
if len(buildIDs) != 1 {
t.Fatal("ex... | explode_data.jsonl/64421 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 219
} | [
2830,
3393,
11066,
30466,
1155,
353,
8840,
836,
8,
341,
18185,
1192,
1669,
26054,
22363,
4071,
1944,
1043,
6184,
11,
330,
55576,
13,
490,
29168,
15382,
1138,
1166,
11,
1848,
1669,
2643,
12953,
8623,
1192,
340,
743,
1848,
961,
2092,
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... | 5 |
func TestAddEndpointsToService(t *testing.T) {
r := newTestResolver(t)
defer r.Close()
ctx := viewertest.NewContext(context.Background(), r.client)
mr, qr := r.Mutation(), r.Query()
locType, err := mr.AddLocationType(ctx, models.AddLocationTypeInput{
Name: "loc_type_name",
})
require.NoError(t, err)
locatio... | explode_data.jsonl/7211 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1529
} | [
2830,
3393,
2212,
80786,
1249,
1860,
1155,
353,
8840,
836,
8,
341,
7000,
1669,
501,
2271,
18190,
1155,
340,
16867,
435,
10421,
741,
20985,
1669,
1651,
83386,
7121,
1972,
5378,
19047,
1507,
435,
6581,
692,
2109,
81,
11,
49290,
1669,
435,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestGC_TrackConfigurationBlobs(t *testing.T) {
require.NoError(t, testutil.TruncateAllTables(suite.db))
// create repo
r := randomRepository(t)
rs := datastore.NewRepositoryStore(suite.db)
r, err := rs.CreateByPath(suite.ctx, r.Path)
require.NoError(t, err)
// create config blob
bs := datastore.NewBlobSt... | explode_data.jsonl/48558 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 415
} | [
2830,
3393,
22863,
21038,
473,
7688,
33,
68164,
1155,
353,
8840,
836,
8,
341,
17957,
35699,
1155,
11,
1273,
1314,
8240,
26900,
2403,
21670,
89516,
7076,
4390,
197,
322,
1855,
15867,
198,
7000,
1669,
4194,
4624,
1155,
340,
41231,
1669,
6... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestNonBlockingOwnerRefDoesNotBlock(t *testing.T) {
stopCh := make(chan struct{})
s, closeFn, gc, clientSet := setup(t, stopCh)
defer func() {
// We have to close the stop channel first, so the shared informers can terminate their watches;
// otherwise closeFn() will hang waiting for active client connecti... | explode_data.jsonl/37646 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 885
} | [
2830,
3393,
8121,
48266,
13801,
3945,
21468,
2623,
4713,
1155,
353,
8840,
836,
8,
341,
62644,
1143,
1669,
1281,
35190,
2036,
37790,
1903,
11,
3265,
24911,
11,
22122,
11,
2943,
1649,
1669,
6505,
1155,
11,
2936,
1143,
692,
16867,
2915,
36... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestKitKnativeFullBuild(t *testing.T) {
doKitFullBuild(t, "knative", "300mi", "5m0s", TestTimeoutLong, kitOptions{
dependencies: []string{
"camel-k-knative",
},
})
} | explode_data.jsonl/61811 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 76
} | [
2830,
3393,
7695,
42,
29738,
9432,
11066,
1155,
353,
8840,
836,
8,
341,
19935,
7695,
9432,
11066,
1155,
11,
330,
19095,
1388,
497,
330,
18,
15,
15,
8155,
497,
330,
20,
76,
15,
82,
497,
3393,
7636,
6583,
11,
16138,
3798,
515,
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 |
func TestMaintainer(t *testing.T) {
t.Skip("asserting session state seems flakey")
t.Parallel()
if testing.Short() {
t.SkipNow()
}
var (
minOpened uint64 = 5
maxIdle uint64 = 4
)
sp, _, cleanup := setup(t, SessionPoolConfig{MinOpened: minOpened, MaxIdle: maxIdle})
defer cleanup()
sampleInterval := sp... | explode_data.jsonl/78708 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 676
} | [
2830,
3393,
66734,
1743,
1155,
353,
8840,
836,
8,
341,
3244,
57776,
445,
2207,
287,
3797,
1584,
4977,
1320,
726,
88,
1138,
3244,
41288,
7957,
741,
743,
7497,
55958,
368,
341,
197,
3244,
57776,
7039,
741,
197,
532,
2405,
2399,
197,
253... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestAccDatabricksDBFSFile_CreateViaContent(t *testing.T) {
config := qa.EnvironmentTemplate(t, `
resource "databricks_dbfs_file" "file" {
content = base64encode("{var.RANDOM}")
content_b64_md5 = md5(base64encode("{var.RANDOM}"))
path = "/tmp/tf-test/file-content-{var.RANDOM}"
overwrite = false
mkdirs =... | explode_data.jsonl/58532 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 415
} | [
2830,
3393,
14603,
35,
2096,
77789,
3506,
8485,
1703,
34325,
54428,
2762,
1155,
353,
8840,
836,
8,
341,
25873,
1669,
88496,
45651,
7275,
1155,
11,
22074,
50346,
330,
67,
2096,
77789,
8685,
3848,
2458,
1,
330,
1192,
1,
341,
197,
27751,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestServer_ListBlocks_Genesis(t *testing.T) {
db, _ := dbTest.SetupDB(t)
ctx := context.Background()
bs := &Server{
BeaconDB: db,
}
// Should throw an error if no genesis block is found.
_, err := bs.ListBlocks(ctx, ðpb.ListBlocksRequest{
QueryFilter: ðpb.ListBlocksRequest_Genesis{
Genesis: tr... | explode_data.jsonl/36473 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 468
} | [
2830,
3393,
5475,
27104,
29804,
2646,
268,
13774,
1155,
353,
8840,
836,
8,
341,
20939,
11,
716,
1669,
2927,
2271,
39820,
3506,
1155,
340,
20985,
1669,
2266,
19047,
2822,
93801,
1669,
609,
5475,
515,
197,
197,
3430,
22379,
3506,
25,
2927... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestReactorBroadcastTxMessage(t *testing.T) {
config := cfg.TestConfig()
const N = 4
reactors := makeAndConnectStorageReactors(config, N)
defer func() {
for _, r := range reactors {
r.Stop()
}
}()
for _, r := range reactors {
for _, peer := range r.Switch.Peers().List() {
peer.Set(types.PeerState... | explode_data.jsonl/22983 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 211
} | [
2830,
3393,
693,
5621,
43362,
31584,
2052,
1155,
353,
8840,
836,
8,
341,
25873,
1669,
13286,
8787,
2648,
741,
4777,
451,
284,
220,
19,
198,
197,
2934,
1087,
1669,
1281,
3036,
14611,
5793,
14799,
1087,
8754,
11,
451,
340,
16867,
2915,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestProgressEventHandlerOnAttemptingCoord(t *testing.T) {
ev := NewProgressEventHandler(true, 0)
board := challengeBoard
coord := &Coord{3, 3}
testProgressEventHandler(t, func() { ev.OnAttemptingCoord(board, coord) }, ev, coord, true)
} | explode_data.jsonl/54908 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 82
} | [
2830,
3393,
9496,
17945,
1925,
98584,
19437,
1155,
353,
8840,
836,
8,
341,
74837,
1669,
1532,
9496,
17945,
3715,
11,
220,
15,
340,
59868,
1669,
8645,
11932,
198,
197,
26402,
1669,
609,
19437,
90,
18,
11,
220,
18,
532,
18185,
9496,
179... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
func TestUpdateHost(t *testing.T) {
ts := httptest.NewServer(http.HandlerFunc(func(res http.ResponseWriter, req *http.Request) {
if req.URL.Path != "/api/v0/hosts/123456ABCD" {
t.Error("request URL should be /api/v0/hosts/123456ABCD but: ", req.URL.Path)
}
if req.Method != "PUT" {
t.Error("request method ... | explode_data.jsonl/63821 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 829
} | [
2830,
3393,
4289,
9296,
1155,
353,
8840,
836,
8,
341,
57441,
1669,
54320,
70334,
7121,
5475,
19886,
89164,
18552,
4590,
1758,
37508,
11,
4232,
353,
1254,
9659,
8,
341,
197,
743,
4232,
20893,
17474,
961,
3521,
2068,
5457,
15,
14,
44692,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestParse(t *testing.T) {
r := strings.NewReader(`
user/repo
user1/repo-x
user3/repo-y 1.0.1
user5/repo-z 1.0.13 `)
repos, err := Parse(r)
if err != nil {
t.Error(err)
}
t.Logf("%q\n", repos)
} | explode_data.jsonl/29348 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 119
} | [
2830,
3393,
14463,
1155,
353,
8840,
836,
8,
341,
7000,
1669,
9069,
68587,
61528,
19060,
10758,
5368,
198,
19060,
16,
10758,
5368,
6558,
198,
19060,
18,
10758,
5368,
12034,
220,
16,
13,
15,
13,
16,
17642,
19060,
20,
10758,
5368,
9141,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestAdDaysInMonths(t *testing.T) {
normalData := []int{31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}
leapData := []int{31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}
tests := []struct {
name string
isLeapYear bool
expected []int
}{
{"leap year", true, leapData},
{"not leap year", false, n... | explode_data.jsonl/62866 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 307
} | [
2830,
3393,
2589,
20557,
641,
59184,
1155,
353,
8840,
836,
8,
341,
197,
8252,
1043,
1669,
3056,
396,
90,
18,
16,
11,
220,
17,
23,
11,
220,
18,
16,
11,
220,
18,
15,
11,
220,
18,
16,
11,
220,
18,
15,
11,
220,
18,
16,
11,
220,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestTeamsService_ListIDPGroupsForTeamByID(t *testing.T) {
client, mux, _, teardown := setup()
defer teardown()
mux.HandleFunc("/organizations/1/team/1/team-sync/group-mappings", func(w http.ResponseWriter, r *http.Request) {
testMethod(t, r, "GET")
fmt.Fprint(w, `{"groups": [{"group_id": "1", "group_name"... | explode_data.jsonl/4554 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 542
} | [
2830,
3393,
60669,
1860,
27104,
915,
47,
22173,
2461,
14597,
60572,
1155,
353,
8840,
836,
8,
341,
25291,
11,
59807,
11,
8358,
49304,
1669,
6505,
741,
16867,
49304,
2822,
2109,
2200,
63623,
4283,
69253,
14,
16,
78015,
14,
16,
78015,
6503... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestSplit(t *testing.T) {
var splittests []SplitTest
splittests = unixsplittests
if runtime.GOOS == "windows" {
splittests = append(splittests, winsplittests...)
}
for _, test := range splittests {
if d, f := filepath.Split(test.path); d != test.dir || f != test.file {
t.Errorf("Split(%q) = %q, %q, wan... | explode_data.jsonl/1656 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 158
} | [
2830,
3393,
20193,
1155,
353,
8840,
836,
8,
341,
2405,
12503,
14267,
82,
3056,
20193,
2271,
198,
1903,
500,
14267,
82,
284,
51866,
69095,
14267,
82,
198,
743,
15592,
97574,
3126,
621,
330,
27077,
1,
341,
197,
1903,
500,
14267,
82,
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... | 5 |
func TestParseStubStatsValidInput(t *testing.T) {
var rt int64 = 271504
var tests = []struct {
input []byte
expectedResult StubStats
expectedError bool
}{
{
input: []byte(validStabStats),
expectedResult: StubStats{
Connections: StubConnections{
Active: 1457,
Accepted: 6717066,... | explode_data.jsonl/63027 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 424
} | [
2830,
3393,
14463,
33838,
16635,
4088,
2505,
1155,
353,
8840,
836,
8,
341,
2405,
16677,
526,
21,
19,
284,
220,
17,
22,
16,
20,
15,
19,
198,
2405,
7032,
284,
3056,
1235,
341,
197,
22427,
688,
3056,
3782,
198,
197,
42400,
2077,
66611,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestIsPassing(t *testing.T) {
yes := true
no := false
headSHA := "head"
success := string(githubql.StatusStateSuccess)
failure := string(githubql.StatusStateFailure)
testCases := []struct {
name string
passing bool
config config.TideContextPolicy
combinedContexts map[st... | explode_data.jsonl/42790 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1641
} | [
2830,
3393,
3872,
12187,
287,
1155,
353,
8840,
836,
8,
341,
197,
9693,
1669,
830,
198,
72104,
1669,
895,
198,
46081,
33145,
1669,
330,
1983,
698,
30553,
1669,
914,
3268,
3827,
1470,
10538,
1397,
7188,
340,
1166,
9373,
1669,
914,
3268,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func Test_Delete_Action(t *testing.T) {
var (
manager *Manager
vectorRepo *fakeVectorRepo
)
reset := func() {
vectorRepo = &fakeVectorRepo{}
vectorRepo.On("ActionByID", mock.Anything, mock.Anything, mock.Anything).Return(&search.Result{
ClassName: "MyAction",
}, nil).Once()
schemaManager := &fakeS... | explode_data.jsonl/74852 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 346
} | [
2830,
3393,
57418,
59899,
1155,
353,
8840,
836,
8,
341,
2405,
2399,
197,
92272,
262,
353,
2043,
198,
197,
20365,
25243,
353,
30570,
3781,
25243,
198,
197,
692,
70343,
1669,
2915,
368,
341,
197,
20365,
25243,
284,
609,
30570,
3781,
25243... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestGDPRPreventsCookie(t *testing.T) {
rr := doPost(`{"bidders":["appnexus", "pubmatic"]}`, nil, false, syncersForTest())
assert.Equal(t, rr.Header().Get("Content-Type"), "application/json; charset=utf-8")
assert.Equal(t, http.StatusOK, rr.Code)
assert.Empty(t, parseSyncs(t, rr.Body.Bytes()))
assert.Equal(t, ... | explode_data.jsonl/21683 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 149
} | [
2830,
3393,
40849,
6480,
4703,
47664,
20616,
1155,
353,
8840,
836,
8,
341,
197,
634,
1669,
65156,
5809,
4913,
65,
99129,
36799,
676,
77,
23666,
497,
330,
9585,
37244,
1341,
28350,
2092,
11,
895,
11,
12811,
388,
2461,
2271,
2398,
6948,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestInsertShardedGeo(t *testing.T) {
invschema := &vschemapb.SrvVSchema{
Keyspaces: map[string]*vschemapb.Keyspace{
"sharded": {
Sharded: true,
Vindexes: map[string]*vschemapb.Vindex{
"geo": {
Type: "region_experimental",
Params: map[string]string{
"region_bytes": "1",
}... | explode_data.jsonl/55991 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1413
} | [
2830,
3393,
13780,
2016,
20958,
37344,
1155,
353,
8840,
836,
8,
341,
17430,
11562,
3416,
1669,
609,
11562,
2407,
391,
65,
808,
10553,
53,
8632,
515,
197,
197,
8850,
27338,
25,
2415,
14032,
8465,
11562,
2407,
391,
65,
37863,
1306,
515,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestTrace(t *testing.T) {
cases := []struct {
name string
rcode int
question *dns.Msg
server string
}{
{
name: "NXDOMAIN",
rcode: dns.RcodeNameError,
question: new(dns.Msg).SetQuestion("example.org.", dns.TypeA),
},
{
name: "NOERROR",
rcode: dns.RcodeSuccess,
... | explode_data.jsonl/64691 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1051
} | [
2830,
3393,
6550,
1155,
353,
8840,
836,
8,
341,
1444,
2264,
1669,
3056,
1235,
341,
197,
11609,
257,
914,
198,
197,
30295,
534,
262,
526,
198,
197,
197,
7841,
353,
45226,
30365,
198,
197,
41057,
256,
914,
198,
197,
59403,
197,
197,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestCreateJob_ThroughPipelineID(t *testing.T) {
store, manager, pipeline := initWithPipeline(t)
defer store.Close()
apiExperiment := &api.Experiment{Name: "e1"}
experiment, err := manager.CreateExperiment(apiExperiment)
job := &api.Job{
Name: "j1",
Enabled: true,
PipelineSpec: &api.PipelineSpec{
P... | explode_data.jsonl/77035 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1091
} | [
2830,
3393,
4021,
12245,
62,
23857,
34656,
915,
1155,
353,
8840,
836,
8,
341,
57279,
11,
6645,
11,
15301,
1669,
13864,
34656,
1155,
340,
16867,
3553,
10421,
741,
54299,
77780,
1669,
609,
2068,
5121,
14329,
63121,
25,
330,
68,
16,
16707,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestAssessRunStatusWorstMessageInReconcileAnalysisRun(t *testing.T) {
newRun := StartAssessRunStatusWorstMessageInReconcileAnalysisRun(t, false)
assert.Equal(t, v1alpha1.AnalysisPhaseFailed, newRun.Status.Phase)
assert.Equal(t, "Metric \"run-forever\" assessed Failed due to failed (1) > failureLimit (0)", newRu... | explode_data.jsonl/75848 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 116
} | [
2830,
3393,
5615,
433,
6727,
2522,
54,
65296,
2052,
641,
693,
40446,
457,
26573,
6727,
1155,
353,
8840,
836,
8,
341,
8638,
6727,
1669,
5145,
5615,
433,
6727,
2522,
54,
65296,
2052,
641,
693,
40446,
457,
26573,
6727,
1155,
11,
895,
340... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestRenderer(t *testing.T) {
tmpl, err := Parse(strings.NewReader(`
my-lang:
hello ${name}
`))
if err != nil {
t.Fatal(err)
}
tmpl.RegisterRenderer("my-lang", func(out io.Writer, n *Node, v *vm.VM) error {
s := os.Expand(n.Text, func(s string) string {
if vv, ok := v.Get(s); ok {
return fmt.Sprin... | explode_data.jsonl/80442 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 296
} | [
2830,
3393,
11541,
1155,
353,
8840,
836,
8,
341,
3244,
54010,
11,
1848,
1669,
14775,
51442,
68587,
61528,
2408,
75460,
510,
220,
23811,
3570,
606,
532,
197,
63,
1171,
743,
1848,
961,
2092,
341,
197,
3244,
26133,
3964,
340,
197,
532,
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... | 2 |
func TestMustReadConfig(t *testing.T) {
cfg := MustReadConfig("../_resources/config/test.toml")
// Logger
if cfg.Logger.LogFile != logFile {
t.Errorf("Test failed, expected: '%s', got: '%s'", logFile, cfg.Logger.LogFile)
}
if cfg.Logger.LogLevel != logLevel {
t.Errorf("Test failed, expected: '%s', got: '%s'... | explode_data.jsonl/49581 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 429
} | [
2830,
3393,
31776,
4418,
2648,
1155,
353,
8840,
836,
8,
341,
50286,
1669,
15465,
4418,
2648,
17409,
62,
12745,
14730,
12697,
73494,
75,
5130,
197,
322,
9514,
198,
743,
13286,
12750,
5247,
1703,
961,
1487,
1703,
341,
197,
3244,
13080,
44... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.