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 TestGetMigSize(t *testing.T) {
server := NewHttpServerMock()
defer server.Close()
g := newTestGceManager(t, server.URL, false)
server.On("handle", "/project1/zones/us-central1-b/instanceGroupManagers/extra-pool-323233232").Return(instanceGroupManagerResponseTemplate).Once()
mig := &gceMig{
gceRef: GceRef{... | explode_data.jsonl/27609 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 257
} | [
2830,
3393,
1949,
44,
343,
1695,
1155,
353,
8840,
836,
8,
341,
41057,
1669,
1532,
2905,
5475,
11571,
741,
16867,
3538,
10421,
741,
3174,
1669,
501,
2271,
38,
346,
2043,
1155,
11,
3538,
20893,
11,
895,
692,
41057,
8071,
445,
8192,
497,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSpanLinkSlice_CopyTo(t *testing.T) {
dest := NewSpanLinkSlice()
// Test CopyTo to empty
NewSpanLinkSlice().CopyTo(dest)
assert.EqualValues(t, NewSpanLinkSlice(), dest)
// Test CopyTo larger slice
generateTestSpanLinkSlice().CopyTo(dest)
assert.EqualValues(t, generateTestSpanLinkSlice(), dest)
// Test... | explode_data.jsonl/63290 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 161
} | [
2830,
3393,
12485,
3939,
33236,
77637,
1249,
1155,
353,
8840,
836,
8,
341,
49616,
1669,
1532,
12485,
3939,
33236,
741,
197,
322,
3393,
14540,
1249,
311,
4287,
198,
197,
3564,
12485,
3939,
33236,
1005,
12106,
1249,
27010,
340,
6948,
12808,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestBuildMultiTag(t *testing.T) {
runWithDindSwarmAndRegistry(t, func(info dindSwarmAndRegistryInfo) {
cmd := info.configuredCmd
tmp := fs.NewDir(t, "TestBuild")
testDir := path.Join("testdata", "build")
iidfile := tmp.Join("iidfile")
tags := []string{"1.0.0", "latest"}
cmd.Command = dockerCli.Command... | explode_data.jsonl/72001 | {
"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,
11066,
20358,
5668,
1155,
353,
8840,
836,
8,
341,
56742,
2354,
35,
484,
13218,
2178,
3036,
15603,
1155,
11,
2915,
14208,
294,
484,
13218,
2178,
3036,
15603,
1731,
8,
341,
197,
25920,
1669,
3546,
5423,
3073,
15613,
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 TestMarshalURL(t *testing.T) {
urlp, err := url.Parse("http://example.com/")
if err != nil {
t.Fatal(err)
}
u := &URL{urlp}
c, err := json.Marshal(u)
if err != nil {
t.Fatal(err)
}
require.Equal(t, "\"http://example.com/\"", string(c), "URL not properly marshalled in JSON.")
c, err = yaml.Marshal(u)... | explode_data.jsonl/72911 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 197
} | [
2830,
3393,
55438,
3144,
1155,
353,
8840,
836,
8,
341,
19320,
79,
11,
1848,
1669,
2515,
8937,
445,
1254,
1110,
8687,
905,
53006,
743,
1848,
961,
2092,
341,
197,
3244,
26133,
3964,
340,
197,
532,
10676,
1669,
609,
3144,
90,
1085,
79,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCreateHTTPLoadBalancer(t *testing.T) {
// This should NOT create the forwarding rule and target proxy
// associated with the HTTPS branch of this loadbalancer.
lbInfo := &L7RuntimeInfo{Name: "test", AllowHTTP: true}
f := NewFakeLoadBalancers(lbInfo.Name)
pool := newFakeLoadBalancerPool(f, t)
pool.Add(lbI... | explode_data.jsonl/49950 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 325
} | [
2830,
3393,
4021,
2545,
77510,
2731,
93825,
1155,
353,
8840,
836,
8,
341,
197,
322,
1096,
1265,
4183,
1855,
279,
62104,
5912,
323,
2169,
13291,
198,
197,
322,
5815,
448,
279,
61044,
8870,
315,
419,
2795,
13313,
11705,
624,
8810,
65,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 9 |
func TestGetDomainState(t *testing.T) {
dom, conn := buildTestDomain()
defer func() {
dom.Free()
if res, _ := conn.Close(); res != 0 {
t.Errorf("Close() == %d, expected 0", res)
}
}()
state, reason, err := dom.GetState()
if err != nil {
t.Error(err)
return
}
if state != DOMAIN_SHUTOFF {
t.Error("D... | explode_data.jsonl/64818 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 199
} | [
2830,
3393,
1949,
13636,
1397,
1155,
353,
8840,
836,
8,
341,
2698,
316,
11,
4534,
1669,
1936,
2271,
13636,
741,
16867,
2915,
368,
341,
197,
2698,
316,
52229,
741,
197,
743,
592,
11,
716,
1669,
4534,
10421,
2129,
592,
961,
220,
15,
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 TestCmdNodeIsRevertible(t *testing.T) {
tcases := []struct {
line, result string
params map[string]interface{}
err error
revertible bool
}{
{line: "update vpc", result: "any", revertible: false},
{line: "delete vpc", result: "any", revertible: false},
{line: "create vpc", result: "... | explode_data.jsonl/39587 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 580
} | [
2830,
3393,
15613,
1955,
3872,
693,
1621,
1238,
1155,
353,
8840,
836,
8,
341,
3244,
23910,
1669,
3056,
1235,
341,
197,
27109,
11,
1102,
914,
198,
197,
25856,
981,
2415,
14032,
31344,
16094,
197,
9859,
688,
1465,
198,
197,
17200,
1621,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestVersion(t *testing.T) {
if Version() != "" {
t.Errorf("Unexpected version %q, want \"\"", Version())
}
var v = "1"
SetVersion(v)
if Version() != v {
t.Errorf("Unexpected version %q, want %q", Version(), v)
}
} | explode_data.jsonl/4157 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 92
} | [
2830,
3393,
5637,
1155,
353,
8840,
836,
8,
341,
743,
6079,
368,
961,
1591,
341,
197,
3244,
13080,
445,
29430,
2319,
1018,
80,
11,
1366,
7245,
55853,
6079,
2398,
197,
532,
2405,
348,
284,
330,
16,
698,
22212,
5637,
3747,
340,
743,
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... | 3 |
func TestRowsCloseOrder(t *testing.T) {
db := newTestDB(t, "people")
defer closeDB(t, db)
db.SetMaxIdleConns(0)
setStrictFakeConnClose(t)
defer setStrictFakeConnClose(nil)
rows, err := db.Query("SELECT|people|age,name|")
if err != nil {
t.Fatal(err)
}
err = rows.Close()
if err != nil {
t.Fatal(err)
}
} | explode_data.jsonl/16011 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 144
} | [
2830,
3393,
9024,
7925,
4431,
1155,
353,
8840,
836,
8,
341,
20939,
1669,
501,
2271,
3506,
1155,
11,
330,
16069,
1138,
16867,
3265,
3506,
1155,
11,
2927,
692,
20939,
4202,
5974,
41370,
1109,
4412,
7,
15,
340,
8196,
41857,
52317,
9701,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPasswordEntry_Reveal(t *testing.T) {
app := test.NewApp()
defer test.NewApp()
app.Settings().SetTheme(theme.LightTheme())
t.Run("NewPasswordEntry constructor", func(t *testing.T) {
entry := widget.NewPasswordEntry()
window := test.NewWindow(entry)
defer window.Close()
window.Resize(fyne.NewSize(15... | explode_data.jsonl/57339 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1055
} | [
2830,
3393,
4876,
5874,
50693,
40611,
1155,
353,
8840,
836,
8,
341,
28236,
1669,
1273,
7121,
2164,
741,
16867,
1273,
7121,
2164,
741,
28236,
27000,
1005,
1649,
12594,
57524,
50791,
12594,
12367,
3244,
16708,
445,
3564,
4876,
5874,
4692,
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 TestRuleMultiBytesWord(t *testing.T) {
common.Log.Debug("Entering function: %s", common.GetFunctionName())
sqls := [][]string{
{
"select col as 列 from tb",
"select col as `列` from tb",
},
{
"select col as c from tb",
"select '列'",
},
}
for _, sql := range sqls[0] {
q, err := NewQuery4Audi... | explode_data.jsonl/76776 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 394
} | [
2830,
3393,
11337,
20358,
7078,
10879,
1155,
353,
8840,
836,
8,
341,
83825,
5247,
20345,
445,
82867,
729,
25,
1018,
82,
497,
4185,
2234,
5152,
675,
2398,
30633,
82,
1669,
52931,
917,
515,
197,
197,
515,
298,
197,
1,
1742,
1375,
438,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 7 |
func TestNewRegistry(t *testing.T) {
r := NewRegistry(info.NewRuntimeInfo())
r.Register(NewFactory("mock", func() lock.LockStore {
return nil
}),
)
if _, err := r.Create("mock"); err != nil {
t.Fatalf("create mock store failed: %v", err)
}
if _, err := r.Create("not exists"); !strings.Contains(err.Error(), "... | explode_data.jsonl/9679 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 151
} | [
2830,
3393,
3564,
15603,
1155,
353,
8840,
836,
8,
341,
7000,
1669,
1532,
15603,
14208,
7121,
15123,
1731,
2398,
7000,
19983,
35063,
4153,
445,
16712,
497,
2915,
368,
5296,
31403,
6093,
341,
197,
853,
2092,
198,
197,
30793,
197,
340,
743... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 Test_destroyStatefulsets(t *testing.T) {
ctx := context.Background()
sfs := &appsv1.StatefulSet{
ObjectMeta: metav1.ObjectMeta{
Name: "test",
Namespace: "ns",
Labels: map[string]string{model.StackNameLabel: "stack-test"},
},
}
client := fake.NewSimpleClientset(sfs)
var tests = []struct ... | explode_data.jsonl/22837 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1006
} | [
2830,
3393,
18066,
1397,
1262,
4917,
1155,
353,
8840,
836,
8,
341,
20985,
1669,
2266,
19047,
2822,
1903,
3848,
1669,
609,
676,
3492,
16,
18942,
1262,
1649,
515,
197,
23816,
12175,
25,
77520,
16,
80222,
515,
298,
21297,
25,
414,
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,
1... | 4 |
func TestShortFlag(t *testing.T) {
var args struct {
Foo string `arg:"-f"`
}
err := parse("-f xyz", &args)
require.NoError(t, err)
assert.Equal(t, "xyz", args.Foo)
err = parse("-foo xyz", &args)
require.NoError(t, err)
assert.Equal(t, "xyz", args.Foo)
err = parse("--foo xyz", &args)
require.NoError(t, er... | explode_data.jsonl/12994 | {
"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,
12472,
12135,
1155,
353,
8840,
836,
8,
341,
2405,
2827,
2036,
341,
197,
12727,
2624,
914,
1565,
858,
86789,
69,
8805,
197,
630,
9859,
1669,
4715,
13645,
69,
40511,
497,
609,
2116,
340,
17957,
35699,
1155,
11,
1848,
340,
69... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPukRollNewUserEK(t *testing.T) {
tc, mctx, user := ephemeralKeyTestSetup(t)
defer tc.Cleanup()
// Confirm that the user has a userEK.
uid := tc.G.Env.GetUID()
uids := []keybase1.UID{uid}
statements, err := fetchUserEKStatements(mctx, uids)
require.NoError(t, err)
firstStatement, ok := statements[uid]
... | explode_data.jsonl/65198 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 581
} | [
2830,
3393,
47,
3101,
32355,
3564,
1474,
71133,
1155,
353,
8840,
836,
8,
341,
78255,
11,
296,
3773,
11,
1196,
1669,
82134,
3253,
1592,
2271,
21821,
1155,
340,
16867,
17130,
727,
60639,
2822,
197,
322,
33563,
429,
279,
1196,
702,
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... | 1 |
func TestGetDiscoveryMode(t *testing.T) {
log.Println("Test GetDiscoveryMode")
res, err := testDevice.GetDiscoveryMode()
if err != nil {
t.Error(err)
}
fmt.Println(res)
} | explode_data.jsonl/60355 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 72
} | [
2830,
3393,
1949,
67400,
3636,
1155,
353,
8840,
836,
8,
341,
6725,
12419,
445,
2271,
2126,
67400,
3636,
5130,
10202,
11,
1848,
1669,
1273,
6985,
2234,
67400,
3636,
741,
743,
1848,
961,
2092,
341,
197,
3244,
6141,
3964,
340,
197,
630,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAdd4D(t *testing.T) {
ctx := assert.Context(t)
for _, test := range []struct {
a f32.Vec4
b f32.Vec4
r f32.Vec4
}{
{f32.Vec4{0, 0, 0, 0}, f32.Vec4{0, 0, 0, 0}, f32.Vec4{0, 0, 0, 0}},
{f32.Vec4{1, 2, 3, 4}, f32.Vec4{0, 0, 0, 0}, f32.Vec4{1, 2, 3, 4}},
{f32.Vec4{0, 0, 0, 0}, f32.Vec4{4, 3, 2, 1}, ... | explode_data.jsonl/8032 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 336
} | [
2830,
3393,
2212,
19,
35,
1155,
353,
8840,
836,
8,
341,
20985,
1669,
2060,
9328,
1155,
340,
2023,
8358,
1273,
1669,
2088,
3056,
1235,
341,
197,
11323,
282,
18,
17,
5058,
757,
19,
198,
197,
2233,
282,
18,
17,
5058,
757,
19,
198,
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... | 2 |
func TestVppSetL2XConnect(t *testing.T) {
ctx, xcHandler, ifaceIdx := xcTestSetup(t)
defer ctx.TeardownTestCtx()
ifaceIdx.Put("rxIf1", &ifaceidx.IfaceMetadata{SwIfIndex: 100})
ifaceIdx.Put("rxIf2", &ifaceidx.IfaceMetadata{SwIfIndex: 101})
ifaceIdx.Put("txIf1", &ifaceidx.IfaceMetadata{SwIfIndex: 200})
ifaceIdx.Pu... | explode_data.jsonl/71080 | {
"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,
53,
602,
1649,
43,
17,
55,
14611,
1155,
353,
8840,
836,
8,
341,
20985,
11,
56901,
3050,
11,
49313,
11420,
1669,
56901,
2271,
21821,
1155,
340,
16867,
5635,
94849,
37496,
2271,
23684,
2822,
743,
578,
11420,
39825,
445,
12651,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPrincipalRoleMember(t *testing.T) {
msp1, err := setup("testdata/idemix/MSP1OU1", "MSP1OU1")
assert.NoError(t, err)
id1, err := getDefaultSigner(msp1)
assert.NoError(t, err)
principalBytes, err := proto.Marshal(&msp.MSPRole{Role: msp.MSPRole_MEMBER, MspIdentifier: id1.GetMSPIdentifier()})
assert.NoErro... | explode_data.jsonl/46046 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 379
} | [
2830,
3393,
31771,
9030,
9366,
1155,
353,
8840,
836,
8,
341,
47691,
79,
16,
11,
1848,
1669,
6505,
445,
92425,
38146,
336,
941,
10270,
4592,
16,
11922,
16,
497,
330,
44,
4592,
16,
11922,
16,
1138,
6948,
35699,
1155,
11,
1848,
692,
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 |
func TestInitWithEC2metadata(t *testing.T) {
ctrl, mockMetadata, _ := setup(t)
defer ctrl.Finish()
mockMetadata.EXPECT().GetMetadata(metadataAZ).Return(az, nil)
mockMetadata.EXPECT().GetMetadata(metadataLocalIP).Return(localIP, nil)
mockMetadata.EXPECT().GetMetadata(metadataInstanceID).Return(instanceID, nil)
mo... | explode_data.jsonl/19277 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 603
} | [
2830,
3393,
3803,
2354,
7498,
17,
17637,
1155,
353,
8840,
836,
8,
341,
84381,
11,
7860,
14610,
11,
716,
1669,
6505,
1155,
340,
16867,
23743,
991,
18176,
2822,
77333,
14610,
22402,
7285,
1005,
1949,
14610,
54436,
23563,
568,
5598,
7,
137... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestForPanicTrace(t *testing.T) {
defer func() {
if e := recover(); e != nil {
PanicTrace(4)
//os.Exit(1)
}
}()
panic("just for test")
} | explode_data.jsonl/61606 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 74
} | [
2830,
3393,
2461,
47,
31270,
6550,
1155,
353,
8840,
836,
8,
341,
16867,
2915,
368,
341,
197,
743,
384,
1669,
11731,
2129,
384,
961,
2092,
341,
298,
10025,
31270,
6550,
7,
19,
340,
298,
197,
322,
436,
34358,
7,
16,
340,
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
] | 2 |
func TestUpdateTicker(t *testing.T) {
t.Parallel()
cp := currency.NewPairWithDelimiter("BTC", "USDT", "/")
_, err := c.UpdateTicker(cp, asset.Spot)
if err != nil {
t.Error(err)
}
_, err = c.UpdateTicker(cp, asset.PerpetualSwap)
if err != nil {
t.Error(err)
}
} | explode_data.jsonl/42934 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 122
} | [
2830,
3393,
4289,
87278,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
52018,
1669,
11413,
7121,
12443,
2354,
91098,
445,
59118,
497,
330,
2034,
10599,
497,
3521,
1138,
197,
6878,
1848,
1669,
272,
16689,
87278,
44075,
11,
9329,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAction_Validate_RequireMixinData(t *testing.T) {
c := NewTestConfig(t)
c.SetupPorterHome()
c.TestContext.AddTestFile("testdata/simple.porter.yaml", Name)
err := c.LoadManifest()
require.NoError(t, err)
// Sabotage!
c.Manifest.Install[0].Data = nil
err = c.Manifest.Install.Validate(c.Manifest)
asse... | explode_data.jsonl/10947 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 143
} | [
2830,
3393,
2512,
62,
17926,
62,
17959,
38456,
1043,
1155,
353,
8840,
836,
8,
341,
1444,
1669,
1532,
2271,
2648,
1155,
340,
1444,
39820,
7084,
261,
7623,
2822,
1444,
8787,
1972,
1904,
2271,
1703,
445,
92425,
67195,
14598,
261,
33406,
49... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAuthenticatorFlags_HasExtensions(t *testing.T) {
var goodByte byte = 0x80
var badByte byte = 0x01
tests := []struct {
name string
flag AuthenticatorFlags
want bool
}{
{
"Present",
AuthenticatorFlags(goodByte),
true,
},
{
"Missing",
AuthenticatorFlags(badByte),
false,
},
}
... | explode_data.jsonl/78527 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 232
} | [
2830,
3393,
5087,
61393,
9195,
2039,
300,
31282,
1155,
353,
8840,
836,
8,
341,
2405,
1661,
7153,
4922,
284,
220,
15,
87,
23,
15,
198,
2405,
3873,
7153,
4922,
284,
220,
15,
87,
15,
16,
198,
78216,
1669,
3056,
1235,
341,
197,
11609,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestDeviceClass(t *testing.T) {
tests := []struct {
features fidlethernet.Features
expectClass network.DeviceClass
}{
{
features: 0,
expectClass: network.DeviceClassEthernet,
},
{
features: fidlethernet.FeaturesWlan,
expectClass: network.DeviceClassWlan,
},
}
for _, test := ran... | explode_data.jsonl/41338 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 236
} | [
2830,
3393,
6985,
1957,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
1235,
341,
197,
1166,
22462,
262,
32104,
273,
696,
4711,
73257,
198,
197,
24952,
1957,
3922,
43995,
1957,
198,
197,
59403,
197,
197,
515,
298,
1166,
22462,
25,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func Test_DirectArrayT(t *testing.T) {
const (
ddl = `
CREATE TABLE clickhouse_test_direct_array (
int8 Array(Int8),
int16 Array(Int16),
int32 Array(Int32),
int64 Array(Int64),
uint8 Array(UInt8),
uint16 Array(UInt16),
uint32 Array(UInt32),
uint64 Array(UInt64... | explode_data.jsonl/22891 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1427
} | [
2830,
3393,
1557,
1226,
1857,
51,
1155,
353,
8840,
836,
8,
341,
4777,
2399,
197,
197,
78372,
284,
22074,
298,
6258,
15489,
14363,
4205,
7675,
4452,
32871,
3858,
2399,
571,
2084,
23,
257,
2910,
24123,
23,
1326,
571,
2084,
16,
21,
262,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 9 |
func TestNotificationDelivery(t *testing.T) {
// given
ds, mockServer := mockDeliveryService(defaultTemplateLoader())
mg := mailgun.NewMailgun("crt-test.com", "123")
mg.SetAPIBase(mockServer.URL())
t.Run("test notification delivery ok", func(t *testing.T) {
// given
userSignup := &toolchainv1alpha1.UserSignu... | explode_data.jsonl/33135 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 2303
} | [
2830,
3393,
11196,
38121,
1155,
353,
8840,
836,
8,
341,
197,
322,
2661,
198,
83336,
11,
7860,
5475,
1669,
7860,
38121,
1860,
18978,
7275,
9181,
12367,
2109,
70,
1669,
8072,
13259,
7121,
16702,
13259,
445,
66,
3342,
16839,
905,
497,
330,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestGetAllCaptureLeases(t *testing.T) {
s := &etcdTester{}
s.setUpTest(t)
defer s.tearDownTest(t)
ctx, cancel := context.WithCancel(context.Background())
defer cancel()
testCases := []*model.CaptureInfo{
{
ID: "a3f41a6a-3c31-44f4-aa27-344c1b8cd658",
AdvertiseAddr: "127.0.0.1:8301",
},
... | explode_data.jsonl/70535 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 680
} | [
2830,
3393,
1949,
2403,
27429,
2304,
2264,
1155,
353,
8840,
836,
8,
341,
1903,
1669,
609,
295,
4385,
58699,
16094,
1903,
77700,
2271,
1155,
340,
16867,
274,
31853,
59342,
2271,
1155,
692,
20985,
11,
9121,
1669,
2266,
26124,
9269,
5378,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestExtensionInvalid(t *testing.T) {
compression := Compression(-1)
output := compression.Extension()
if output != "" {
t.Fatalf("The extension of an invalid compression should be an empty string.")
}
} | explode_data.jsonl/79227 | {
"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,
12049,
7928,
1155,
353,
8840,
836,
8,
341,
32810,
4011,
1669,
66161,
4080,
16,
340,
21170,
1669,
25111,
59715,
741,
743,
2550,
961,
1591,
341,
197,
3244,
30762,
445,
785,
8894,
315,
458,
8318,
25111,
1265,
387,
458,
4287,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestState_UpdateRplNamereply(t *testing.T) {
t.Parallel()
st := setupNewState()
ev := &irc.Event{
Name: irc.RPL_NAMREPLY,
Sender: network,
Args: []string{
st.selfUser.Nick(), "=", channels[0],
"@" + nicks[0] + " +" + nicks[1] + " " + st.selfUser.Nick(),
},
}
st.addChannel(channels[0])
if ... | explode_data.jsonl/32110 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 475
} | [
2830,
3393,
1397,
47393,
49,
500,
71367,
485,
2541,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
18388,
1669,
6505,
3564,
1397,
2822,
74837,
1669,
609,
2437,
6904,
515,
197,
21297,
25,
256,
79923,
2013,
2916,
1604,
1402,
787,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestBaseIdentity_GetAttack(t *testing.T) {
i := getTestBaseIdentity()
a := i.GetAttack()
if a != 0 {
t.Errorf("When isHero is false, GetAttack should return 0. Expected 0, got: %d", a)
}
i.ChangeForm()
a = i.GetAttack()
if a != TestAttack {
t.Errorf("When isHero is true, GetAttack should return the h... | explode_data.jsonl/55787 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 144
} | [
2830,
3393,
3978,
18558,
13614,
28602,
1155,
353,
8840,
836,
8,
341,
8230,
1669,
633,
2271,
3978,
18558,
2822,
11323,
1669,
600,
2234,
28602,
741,
743,
264,
961,
220,
15,
341,
197,
3244,
13080,
445,
4498,
374,
30228,
374,
895,
11,
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... | 3 |
func TestMaxRetransmitsTimeout(t *testing.T) {
c := context.New(t, defaultMTU)
defer c.Cleanup()
const numRetries = 2
opt := tcpip.TCPMaxRetriesOption(numRetries)
if err := c.Stack().SetTransportProtocolOption(tcp.ProtocolNumber, &opt); err != nil {
t.Fatalf("SetTransportProtocolOption(%d, &%T(%d)): %s", tcp.Pr... | explode_data.jsonl/75977 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 760
} | [
2830,
3393,
5974,
12020,
33389,
44703,
7636,
1155,
353,
8840,
836,
8,
341,
1444,
1669,
2266,
7121,
1155,
11,
1638,
8505,
52,
340,
16867,
272,
727,
60639,
2822,
4777,
1629,
12020,
4019,
284,
220,
17,
198,
64838,
1669,
28051,
573,
836,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
func TestFlexLayout(t *testing.T) {
fl := flexlayout.New()
section1 := fl.AddSection()
t1 := component.NewText("item 1")
t2 := component.NewText("item 2")
t3 := component.NewText("item 3")
require.NoError(t, section1.Add(t1, 12))
require.NoError(t, section1.Add(t2, 12))
require.NoError(t, section1.Add(t3, 12... | explode_data.jsonl/26078 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 379
} | [
2830,
3393,
31671,
2175,
1155,
353,
8840,
836,
8,
341,
1166,
75,
1669,
5763,
8399,
7121,
2822,
197,
2809,
16,
1669,
1320,
1904,
9620,
2822,
3244,
16,
1669,
3692,
7121,
1178,
445,
1203,
220,
16,
1138,
3244,
17,
1669,
3692,
7121,
1178,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestNetNative(t *testing.T) {
log := logging.NewDefaultLoggerFactory().NewLogger("test")
t.Run("Interfaces", func(t *testing.T) {
nw := NewNet(nil)
assert.False(t, nw.IsVirtual(), "should be false")
interfaces, err := nw.Interfaces()
assert.NoError(t, err, "should succeed")
log.Debugf("interfaces: %+v... | explode_data.jsonl/62495 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 2546
} | [
2830,
3393,
6954,
20800,
1155,
353,
8840,
836,
8,
341,
6725,
1669,
8392,
7121,
3675,
7395,
4153,
1005,
3564,
7395,
445,
1944,
5130,
3244,
16708,
445,
41066,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
9038,
86,
1669,
1532,
6954,
279... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAPISelector_SelectDefaultWhenBadResponse(t *testing.T) {
ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, req *http.Request) {
w.WriteHeader(http.StatusInternalServerError)
}))
defer ts.Close()
u, _ := url.Parse(ts.URL)
as := NewAPISelector(u)
as.SetMaxInterval(time.Millisecond)
a... | explode_data.jsonl/18680 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 206
} | [
2830,
3393,
7082,
5877,
58073,
3675,
4498,
17082,
2582,
1155,
353,
8840,
836,
8,
341,
57441,
1669,
54320,
70334,
7121,
5475,
19886,
89164,
18552,
3622,
1758,
37508,
11,
4232,
353,
1254,
9659,
8,
341,
197,
6692,
69794,
19886,
66760,
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 TestAND(t *testing.T) {
fmt.Println("===== AND =====")
var a1 = AND(AND(SQL("a=?", 10), SQL("b=?", 20)), AND(SQL("c=?", 30), SQL("d=?", 40)))
a1.Append("e=?", 50)
a1.Append(AND(SQL("f=?", 60)))
fmt.Println(a1.ToSQL())
var a2 = AND(OR(SQL("a=?", 10), SQL("b=?", 20)))
fmt.Println(a2.ToSQL())
} | explode_data.jsonl/1260 | {
"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,
3976,
1155,
353,
8840,
836,
8,
341,
11009,
12419,
445,
46725,
3567,
30742,
1138,
2405,
264,
16,
284,
3567,
7,
3976,
38669,
445,
64,
87873,
220,
16,
15,
701,
7870,
445,
65,
87873,
220,
17,
15,
5731,
3567,
38669,
445,
66,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestDyn_errorOrValue(t *testing.T) {
e := errors.New("an error")
val := "value"
assert.Equal(t, e, errorOrValue(e, val))
assert.Equal(t, val, errorOrValue(nil, val))
} | explode_data.jsonl/9814 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 74
} | [
2830,
3393,
95709,
4096,
2195,
1130,
1155,
353,
8840,
836,
8,
341,
7727,
1669,
5975,
7121,
445,
276,
1465,
1138,
19302,
1669,
330,
957,
698,
6948,
12808,
1155,
11,
384,
11,
1465,
2195,
1130,
2026,
11,
1044,
1171,
6948,
12808,
1155,
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 |
func TestFetchOrderHistory(t *testing.T) {
t.Parallel()
if !areTestAPIKeysSet() {
t.Skip()
}
_, err := f.FetchOrderHistory(context.Background(),
"", time.Time{}, time.Time{}, "2")
if err != nil {
t.Error(err)
}
_, err = f.FetchOrderHistory(context.Background(),
spotPair, time.Unix(authStartTime, 0), time... | explode_data.jsonl/15185 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 256
} | [
2830,
3393,
20714,
4431,
13424,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
743,
753,
546,
2271,
7082,
8850,
1649,
368,
341,
197,
3244,
57776,
741,
197,
532,
197,
6878,
1848,
1669,
282,
78506,
4431,
13424,
5378,
19047,
3148,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 5 |
func TestGenerateRequestBodyTypes(t *testing.T) {
spec := `---
components:
requestBodies:
FooRequest:
description: bar
content:
application/json:
schema:
type: object
properties:
baz:
type: string
`
doc, err := openapi.Load([]by... | explode_data.jsonl/65729 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 300
} | [
2830,
3393,
31115,
33334,
4173,
1155,
353,
8840,
836,
8,
341,
98100,
1669,
1565,
10952,
5149,
510,
220,
1681,
33,
10028,
510,
262,
33428,
1900,
510,
414,
4008,
25,
3619,
198,
414,
2213,
510,
286,
3766,
8931,
510,
688,
10802,
510,
310,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestFieldIterFromSegmentsDeduplicates(t *testing.T) {
segments := []segmentMetadata{
{segment: newTestSegmentWithDocs(t, []doc.Document{
{
ID: []byte("foo"),
Fields: []doc.Field{
{Name: []byte("fruit"), Value: []byte("apple")},
{Name: []byte("vegetable"), Value: []byte("carrot")},
},
... | explode_data.jsonl/36428 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 440
} | [
2830,
3393,
1877,
8537,
3830,
64813,
35,
291,
40614,
1155,
353,
8840,
836,
8,
341,
197,
56829,
1669,
3056,
23169,
14610,
515,
197,
197,
90,
23169,
25,
501,
2271,
21086,
2354,
63107,
1155,
11,
3056,
5236,
26256,
515,
298,
197,
515,
571... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestValidateSubpathMutuallyExclusive(t *testing.T) {
// Enable feature VolumeSubpathEnvExpansion and VolumeSubpath
defer featuregatetesting.SetFeatureGateDuringTest(t, utilfeature.DefaultFeatureGate, features.VolumeSubpathEnvExpansion, true)()
defer featuregatetesting.SetFeatureGateDuringTest(t, utilfeature.Def... | explode_data.jsonl/25643 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 972
} | [
2830,
3393,
17926,
3136,
2343,
51440,
1832,
70405,
1155,
353,
8840,
836,
8,
341,
197,
322,
18567,
4565,
20265,
3136,
2343,
14359,
71642,
323,
20265,
3136,
2343,
198,
16867,
4565,
70,
266,
57824,
287,
4202,
13859,
42318,
16014,
2271,
1155,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestEncoder_Result(t *testing.T) {
testCases := []struct {
Name string
E *encoder
Expected []*layerJSON
}{
{
Name: "nil encoder",
E: nil,
Expected: nil,
},
{
Name: "success",
E: &encoder{
res: []*layerJSON{
{
ID: "xxx",
PluginID: n... | explode_data.jsonl/56397 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 479
} | [
2830,
3393,
19921,
49596,
1155,
353,
8840,
836,
8,
341,
18185,
37302,
1669,
3056,
1235,
341,
197,
21297,
257,
914,
198,
197,
22784,
286,
353,
27008,
198,
197,
197,
18896,
29838,
10333,
5370,
198,
197,
59403,
197,
197,
515,
298,
21297,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestParsePositionalAndMultipleInterspersedKeyword(t *testing.T) {
args := []string{"--bar", "puerto rico", "--baz", "colombia", "--bar", "venezuela", "--baz", "honduras", "--baz", "guyana", "and", "still"}
f := NewFixture(t, model.NewUserConfigState(args))
defer f.TearDown()
f.File("Tiltfile", `
config.define... | explode_data.jsonl/65227 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 327
} | [
2830,
3393,
14463,
3812,
278,
3036,
32089,
1072,
388,
31290,
291,
34481,
1155,
353,
8840,
836,
8,
341,
31215,
1669,
3056,
917,
4913,
313,
2257,
497,
330,
5584,
13878,
93598,
497,
14482,
42573,
497,
330,
2074,
2855,
685,
497,
14482,
2257... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 Test_ScanDirFile(t *testing.T) {
teatPath := gdebug.TestDataPath()
gtest.C(t, func(t *gtest.T) {
files, err := gfile.ScanDirFile(teatPath, "*", false)
t.Assert(err, nil)
t.Assert(len(files), 0)
})
gtest.C(t, func(t *gtest.T) {
files, err := gfile.ScanDirFile(teatPath, "*", true)
t.Assert(err, nil)
... | explode_data.jsonl/25085 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 285
} | [
2830,
3393,
1098,
4814,
6184,
1703,
1155,
353,
8840,
836,
8,
341,
197,
665,
266,
1820,
1669,
342,
8349,
8787,
1043,
1820,
741,
3174,
1944,
727,
1155,
11,
2915,
1155,
353,
82038,
836,
8,
341,
197,
74075,
11,
1848,
1669,
342,
1192,
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... | 1 |
func TestHeapSortAscending(t *testing.T) {
var heap = []int{0, 10, 5, 20, 4, 3, 1, 15}
want := []int{0, 1, 3, 4, 5, 10, 15, 20}
heapSortAscending(&heap, len(heap)-1)
if !reflect.DeepEqual(want, heap) {
t.Errorf("after sorting using max heapify wanted %v got %v", want, heap)
}
} | explode_data.jsonl/22507 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 127
} | [
2830,
3393,
27909,
10231,
82952,
1155,
353,
8840,
836,
8,
341,
2405,
17364,
284,
3056,
396,
90,
15,
11,
220,
16,
15,
11,
220,
20,
11,
220,
17,
15,
11,
220,
19,
11,
220,
18,
11,
220,
16,
11,
220,
16,
20,
630,
50780,
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... | 2 |
func TestRoundTripSplitIntervalMiddleware(t *testing.T) {
testRequest := &ThanosRequest{
Path: "/api/v1/query_range",
Start: 0,
End: 2 * hour,
Step: 10 * seconds,
}
codec := NewThanosCodec(true)
for _, tc := range []struct {
name string
splitInterval time.Duration
req ... | explode_data.jsonl/49918 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1206
} | [
2830,
3393,
27497,
56352,
20193,
10256,
24684,
1155,
353,
8840,
836,
8,
341,
18185,
1900,
1669,
609,
26067,
436,
1900,
515,
197,
69640,
25,
220,
3521,
2068,
5457,
16,
66762,
9698,
756,
197,
65999,
25,
220,
15,
345,
197,
38407,
25,
256... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestNSERetryClient_RegisterCompletesOnParentContextTimeout(t *testing.T) {
t.Cleanup(func() { goleak.VerifyNone(t) })
var callCounter = &count.CallCounter{}
var counter = count.NewNetworkServiceEndpointRegistryClient(callCounter)
var client = chain.NewNetworkServiceEndpointRegistryClient(
retry.NewNetworkS... | explode_data.jsonl/68616 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 250
} | [
2830,
3393,
2448,
640,
15149,
2959,
73124,
66625,
2338,
1925,
8387,
1972,
7636,
1155,
353,
8840,
836,
8,
341,
3244,
727,
60639,
18552,
368,
314,
728,
273,
585,
54853,
4064,
1155,
8,
9568,
2405,
1618,
14099,
284,
609,
1830,
27017,
14099,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSetProcTitle(t *testing.T) {
if HaveSetProcTitle == HaveNone {
t.SkipNow()
}
title := randomMD5()
SetProcTitle(title)
out, err := exec.Command("/bin/ps", "ax").Output()
if err != nil {
// No ps available on this platform.
t.SkipNow()
} else if !strings.Contains(string(out), title) {
t.FailNow... | explode_data.jsonl/48490 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 131
} | [
2830,
3393,
1649,
24508,
3851,
1155,
353,
8840,
836,
8,
341,
743,
12243,
1649,
24508,
3851,
621,
12243,
4064,
341,
197,
3244,
57776,
7039,
741,
197,
630,
24751,
1669,
4194,
6076,
20,
2822,
22212,
24508,
3851,
12504,
692,
13967,
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... | 4 |
func TestSvc_SeasonChallengeList(t *testing.T) {
svc, cleanup := TestingService(t, ServiceOpts{Logger: testutil.Logger(t)})
defer cleanup()
ctx := testingSetContextToken(context.Background(), t)
// fetch user session to ensure account is created
_, err := svc.UserGetSession(ctx, nil)
require.NoError(t, err)
se... | explode_data.jsonl/55345 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 536
} | [
2830,
3393,
92766,
26920,
1497,
62078,
852,
1155,
353,
8840,
836,
8,
341,
1903,
7362,
11,
21290,
1669,
26768,
1860,
1155,
11,
5362,
43451,
90,
7395,
25,
1273,
1314,
12750,
1155,
59209,
16867,
21290,
741,
20985,
1669,
7497,
1649,
1972,
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 |
func TestPointBls12377G2Random(t *testing.T) {
bls12377G2 := BLS12377G2()
sc := bls12377G2.Point.Random(testRng())
s, ok := sc.(*PointBls12377G2)
require.True(t, ok)
expectedX, _ := new(big.Int).SetString("2deeb99988cc46605a5e8eeb50b2c52fc4a12b4537aa8a149431ca85bac2017a32d2a3bf8411d5145bdf587f162a1b01a106e89ebf321... | explode_data.jsonl/15762 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 464
} | [
2830,
3393,
2609,
33,
4730,
16,
17,
18,
22,
22,
38,
17,
13999,
1155,
353,
8840,
836,
8,
341,
96421,
82,
16,
17,
18,
22,
22,
38,
17,
1669,
425,
7268,
16,
17,
18,
22,
22,
38,
17,
741,
29928,
1669,
1501,
82,
16,
17,
18,
22,
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... | 2 |
func TestGetRuntime(t *testing.T) {
var result string
result = GetRuntime("laughing_feistel", "display", "markdown")
assert.Contains(t, result, "display")
assert.Contains(t, result, "`")
result = GetRuntime("laughing_feistel", "hello_world", "html")
assert.Contains(t, result, "hello_world")
assert.Contains(t, ... | explode_data.jsonl/54594 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 153
} | [
2830,
3393,
1949,
15123,
1155,
353,
8840,
836,
8,
341,
2405,
1102,
914,
271,
9559,
284,
2126,
15123,
445,
4260,
7443,
287,
7642,
380,
301,
497,
330,
5493,
497,
330,
60073,
1138,
6948,
11545,
1155,
11,
1102,
11,
330,
5493,
1138,
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 TestValidateAndBuildCellKeyCellidValidationFailure(t *testing.T) {
_, err := ValidateAndBuildCellIdKey("")
assert.NotNil(t, err)
assert.IsType(t, &ValidationError{}, err)
assert.Equal(t, "#utils.ValidateAndBuildCellIdKey - an empty cell id received", err.Error())
} | explode_data.jsonl/33039 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 97
} | [
2830,
3393,
17926,
3036,
11066,
3599,
1592,
3599,
307,
13799,
17507,
1155,
353,
8840,
836,
8,
341,
197,
6878,
1848,
1669,
23282,
3036,
11066,
3599,
764,
1592,
31764,
6948,
93882,
1155,
11,
1848,
340,
6948,
4506,
929,
1155,
11,
609,
8055... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSimpleQueue_TotalByte(t *testing.T) {
q, mem := initEnv(0)
defer q.Close()
defer mem.Close()
txa := &types.Transaction{Payload: []byte("123"), Fee: 100000}
mem.cache.Push(txa)
txb := &types.Transaction{Payload: []byte("1234"), Fee: 100000}
mem.cache.Push(txb)
var sumByte int64
mem.cache.Walk(mem.cac... | explode_data.jsonl/16841 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 316
} | [
2830,
3393,
16374,
7554,
85933,
7153,
1155,
353,
8840,
836,
8,
341,
18534,
11,
1833,
1669,
2930,
14359,
7,
15,
340,
16867,
2804,
10421,
741,
16867,
1833,
10421,
741,
3244,
9591,
1669,
609,
9242,
29284,
90,
29683,
25,
3056,
3782,
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 |
func TestPromoteLearnerToPeer_fromLearner(t *testing.T) {
learnerRaftId := uint16(3)
raftService := newTestRaftService(t, 2, []uint64{1}, []uint64{2, uint64(learnerRaftId)})
_, err := raftService.raftProtocolManager.PromoteToPeer(learnerRaftId)
if err == nil {
t.Errorf("learner should not be allowed to promote ... | explode_data.jsonl/13619 | {
"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,
35186,
1272,
43,
682,
1194,
1249,
30888,
5673,
43,
682,
1194,
1155,
353,
8840,
836,
8,
341,
197,
93595,
55535,
723,
764,
1669,
2622,
16,
21,
7,
18,
340,
197,
2944,
1860,
1669,
501,
2271,
55535,
723,
1860,
1155,
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... | 4 |
func TestSanitizeVolumeID(t *testing.T) {
tests := map[string]struct {
provided string
want string
}{
"basic ip example": {
provided: "beegfs://127.0.0.1/path/to/volume",
want: "127.0.0.1_path_to_volume",
},
"basic FQDN example": {
provided: "beegfs://some.domain.com/path/to/volume",
wan... | explode_data.jsonl/77110 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 519
} | [
2830,
3393,
23729,
26310,
18902,
915,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
2415,
14032,
60,
1235,
341,
197,
197,
63425,
914,
198,
197,
50780,
257,
914,
198,
197,
59403,
197,
197,
1,
22342,
5997,
3110,
788,
341,
298,
197,
63425,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestExpirationBasic(t *testing.T) {
unexpectedVal := "bar"
expectedVal := "bar2"
testObj := testObject{
key: "foo",
val: unexpectedVal,
}
fakeClock := clock.NewFakeClock(time.Now())
objectCache := NewFakeObjectCache(func() (interface{}, error) {
return expectedVal, nil
}, 1*time.Second, fakeClock)
... | explode_data.jsonl/44028 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 300
} | [
2830,
3393,
66301,
15944,
1155,
353,
8840,
836,
8,
341,
20479,
7325,
2208,
1669,
330,
2257,
698,
42400,
2208,
1669,
330,
2257,
17,
1837,
18185,
5261,
1669,
1273,
1190,
515,
197,
23634,
25,
330,
7975,
756,
197,
19302,
25,
16500,
2208,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestEncodeMD5(t *testing.T) {
var tests = []struct {
in string
out string
}{
{"", "d41d8cd98f00b204e9800998ecf8427e"},
{"hello", "5d41402abc4b2a76b9719d911017c592"},
{"小肥猫告别了小瘦猫,去大城市闯荡了。“再见了,小瘦猫,我一只猫也能过得很好。”小肥猫抹下最后一颗泪珠,赌着气给小瘦猫写下了这封诀别信。小瘦猫还在熟睡着,连小肥猫用力关门的“咣当”声都没能把它吵醒。小肥猫一步三回头,却始终没有猫来追它回去。小肥猫叹口气,只能自己一个人去... | explode_data.jsonl/56074 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1241
} | [
2830,
3393,
32535,
6076,
20,
1155,
353,
8840,
836,
8,
341,
2405,
7032,
284,
3056,
1235,
341,
197,
17430,
220,
914,
198,
197,
13967,
914,
198,
197,
59403,
197,
197,
4913,
497,
330,
67,
19,
16,
67,
23,
4385,
24,
23,
69,
15,
15,
65... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestOptionFunction(t *testing.T) {
logger := defaultLogger()
db := dbm.NewMemDB()
bap := baseapp.NewBaseApp("starting name", logger, db, testChangeNameHelper("new name"))
require.Equal(t, bap.GetName(), "new name", "BaseApp should have had name changed via option function")
} | explode_data.jsonl/30028 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 92
} | [
2830,
3393,
5341,
5152,
1155,
353,
8840,
836,
8,
341,
17060,
1669,
1638,
7395,
741,
20939,
1669,
2927,
76,
7121,
18816,
3506,
741,
2233,
391,
1669,
2331,
676,
7121,
3978,
2164,
445,
39289,
829,
497,
5925,
11,
2927,
11,
1273,
4072,
675... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestWaitForContainerTransitionsForTerminalTask(t *testing.T) {
acsMessages := make(chan acsTransition)
dockerMessages := make(chan dockerContainerChange)
ctx, cancel := context.WithCancel(context.TODO())
defer cancel()
task := &managedTask{
acsMessages: acsMessages,
dockerMessages: dockerMessages,
Ta... | explode_data.jsonl/24576 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 377
} | [
2830,
3393,
14190,
2461,
4502,
3167,
5930,
2461,
47890,
6262,
1155,
353,
8840,
836,
8,
341,
197,
19252,
15820,
1669,
1281,
35190,
1613,
82,
21768,
340,
2698,
13659,
15820,
1669,
1281,
35190,
26588,
4502,
4072,
340,
20985,
11,
9121,
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 TestStripWhitespaces(t *testing.T) {
defer leaktest.AfterTest(t)()
testData := []struct {
in, out string
}{
{" ", ""},
{" \n", "\n"},
{"abc", "abc"},
{"abc ", "abc"},
{"abc \n", "abc\n"},
{"abc \nxyz", "abc\nxyz"},
}
for _, test := range testData {
t.Run(test.in, func(t *testing.T) {
res... | explode_data.jsonl/33193 | {
"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,
5901,
1639,
3611,
27338,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
36892,
2271,
1155,
8,
741,
18185,
1043,
1669,
3056,
1235,
341,
197,
17430,
11,
700,
914,
198,
197,
59403,
197,
197,
4913,
3670,
77496,
197,
197,
49... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestDirect_AddSync(t *testing.T) {
g := NewGomegaWithT(t)
xform, src, acc := setup(g)
xform.Start()
defer xform.Stop()
src.Handlers.Handle(event.AddFor(basicmeta.K8SCollection1, data.EntryN1I1V1))
src.Handlers.Handle(event.FullSyncFor(basicmeta.K8SCollection1))
fixtures.ExpectEventsEventually(t, acc,
... | explode_data.jsonl/37554 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 174
} | [
2830,
3393,
16027,
21346,
12154,
1155,
353,
8840,
836,
8,
341,
3174,
1669,
1532,
38,
32696,
2354,
51,
1155,
692,
10225,
627,
11,
2286,
11,
1029,
1669,
6505,
3268,
692,
10225,
627,
12101,
741,
16867,
856,
627,
30213,
2822,
41144,
35308,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestGetDepth(t *testing.T) {
ticker, err := anx.GetDepth("BTCUSD")
if err != nil {
t.Errorf("Test Failed - ANX GetDepth() error: %s", err)
}
if ticker.Result != "success" {
t.Error("Test Failed - ANX GetDepth() unsuccessful")
}
} | explode_data.jsonl/8475 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 94
} | [
2830,
3393,
1949,
19776,
1155,
353,
8840,
836,
8,
341,
3244,
5215,
11,
1848,
1669,
73784,
2234,
19776,
445,
59118,
26749,
1138,
743,
1848,
961,
2092,
341,
197,
3244,
13080,
445,
2271,
21379,
481,
2100,
55,
2126,
19776,
368,
1465,
25,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestFieldCustomize(t *testing.T) {
uu := map[string]struct {
fields render.Fields
cols []int
e render.Fields
}{
"empty": {
fields: render.Fields{},
cols: []int{0, 1, 2},
e: render.Fields{"", "", ""},
},
"no-cols": {
fields: render.Fields{"f1", "f2", "f3"},
cols: []int{}... | explode_data.jsonl/66591 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 430
} | [
2830,
3393,
1877,
10268,
551,
1155,
353,
8840,
836,
8,
341,
10676,
84,
1669,
2415,
14032,
60,
1235,
341,
197,
55276,
3141,
42809,
198,
197,
1444,
3069,
256,
3056,
396,
198,
197,
7727,
414,
3141,
42809,
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,
1... | 1 |
func TestSnowflakeHeap(t *testing.T) {
Convey("SnowflakeHeap", t, func() {
h := new(SnowflakeHeap)
heap.Init(h)
So(h.Len(), ShouldEqual, 0)
s1 := new(Snowflake)
s2 := new(Snowflake)
s3 := new(Snowflake)
s4 := new(Snowflake)
s1.clients = 4
s2.clients = 5
s3.clients = 3
s4.clients = 1
heap.Push(... | explode_data.jsonl/18802 | {
"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,
62285,
63456,
27909,
1155,
353,
8840,
836,
8,
341,
93070,
5617,
445,
62285,
63456,
27909,
497,
259,
11,
2915,
368,
341,
197,
9598,
1669,
501,
3759,
3328,
63456,
27909,
340,
197,
197,
15961,
26849,
3203,
340,
197,
76912,
3203... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAddPod(t *testing.T) {
labels := map[string]string{
"app": "test-pod",
}
podObj := createPod("test-pod", "test-namespace", "0", "1.2.3.4", labels, NonHostNetwork, corev1.PodRunning)
calls := []testutils.TestCmd{
{Cmd: []string{"ipset", "-N", "-exist", util.GetHashedName("ns-test-namespace"), "nethash"... | explode_data.jsonl/35405 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 686
} | [
2830,
3393,
2212,
23527,
1155,
353,
8840,
836,
8,
341,
95143,
1669,
2415,
14032,
30953,
515,
197,
197,
1,
676,
788,
330,
1944,
2268,
347,
756,
197,
532,
3223,
347,
5261,
1669,
1855,
23527,
445,
1944,
2268,
347,
497,
330,
1944,
12,
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 TestClient_Aggregator(t *testing.T) {
ctx := context.Background()
asUser := userClient(t)
withToken := withToken(t, asUser)
created, err := withToken.CreateAggregator(ctx, types.CreateAggregator{
Name: "test-aggregator",
Version: types.DefaultAggregatorVersion,
AddHealth... | explode_data.jsonl/30418 | {
"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,
2959,
1566,
70,
58131,
1155,
353,
8840,
836,
8,
341,
20985,
1669,
2266,
19047,
741,
60451,
1474,
1669,
1196,
2959,
1155,
340,
46948,
3323,
1669,
448,
3323,
1155,
11,
438,
1474,
692,
197,
7120,
11,
1848,
1669,
448,
3323,
72... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestIntegerDeclConforms(t *testing.T) {
checkConforms(t,
context{},
&IntegerDecl{subtype: fidlir.Uint8, lower: 0, upper: 255},
[]conformTest{
conformOk{uint64(0)},
conformOk{uint64(128)},
conformOk{uint64(255)},
conformFail{uint64(256), "out of range"},
conformFail{int64(256), "out of range"}... | explode_data.jsonl/21394 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 461
} | [
2830,
3393,
3486,
21629,
1109,
9807,
1155,
353,
8840,
836,
8,
341,
25157,
1109,
9807,
1155,
345,
197,
28413,
38837,
197,
197,
5,
3486,
21629,
90,
77241,
25,
32104,
75,
404,
71869,
23,
11,
4722,
25,
220,
15,
11,
8416,
25,
220,
17,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestEditEquipmentType(t *testing.T) {
r := newTestResolver(t)
defer r.drv.Close()
ctx := viewertest.NewContext(r.client)
mr, qr := r.Mutation(), r.Query()
eqType, err := mr.AddEquipmentType(ctx, models.AddEquipmentTypeInput{
Name: "example_type_name",
})
require.NoError(t, err)
require.Equal(t, "example... | explode_data.jsonl/437 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 543
} | [
2830,
3393,
4036,
58276,
929,
1155,
353,
8840,
836,
8,
341,
7000,
1669,
501,
2271,
18190,
1155,
340,
16867,
435,
950,
10553,
10421,
741,
20985,
1669,
1651,
83386,
7121,
1972,
2601,
6581,
340,
2109,
81,
11,
49290,
1669,
435,
1321,
22705,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSessionPool(t *testing.T) {
t.Run("TestLifo", func(t *testing.T) {
descChan := make(chan description.Topology)
p := NewPool(descChan)
p.timeout = 30 // Set to some arbitrarily high number greater than 1 minute.
first, err := p.GetSession()
testhelpers.RequireNil(t, err, "error getting session %s", ... | explode_data.jsonl/32856 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 637
} | [
2830,
3393,
5283,
10551,
1155,
353,
8840,
836,
8,
341,
3244,
16708,
445,
2271,
43,
31497,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
41653,
46019,
1669,
1281,
35190,
4008,
17557,
2449,
340,
197,
3223,
1669,
1532,
10551,
37673,
46019,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSharedDepsList(t *testing.T) {
for _, tcase := range []struct {
chart string
golden string
wantError bool
}{
{
chart: "no/such/chart",
wantError: true,
},
{
chart: "testdata/charts/vanilla-helm",
golden: "output/shared-deps-no-deps.txt",
},
{
chart: "testdata/ch... | explode_data.jsonl/61034 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 580
} | [
2830,
3393,
16997,
35,
7124,
852,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
259,
5638,
1669,
2088,
3056,
1235,
341,
197,
197,
15941,
257,
914,
198,
197,
3174,
813,
268,
262,
914,
198,
197,
50780,
1454,
1807,
198,
197,
59403,
197,
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... | 4 |
func TestNamespace(t *testing.T) {
t.Run("empty namespace", func(t *testing.T) {
rt := NewTestDaprRuntime(modes.StandaloneMode)
ns := rt.getNamespace()
assert.Empty(t, ns)
})
t.Run("non-empty namespace", func(t *testing.T) {
os.Setenv("NAMESPACE", "a")
defer os.Clearenv()
rt := NewTestDaprRuntime(mode... | explode_data.jsonl/76071 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 175
} | [
2830,
3393,
22699,
1155,
353,
8840,
836,
8,
341,
3244,
16708,
445,
3194,
4473,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
55060,
1669,
1532,
2271,
35,
59817,
15123,
1255,
2539,
7758,
84112,
3636,
340,
197,
84041,
1669,
16677,
670,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCombinedStatus(t *testing.T) {
defer gock.Off()
gock.New("https://api.github.com").
Get("/repos/octocat/hello-world/commits/6dcb09b5b57875f334f61aebed695e2e4193db5e/status").
Reply(200).
Type("application/json").
SetHeaders(mockHeaders).
SetHeaders(mockPageHeaders).
File("testdata/combined_statu... | explode_data.jsonl/29869 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 404
} | [
2830,
3393,
94268,
2522,
1155,
353,
8840,
836,
8,
341,
16867,
728,
377,
13,
4596,
2822,
3174,
1176,
7121,
445,
2428,
1110,
2068,
11021,
905,
38609,
197,
37654,
4283,
68354,
59182,
509,
266,
7530,
4791,
30084,
14,
3621,
1199,
14,
21,
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... | 5 |
func TestVerify(t *testing.T) {
msgCryptoService := NewMCS(
&mocks.ChannelPolicyManagerGetterWithManager{
Managers: map[string]policies.Manager{
"A": &mocks.ChannelPolicyManager{
Policy: &mocks.Policy{Deserializer: &mocks.IdentityDeserializer{Identity: []byte("Bob"), Msg: []byte("msg2"), Mock: mock.Mock{... | explode_data.jsonl/26112 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 764
} | [
2830,
3393,
32627,
1155,
353,
8840,
836,
8,
341,
21169,
58288,
1860,
1669,
1532,
44,
6412,
1006,
197,
197,
5,
16712,
82,
38716,
13825,
2043,
31485,
2354,
2043,
515,
298,
197,
1658,
11218,
25,
2415,
14032,
60,
79,
42038,
58298,
515,
57... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestRuntime_ExportToStructAnonymous(t *testing.T) {
type BaseTestStruct struct {
A int64
B int64
}
type TestStruct struct {
BaseTestStruct
C string
}
const SCRIPT = `
var m = {
A: 1,
B: 2,
C: "testC"
}
m;
`
vm := New()
v, err := vm.RunString(SCRIPT)
if err != nil {
t.Fatal(err)
}
t... | explode_data.jsonl/10474 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 293
} | [
2830,
3393,
15123,
62,
16894,
1249,
9422,
32684,
1155,
353,
8840,
836,
8,
341,
13158,
5351,
2271,
9422,
2036,
341,
197,
22985,
526,
21,
19,
198,
197,
12791,
526,
21,
19,
198,
197,
630,
13158,
3393,
9422,
2036,
341,
197,
66732,
2271,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestArrayLabelValue(t *testing.T) {
arr := pdata.NewAnyValueArray()
arr.AppendEmpty()
_, ok := arrayLabelValue(arr)
require.False(t, ok)
mapVal := pdata.NewAttributeValueMap()
fillAttributeMap(mapVal.MapVal())
arr = pdata.NewAnyValueArray()
mapVal.CopyTo(arr.AppendEmpty())
value, ok := arrayLabelValue(a... | explode_data.jsonl/80393 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 365
} | [
2830,
3393,
1857,
2476,
1130,
1155,
353,
8840,
836,
8,
341,
36511,
1669,
70311,
7121,
8610,
1130,
1857,
741,
36511,
8982,
3522,
741,
197,
6878,
5394,
1669,
1334,
2476,
1130,
10939,
340,
17957,
50757,
1155,
11,
5394,
692,
19567,
2208,
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 |
func TestFSGapsInSequenceWithExpirationLimits(t *testing.T) {
opts := testFSGetOptionsForGapsTests()
for _, o := range opts {
t.Run(o.name, func(t *testing.T) {
cleanupFSDatastore(t)
defer cleanupFSDatastore(t)
s := createDefaultFileStore(t, o.opt)
defer s.Close()
limits := testDefaultStoreLimits
... | explode_data.jsonl/7783 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 445
} | [
2830,
3393,
37,
7783,
2625,
641,
14076,
2354,
66301,
94588,
1155,
353,
8840,
836,
8,
341,
64734,
1669,
1273,
8485,
1949,
3798,
2461,
38,
2625,
18200,
741,
2023,
8358,
297,
1669,
2088,
12185,
341,
197,
3244,
16708,
10108,
2644,
11,
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... | 6 |
func TestEtcdUpdateService(t *testing.T) {
ctx := api.NewDefaultContext()
fakeClient := tools.NewFakeEtcdClient(t)
fakeClient.TestIndex = true
key, _ := makeServiceKey(ctx, "foo")
resp, _ := fakeClient.Set(key, runtime.EncodeOrDie(latest.Codec, &api.Service{TypeMeta: api.TypeMeta{ID: "foo"}}), 0)
registry := NewT... | explode_data.jsonl/8171 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 402
} | [
2830,
3393,
31860,
4385,
4289,
1860,
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,
1166,
726,
2959,
8787,
1552,
284,
830,
198,
23634,
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 |
func Test_BubbleOptimal(t *testing.T) {
array := []int{10,50,60,1,29,95,02,6,025,4521,020,4515,2,5,15,24,65,6,1,051,10,24,45,1,4,51,42}
list := BubbleOptimal(array)
t.Logf("%+v",list)
} | explode_data.jsonl/14878 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 105
} | [
2830,
3393,
1668,
14600,
21367,
2861,
1155,
353,
8840,
836,
8,
341,
11923,
1669,
3056,
396,
90,
16,
15,
11,
20,
15,
11,
21,
15,
11,
16,
11,
17,
24,
11,
24,
20,
11,
15,
17,
11,
21,
11,
15,
17,
20,
11,
19,
20,
17,
16,
11,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestIndex(t *testing.T) {
index := NewSimpleTableIndex()
err := index.Insert(1, 10)
assert.Nil(t, err)
err = index.Insert("one", 10)
assert.Nil(t, err)
row, err := index.Find("one")
assert.Nil(t, err)
assert.Equal(t, 10, int(row))
err = index.Delete("one")
assert.Nil(t, err)
_, err = index.Find("one")
... | explode_data.jsonl/14642 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 674
} | [
2830,
3393,
1552,
1155,
353,
8840,
836,
8,
341,
26327,
1669,
1532,
16374,
2556,
1552,
741,
9859,
1669,
1922,
23142,
7,
16,
11,
220,
16,
15,
340,
6948,
59678,
1155,
11,
1848,
340,
9859,
284,
1922,
23142,
445,
603,
497,
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... | 1 |
func TestFloat32_Clear(t *testing.T) {
testcases := []struct {
name string
s Float32
}{
{
name: "test Float32 Clear, s is empty",
s: Float32{},
},
{
name: "test Float32 Clear, s is not empty",
s: map[float32]struct{}{1: {}, 1.5: {}, 1.2: {}},
},
}
for _, tc := range testcases {
t.... | explode_data.jsonl/60106 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 220
} | [
2830,
3393,
5442,
18,
17,
57744,
1155,
353,
8840,
836,
8,
341,
18185,
23910,
1669,
3056,
1235,
341,
197,
11609,
914,
198,
197,
1903,
262,
13001,
18,
17,
198,
197,
59403,
197,
197,
515,
298,
11609,
25,
330,
1944,
13001,
18,
17,
12023... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestBFS(t *testing.T) {
g := map[int][]int{
1: {2, 3},
2: {4, 5},
3: {6, 7},
6: {2},
}
t1 := newTestTraversal(g)
stopped := BFS(t1, t1.Iter, 1)
if stopped {
t.Fatalf("Did not expect traversal to stop")
}
expected := []int{1, 2, 3, 4, 5, 6, 7}
if !reflect.DeepEqual(expected, t1.ordered) {
t.... | explode_data.jsonl/30658 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 192
} | [
2830,
3393,
33,
8485,
1155,
353,
8840,
836,
8,
341,
3174,
1669,
2415,
18640,
45725,
396,
515,
197,
197,
16,
25,
314,
17,
11,
220,
18,
1583,
197,
197,
17,
25,
314,
19,
11,
220,
20,
1583,
197,
197,
18,
25,
314,
21,
11,
220,
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... | 3 |
func TestGetAllComponentParams(t *testing.T) {
tests := []struct {
jsonnet string
expected map[string]Params
}{
// Test getting the parameters where there are zero components
{
`
{
global: {},
components: {
},
}`,
map[string]Params{},
},
// Test getting the parameters where there is a single ... | explode_data.jsonl/36749 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 509
} | [
2830,
3393,
1949,
2403,
2189,
4870,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
1235,
341,
197,
30847,
4711,
220,
914,
198,
197,
42400,
2415,
14032,
60,
4870,
198,
197,
59403,
197,
197,
322,
3393,
3709,
279,
5029,
1380,
1052,
525... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestErrUnexpectedResponse(t *testing.T) {
for _, tc := range socketTestCases(t) {
func() {
var (
logger = log.TestingLogger()
chainID = cmn.RandStr(12)
readyCh = make(chan struct{})
errCh = make(chan error, 1)
serviceEndpoint = NewSignerServiceEndpoint(
logger,
chainID,
... | explode_data.jsonl/77987 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 702
} | [
2830,
3393,
7747,
29430,
2582,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
17130,
1669,
2088,
7575,
2271,
37302,
1155,
8,
341,
197,
29244,
368,
341,
298,
2405,
2399,
571,
17060,
220,
284,
1487,
8787,
287,
7395,
741,
571,
197,
8819,
915,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 Test_Service_Error3(t *testing.T) {
bkoff := backoff.NewExponentialBackOff()
bkoff.MaxElapsedTime = time.Second * 15
err := backoff.Retry(func() error {
logger, _ := test.NewNullLogger()
logger.SetLevel(logrus.DebugLevel)
c := service.NewContainer(logger)
c.Register(ID, &Service{})
err := c.Init(&t... | explode_data.jsonl/34505 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 374
} | [
2830,
3393,
52548,
28651,
18,
1155,
353,
8840,
836,
8,
341,
2233,
74,
1847,
1669,
1182,
1847,
7121,
840,
59825,
3707,
4596,
741,
2233,
74,
1847,
14535,
98483,
284,
882,
32435,
353,
220,
16,
20,
271,
9859,
1669,
1182,
1847,
2013,
15149... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestKubectlCleanup(t *testing.T) {
tests := []struct {
description string
kubectl latestV1.KubectlDeploy
commands util.Command
shouldErr bool
}{
{
description: "cleanup success",
kubectl: latestV1.KubectlDeploy{
Manifests: []string{"deployment.yaml"},
},
commands: testutil.
... | explode_data.jsonl/52875 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1178
} | [
2830,
3393,
42,
53380,
67335,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
1235,
341,
197,
42407,
914,
198,
197,
16463,
53380,
257,
5535,
53,
16,
11352,
53380,
69464,
198,
197,
197,
24270,
262,
4094,
12714,
198,
197,
197,
5445,
77... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSetSmShop(t *testing.T) {
bsToken := getBusToken()
mSm := new(logics.SmLogic)
args := &cards.ArgsSetSmShop{
BsToken: bsToken,
SmIds: []int{1, 2, 3, 4, 5},
ShopIds: []int{1},
IsAllShop: false,
}
logs.Info(mSm.SetSmShop(context.Background(), args))
} | explode_data.jsonl/35924 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 132
} | [
2830,
3393,
1649,
10673,
19795,
1155,
353,
8840,
836,
8,
341,
93801,
3323,
1669,
633,
15073,
3323,
741,
2109,
10673,
1669,
501,
12531,
1211,
92445,
26751,
340,
31215,
1669,
609,
25024,
51015,
1649,
10673,
19795,
515,
197,
12791,
82,
3323,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCurrentUser(t *testing.T) {
var userEnv string
if runtime.GOOS == "windows" {
userEnv = os.Getenv("USERNAME")
} else {
userEnv = os.Getenv("USER")
}
username, err := CurrentUser()
if userEnv != "" && err != nil {
t.Fatalf("If $USER is not blank, error should not happen. Error: %v", err)
}
if user... | explode_data.jsonl/22083 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 166
} | [
2830,
3393,
78257,
1155,
353,
8840,
836,
8,
341,
2405,
1196,
14359,
914,
198,
743,
15592,
97574,
3126,
621,
330,
27077,
1,
341,
197,
19060,
14359,
284,
2643,
64883,
445,
63516,
1138,
197,
92,
770,
341,
197,
19060,
14359,
284,
2643,
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,
1,
1... | 5 |
func TestEvalIfNode(t *testing.T) {
var data = make(VarMap)
data.Set("lower", strings.ToLower)
data.Set("upper", strings.ToUpper)
data.Set("repeat", strings.Repeat)
data.Set("user", &User{
"José Santos", "email@example.com",
})
RunJetTest(t, data, nil, "ifNode_simples", `{{if true}}hello{{end}}`, `hello`)
R... | explode_data.jsonl/22894 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 352
} | [
2830,
3393,
54469,
2679,
1955,
1155,
353,
8840,
836,
8,
341,
2405,
821,
284,
1281,
7,
3962,
2227,
340,
8924,
4202,
445,
14772,
497,
9069,
29983,
340,
8924,
4202,
445,
13574,
497,
9069,
49396,
340,
8924,
4202,
445,
30624,
497,
9069,
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 |
func TestNewWorker(t *testing.T) {
// Setup a new blockchain with genesis block containing test token on test address
var (
database = ethdb.NewMemDatabase()
gspec = core.Genesis{
Config: chainConfig,
Factory: blockFactory,
Alloc: core.GenesisAlloc{testBankAddress: {Balance: testBankFunds}},
Sha... | explode_data.jsonl/44238 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 260
} | [
2830,
3393,
3564,
21936,
1155,
353,
8840,
836,
8,
341,
197,
322,
18626,
264,
501,
17944,
448,
59366,
2504,
8482,
1273,
3950,
389,
1273,
2621,
198,
2405,
2399,
197,
2698,
2211,
284,
8372,
1999,
7121,
18816,
5988,
741,
197,
3174,
9535,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestInputService5ProtocolTestNonFlattenedListsCase1(t *testing.T) {
sess := session.New()
svc := NewInputService5ProtocolTest(sess, &aws.Config{Endpoint: aws.String("https://test")})
input := &InputService5TestShapeInputService5TestCaseOperation1Input{
ListParam: []*string{
aws.String("one"),
aws.String... | explode_data.jsonl/46475 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 372
} | [
2830,
3393,
2505,
1860,
20,
20689,
2271,
8121,
3882,
1587,
6758,
37848,
4207,
16,
1155,
353,
8840,
836,
8,
341,
1903,
433,
1669,
3797,
7121,
741,
1903,
7362,
1669,
1532,
2505,
1860,
20,
20689,
2271,
57223,
11,
609,
8635,
10753,
90,
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... | 1 |
func TestMarshalJSONPBMarshaler(t *testing.T) {
rawJson := `{ "foo": "bar", "baz": [0, 1, 2, 3] }`
msg := dynamicMessage{RawJson: rawJson}
str, err := new(Marshaler).MarshalToString(&msg)
if err != nil {
t.Errorf("an unexpected error occurred when marshaling JSONPBMarshaler: %v", err)
}
if str != rawJson {
t.... | explode_data.jsonl/63116 | {
"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,
55438,
5370,
40637,
55438,
261,
1155,
353,
8840,
836,
8,
341,
76559,
5014,
1669,
53692,
330,
7975,
788,
330,
2257,
497,
330,
42573,
788,
508,
15,
11,
220,
16,
11,
220,
17,
11,
220,
18,
60,
335,
3989,
21169,
1669,
8741,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestKeys_CertCA(t *testing.T) {
keys, err := NewKeys()
require.NoError(t, err)
assert.NotNil(t, keys)
assert.NoError(t, keys.Generate())
assert.Nil(t, keys.certCARoot)
ca := &x509.Certificate{
SerialNumber: big.NewInt(2019),
Subject: pkix.Name{
Organization: []string{"TEST, INC."},
Country: ... | explode_data.jsonl/11408 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 426
} | [
2830,
3393,
8850,
920,
529,
5049,
1155,
353,
8840,
836,
8,
341,
80112,
11,
1848,
1669,
1532,
8850,
741,
17957,
35699,
1155,
11,
1848,
340,
6948,
93882,
1155,
11,
6894,
692,
6948,
35699,
1155,
11,
6894,
57582,
2398,
6948,
59678,
1155,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestClientDisallowMultipleConns(t *testing.T) {
defer leaktest.AfterTest(t)()
stopper := stop.NewStopper()
defer stopper.Stop(context.TODO())
local := startGossip(1, stopper, t, metric.NewRegistry())
remote := startGossip(2, stopper, t, metric.NewRegistry())
local.mu.Lock()
remote.mu.Lock()
rAddr := remote... | explode_data.jsonl/18549 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 413
} | [
2830,
3393,
2959,
87854,
32089,
1109,
4412,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
36892,
2271,
1155,
8,
741,
62644,
712,
1669,
2936,
7121,
10674,
712,
741,
16867,
2936,
712,
30213,
5378,
90988,
2398,
8854,
1669,
1191,
38,
41... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestOpenMoreThanOnceInSameProcess(t *testing.T) {
t.Parallel()
path := testRepoPath("", t)
assert.Nil(Init(path, &config.Config{Datastore: config.DefaultDatastoreConfig()}), t)
r1, err := Open(path)
assert.Nil(err, t, "first repo should open successfully")
r2, err := Open(path)
assert.Nil(err, t, "second r... | explode_data.jsonl/24177 | {
"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,
5002,
7661,
26067,
12522,
641,
19198,
7423,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
26781,
1669,
1273,
25243,
1820,
19814,
259,
340,
6948,
59678,
7,
3803,
5581,
11,
609,
1676,
10753,
90,
1043,
4314,
25,
2193,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestGenerateProfile(t *testing.T) {
var tests = []struct {
description string
skaffoldConfig *latestV1.SkaffoldConfig
expectedProfile *latestV1.Profile
responses []string
namespace string
shouldErr bool
}{
{
description: "successful profile generation docker",
skaffoldC... | explode_data.jsonl/48470 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1852
} | [
2830,
3393,
31115,
8526,
1155,
353,
8840,
836,
8,
341,
2405,
7032,
284,
3056,
1235,
341,
197,
42407,
257,
914,
198,
197,
1903,
74,
2649,
813,
2648,
220,
353,
19350,
53,
16,
808,
74,
2649,
813,
2648,
198,
197,
42400,
8526,
353,
19350... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSnapshotMethods(t *testing.T) {
defer leaktest.AfterTest(t)()
runWithAllEngines(func(engine Engine, t *testing.T) {
keys := []MVCCKey{mvccKey("a"), mvccKey("b")}
vals := [][]byte{[]byte("1"), []byte("2")}
for i := range keys {
if err := engine.Put(keys[i], vals[i]); err != nil {
t.Fatal(err)
... | explode_data.jsonl/38117 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1057
} | [
2830,
3393,
15009,
17856,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
36892,
2271,
1155,
8,
741,
56742,
2354,
2403,
4106,
1543,
18552,
48974,
8200,
11,
259,
353,
8840,
836,
8,
341,
197,
80112,
1669,
3056,
66626,
3706,
1592,
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... | 6 |
func TestInstallCommand(t *testing.T) {
validInstallCmd := IsInstallCmd([]string{"--install"})
assert.Equal(t, true, validInstallCmd)
validInstallCmd = IsInstallCmd([]string{"-install"})
assert.Equal(t, true, validInstallCmd)
} | explode_data.jsonl/5832 | {
"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,
24690,
4062,
1155,
353,
8840,
836,
8,
341,
56322,
24690,
15613,
1669,
2160,
24690,
15613,
10556,
917,
4913,
313,
12248,
23625,
6948,
12808,
1155,
11,
830,
11,
2697,
24690,
15613,
340,
56322,
24690,
15613,
284,
2160,
24690,
156... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestTuple(t *testing.T) {
require := require.New(t)
typ := Tuple(Int32, Text, Int64)
_, err := typ.Convert("foo")
require.Error(err)
require.True(ErrNotTuple.Is(err))
_, err = typ.Convert([]interface{}{1, 2})
require.Error(err)
require.True(ErrInvalidColumnNumber.Is(err))
convert(t, typ, []interface{}{... | explode_data.jsonl/54306 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 391
} | [
2830,
3393,
28681,
1155,
353,
8840,
836,
8,
341,
17957,
1669,
1373,
7121,
1155,
692,
25314,
1669,
24622,
24123,
18,
17,
11,
2918,
11,
1333,
21,
19,
340,
197,
6878,
1848,
1669,
3582,
36179,
445,
7975,
1138,
17957,
6141,
3964,
340,
1795... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSendAlertWithoutTitle(t *testing.T) {
sqsMock := &mockSqs{}
sqsClient = sqsMock
mockRoundTripper := &mockRoundTripper{}
httpClient = &http.Client{Transport: mockRoundTripper}
policyConfig = policiesclient.DefaultTransportConfig().
WithHost("host").
WithBasePath("path")
policyClient = policiesclient.... | explode_data.jsonl/39036 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 817
} | [
2830,
3393,
11505,
9676,
26040,
3851,
1155,
353,
8840,
836,
8,
341,
1903,
26358,
11571,
1669,
609,
16712,
50,
26358,
16094,
1903,
26358,
2959,
284,
18031,
82,
11571,
271,
77333,
27497,
21884,
6922,
1669,
609,
16712,
27497,
21884,
6922,
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 TestFloat64Increment(t *testing.T) {
if err := quick.Check(func(v float64) bool {
a := NewFloat64(v)
v++
return a.Increment() == v && a.Load() == v
}, nil); err != nil {
t.Fatal(err)
}
} | explode_data.jsonl/30769 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 89
} | [
2830,
3393,
5442,
21,
19,
38311,
1155,
353,
8840,
836,
8,
341,
743,
1848,
1669,
3974,
10600,
18552,
3747,
2224,
21,
19,
8,
1807,
341,
197,
11323,
1669,
1532,
5442,
21,
19,
3747,
340,
197,
5195,
22940,
197,
853,
264,
5337,
13477,
368... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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.