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 TestConnectClusterReachableAndUnreachableNodes(t *testing.T) {
nodeList := createMockNodes(allocatableMap, schedulableNodeMap)
ms := &MockClusterScrapper{
mockGetAllNodes: func() ([]*v1.Node, error) {
return nodeList, nil
},
mockGetKubernetesServiceID: func() (svcID string, err error) {
return testCl... | explode_data.jsonl/62019 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 297
} | [
2830,
3393,
14611,
28678,
48368,
480,
3036,
1806,
46550,
12288,
1155,
353,
8840,
836,
8,
341,
20831,
852,
1669,
1855,
11571,
12288,
7,
4742,
15086,
2227,
11,
5575,
360,
480,
1955,
2227,
340,
47691,
1669,
609,
11571,
28678,
3326,
5518,
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 TestLiveUpdateExecUserRunFailureDoesntFallBack(t *testing.T) {
f := newBDFixture(t, k8s.EnvDockerDesktop, container.RuntimeCrio)
defer f.TearDown()
f.k8s.ExecErrors = []error{nil, userFailureErrExec}
lu := assembleLiveUpdate(SanchoSyncSteps(f), SanchoRunSteps, false, []string{"i/match/nothing"}, f)
tCase :=... | explode_data.jsonl/35161 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 349
} | [
2830,
3393,
20324,
4289,
10216,
1474,
6727,
17507,
21468,
406,
49772,
3707,
1155,
353,
8840,
836,
8,
341,
1166,
1669,
501,
33,
5262,
12735,
1155,
11,
595,
23,
82,
81214,
35,
13659,
23597,
11,
5476,
16706,
34,
10383,
340,
16867,
282,
8... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestApp01maVendorHndlrRowUpdate(t *testing.T) {
var td *TestData_App01maVendor
t.Logf("TestVendor.RowUpdate()...\n")
td = &TestData_App01maVendor{}
td.Setup(t)
t.Logf("TestVendor.RowUpdate() - End of Test\n\n\n")
} | explode_data.jsonl/78280 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 120
} | [
2830,
3393,
2164,
15,
16,
1728,
44691,
39,
303,
19018,
3102,
4289,
1155,
353,
8840,
836,
8,
341,
262,
762,
17941,
688,
353,
83920,
36117,
15,
16,
1728,
44691,
271,
262,
259,
98954,
445,
2271,
44691,
14657,
4289,
368,
30801,
77,
1138,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSequenceNumberOverflow(t *testing.T) {
// Limit runtime in case of deadlocks
lim := test.TimeOut(5 * time.Second)
defer lim.Stop()
// Check for leaking routines
report := test.CheckRoutines(t)
defer report()
t.Run("ApplicationData", func(t *testing.T) {
ca, cb, err := pipeMemory()
if err != nil {
... | explode_data.jsonl/40929 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 777
} | [
2830,
3393,
14076,
2833,
42124,
1155,
353,
8840,
836,
8,
341,
197,
322,
28008,
15592,
304,
1142,
315,
5593,
34936,
198,
197,
4659,
1669,
1273,
16299,
2662,
7,
20,
353,
882,
32435,
340,
16867,
4568,
30213,
2822,
197,
322,
4248,
369,
51... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestValidateFQDN(t *testing.T) {
if ValidateFQDN(strings.Repeat("x", 256)) == nil {
t.Error("expected error on long FQDN")
}
if ValidateFQDN("") == nil {
t.Error("expected error on empty FQDN")
}
} | explode_data.jsonl/56891 | {
"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,
17926,
37,
48,
31264,
1155,
353,
8840,
836,
8,
341,
743,
23282,
37,
48,
31264,
51442,
2817,
10979,
445,
87,
497,
220,
17,
20,
21,
593,
621,
2092,
341,
197,
3244,
6141,
445,
7325,
1465,
389,
1293,
434,
48,
31264,
1138,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestResolver_ScheduleUserPermissionsSync(t *testing.T) {
t.Run("authenticated as non-admin", func(t *testing.T) {
db.Mocks.Users.GetByCurrentAuthUser = func(context.Context) (*types.User, error) {
return &types.User{}, nil
}
t.Cleanup(func() {
db.Mocks.Users = db.MockUsers{}
})
ctx := actor.WithA... | explode_data.jsonl/14715 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 530
} | [
2830,
3393,
18190,
1098,
8796,
1474,
23851,
12154,
1155,
353,
8840,
836,
8,
341,
3244,
16708,
445,
57707,
438,
2477,
27225,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
20939,
24664,
82,
36782,
2234,
1359,
5405,
5087,
1474,
284,
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... | 1 |
func Test_reader_Read(t *testing.T) {
type fields struct {
config Config
schema string
table string
columns []string
statement *sql.Stmt
db *sql.DB
}
type args struct {
record store.Record
}
tests := []struct {
name string
fields fields
args args
hasPanic bool
}{... | explode_data.jsonl/39200 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 630
} | [
2830,
3393,
22306,
38381,
1155,
353,
8840,
836,
8,
341,
13158,
5043,
2036,
341,
197,
25873,
262,
5532,
198,
197,
1903,
3416,
262,
914,
198,
197,
26481,
257,
914,
198,
197,
51661,
82,
256,
3056,
917,
198,
197,
89566,
353,
3544,
7758,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestMust(t *testing.T) {
t.Parallel()
tests := []struct {
name string
l *Logger
err error
expect error
}{
{"success(Must)", nil, nil, nil},
{"panic(Must)", nil, errForTest, errForTest},
}
for _, tt := range tests {
tt := tt
t.Run(tt.name, func(t *testing.T) {
t.Parallel()
exp... | explode_data.jsonl/71317 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 271
} | [
2830,
3393,
31776,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
78216,
1669,
3056,
1235,
341,
197,
11609,
256,
914,
198,
197,
8810,
414,
353,
7395,
198,
197,
9859,
262,
1465,
198,
197,
24952,
1465,
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... | 3 |
func TestCommand(t *testing.T) {
t.Log("Testing generate ansible adhoc command string")
adhoc := &AnsibleAdhocCmd{
Binary: "custom-binary",
Pattern: "pattenr",
Options: &AnsibleAdhocOptions{
Args: "args",
Background: 11,
ModuleName: "module-name",
OneLine: true,
PlaybookDir: "playb... | explode_data.jsonl/69686 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 419
} | [
2830,
3393,
4062,
1155,
353,
8840,
836,
8,
341,
3244,
5247,
445,
16451,
6923,
90719,
993,
88473,
3210,
914,
5130,
197,
51587,
509,
1669,
609,
69599,
1238,
2589,
88473,
15613,
515,
197,
12791,
3287,
25,
220,
330,
9163,
94839,
756,
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 TestCleanupErr(t *testing.T) {
agent := &upload.MockAgent{
Err: errors.New("bad error"),
}
dir, _ := ioutil.TempDir("", "clenaup-testing")
dl := &downloadedFiles{dir: dir}
defer dl.deleteFiles()
// write a test file to attempt deletion
path := filepath.Join(dl.dir, agent.InboundPath())
if err := os.Mkd... | explode_data.jsonl/39198 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 288
} | [
2830,
3393,
67335,
7747,
1155,
353,
8840,
836,
8,
341,
197,
8092,
1669,
609,
6120,
24664,
16810,
515,
197,
197,
7747,
25,
5975,
7121,
445,
13855,
1465,
4461,
197,
630,
48532,
11,
716,
1669,
43144,
65009,
6184,
19814,
330,
564,
7157,
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... | 5 |
func TestDataAccess(t *testing.T) {
Convey("Testing DB", t, func() {
InitTestDB(t)
Convey("Can add datasource", func() {
err := AddDataSource(&m.AddDataSourceCommand{
OrgId: 10,
Name: "laban",
Type: m.DS_INFLUXDB,
Access: m.DS_ACCESS_DIRECT,
Url: "http://test",
Database... | explode_data.jsonl/22919 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1860
} | [
2830,
93200,
6054,
1155,
353,
8840,
836,
8,
341,
93070,
5617,
445,
16451,
5952,
497,
259,
11,
2915,
368,
341,
197,
98762,
2271,
3506,
1155,
340,
197,
93070,
5617,
445,
6713,
912,
69156,
497,
2915,
368,
341,
298,
9859,
1669,
2691,
1717... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCodeSpan(t *testing.T) {
var tests = []string{
"`source code`\n",
"<p><code>source code</code></p>\n",
"` source code with spaces `\n",
"<p><code>source code with spaces</code></p>\n",
"` source code with spaces `not here\n",
"<p><code>source code with spaces</code>not here</p>\n",
"a `single... | explode_data.jsonl/57351 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 452
} | [
2830,
3393,
2078,
12485,
1155,
353,
8840,
836,
8,
341,
2405,
7032,
284,
3056,
917,
515,
197,
197,
39917,
2427,
2038,
61069,
77,
756,
197,
197,
22476,
79,
1784,
1851,
29,
2427,
2038,
522,
1851,
1472,
79,
8449,
77,
25897,
197,
197,
39... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestTLS11SignatureSchemes(t *testing.T) {
expected := tls11SignatureSchemesNumECDSA + tls11SignatureSchemesNumRSA
if expected != len(tls11SignatureSchemes) {
t.Errorf("expected to find %d TLS 1.1 signature schemes, but found %d", expected, len(tls11SignatureSchemes))
}
} | explode_data.jsonl/71378 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 100
} | [
2830,
3393,
45439,
16,
16,
25088,
50,
66346,
1155,
353,
8840,
836,
8,
341,
42400,
1669,
55026,
16,
16,
25088,
50,
66346,
4651,
7498,
72638,
488,
55026,
16,
16,
25088,
50,
66346,
4651,
73564,
198,
743,
3601,
961,
2422,
1155,
4730,
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 TestKeyTypes(t *testing.T) {
for k, v := range testPrivateKeys {
if err := addKeyToAgent(v); err != nil {
t.Errorf("error adding key type %s, %v", k, err)
}
if err := addCertToAgentSock(v, nil); err != nil {
t.Errorf("error adding key type %s, %v", k, err)
}
}
} | explode_data.jsonl/68410 | {
"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,
1592,
4173,
1155,
353,
8840,
836,
8,
341,
2023,
595,
11,
348,
1669,
2088,
1273,
16787,
8850,
341,
197,
743,
1848,
1669,
912,
1592,
1249,
16810,
3747,
1215,
1848,
961,
2092,
341,
298,
3244,
13080,
445,
841,
7842,
1376,
943,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestReposGetInventory(t *testing.T) {
var s repos
ctx := testContext()
const (
wantRepo = "a"
wantCommitID = "cccccccccccccccccccccccccccccccccccccccc"
wantRootOID = "oid-root"
)
repoupdater.MockRepoLookup = func(args protocol.RepoLookupArgs) (*protocol.RepoLookupResult, error) {
if args.Repo !=... | explode_data.jsonl/77408 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1271
} | [
2830,
3393,
693,
966,
1949,
22319,
1155,
353,
8840,
836,
8,
341,
2405,
274,
45774,
198,
20985,
1669,
1273,
1972,
2822,
4777,
2399,
197,
50780,
25243,
257,
284,
330,
64,
698,
197,
50780,
33441,
915,
284,
330,
55597,
55597,
55597,
55597,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestEncodeInvalidMessages(t *testing.T) {
for _, test := range testInvalidMessages {
for _, m := range test.decodeTo {
if !m.ProtoReflect().IsValid() {
continue
}
t.Run(fmt.Sprintf("%s (%T)", test.desc, m), func(t *testing.T) {
opts := proto.MarshalOptions{
AllowPartial: test.partial,
... | explode_data.jsonl/1537 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 278
} | [
2830,
3393,
32535,
7928,
15820,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
1273,
1669,
2088,
1273,
7928,
15820,
341,
197,
2023,
8358,
296,
1669,
2088,
1273,
15922,
1249,
341,
298,
743,
753,
76,
7763,
983,
72789,
1005,
55470,
368,
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... | 3 |
func TestCreateBroadcastForSanction(t *testing.T) {
cases := []struct {
name string
clientID shared.ClientID
tier shared.IIGOSanctionsTier
expectedComms map[shared.CommunicationFieldName]shared.CommunicationContent
}{
{
name: "Basic broadcast",
clientID: shared.Teams["Team1"... | explode_data.jsonl/74044 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 419
} | [
2830,
3393,
4021,
43362,
2461,
23729,
407,
1155,
353,
8840,
836,
8,
341,
1444,
2264,
1669,
3056,
1235,
341,
197,
11609,
688,
914,
198,
197,
25291,
915,
414,
6094,
11716,
915,
198,
197,
3244,
1268,
688,
6094,
2447,
1914,
3126,
276,
513... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestNamespaceTopicsNamespaceDoesNotExit(t *testing.T) {
c, err := NewClient(ClientOptions{
URL: serviceURL,
})
if err != nil {
t.Errorf("failed to create client error: %+v", err)
return
}
defer c.Close()
ci := c.(*client)
// fetch from namespace that does not exist
name := generateRandomName()
topi... | explode_data.jsonl/69314 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 169
} | [
2830,
3393,
22699,
45003,
22699,
21468,
2623,
15339,
1155,
353,
8840,
836,
8,
341,
1444,
11,
1848,
1669,
1532,
2959,
46851,
3798,
515,
197,
79055,
25,
2473,
3144,
345,
197,
3518,
743,
1848,
961,
2092,
341,
197,
3244,
13080,
445,
16091,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 Test1(t *testing.T) {
expected := "ok\nok\n"
linux, err := Command("echo ok && echo ok")
if err != nil {
t.Errorf("should err=nil, got err=%q\n", err)
}
out, err := linux.Output()
if err != nil {
t.Errorf("should err=nil, got err=%q\n", err)
}
if expected != string(out) {
t.Errorf("should output=\n... | explode_data.jsonl/16668 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 160
} | [
2830,
3393,
16,
1155,
353,
8840,
836,
8,
341,
42400,
1669,
330,
562,
1699,
562,
1699,
698,
197,
14210,
11,
1848,
1669,
7348,
445,
3047,
5394,
1009,
1687,
5394,
1138,
743,
1848,
961,
2092,
341,
197,
3244,
13080,
445,
5445,
1848,
63358,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestClusterGetPVCEncryptionInitContainerActivate(t *testing.T) {
c := New(&clusterd.Context{}, &cephclient.ClusterInfo{OwnerInfo: &k8sutil.OwnerInfo{}}, cephv1.ClusterSpec{}, "rook/rook:myversion")
osdProperties := osdProperties{
pvc: v1.PersistentVolumeClaimVolumeSource{
ClaimName: "pvc1",
},
resources... | explode_data.jsonl/73007 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 338
} | [
2830,
3393,
28678,
1949,
48469,
2104,
1016,
15597,
3803,
4502,
31242,
1155,
353,
8840,
836,
8,
341,
1444,
1669,
1532,
2099,
18855,
67,
9328,
22655,
609,
58722,
2972,
72883,
1731,
90,
13801,
1731,
25,
609,
74,
23,
82,
1314,
49920,
1731,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestNewLocaleStage(t *testing.T) {
expectedStage := &Stage{
Name: "org.osbuild.locale",
Options: &LocaleStageOptions{},
}
actualStage := NewLocaleStage(&LocaleStageOptions{})
assert.Equal(t, expectedStage, actualStage)
} | explode_data.jsonl/62875 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 87
} | [
2830,
3393,
3564,
19231,
19398,
1155,
353,
8840,
836,
8,
341,
42400,
19398,
1669,
609,
19398,
515,
197,
21297,
25,
262,
330,
1775,
9291,
5834,
45500,
756,
197,
197,
3798,
25,
609,
19231,
19398,
3798,
38837,
197,
532,
88814,
19398,
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 |
func TestUFetchOpenOrder(t *testing.T) {
t.Parallel()
if !areTestAPIKeysSet() {
t.Skip("skipping test: api keys not set")
}
_, err := b.UFetchOpenOrder(context.Background(), currency.NewPair(currency.BTC, currency.USDT), "123", "")
if err != nil {
t.Error(err)
}
} | explode_data.jsonl/76577 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 109
} | [
2830,
3393,
20538,
2995,
5002,
4431,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
743,
753,
546,
2271,
7082,
8850,
1649,
368,
341,
197,
3244,
57776,
445,
4886,
5654,
1273,
25,
6330,
6894,
537,
738,
1138,
197,
532,
197,
6878,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestBlockValidSemantic(t *testing.T) {
tf.UnitTest(t)
blockTime := clock.DefaultEpochDuration
ts := time.Unix(1234567890, 0)
genTime := ts
mclock := clock.NewChainClockFromClock(uint64(genTime.Unix()), blockTime, clock.NewFake(ts))
ctx := context.Background()
validator := consensus.NewDefaultBlockValidato... | explode_data.jsonl/31025 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 354
} | [
2830,
3393,
4713,
4088,
97931,
1155,
353,
8840,
836,
8,
341,
3244,
69,
25159,
2271,
1155,
692,
47996,
1462,
1669,
8866,
13275,
44338,
12945,
198,
57441,
1669,
882,
10616,
941,
7,
16,
17,
18,
19,
20,
21,
22,
23,
24,
15,
11,
220,
15... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestExecutorReadTransaction(t *testing.T) {
txe, tsv, db := newTestTxExecutor(t)
defer db.Close()
defer tsv.StopService()
db.AddQuery("select dtid, state, time_created from _vt.dt_state where dtid = 'aa'", &sqltypes.Result{})
got, err := txe.ReadTransaction("aa")
require.NoError(t, err)
want := &querypb.Tr... | explode_data.jsonl/25175 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1270
} | [
2830,
3393,
25255,
4418,
8070,
1155,
353,
8840,
836,
8,
341,
3244,
8371,
11,
259,
3492,
11,
2927,
1669,
501,
2271,
31584,
25255,
1155,
340,
16867,
2927,
10421,
741,
16867,
259,
3492,
30213,
1860,
2822,
20939,
1904,
2859,
445,
1742,
7594... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestGrpcRegisterUser(t *testing.T) {
log.Printf("Starting GET5 gRPC Client...")
conn, err := grpc.Dial("127.0.0.1:50055", grpc.WithInsecure())
if err != nil {
t.Errorf("client connection error:%v\n", err)
}
defer conn.Close()
client := pb.NewGet5Client(conn)
req := &pb.RegisterUserRequest{Steamid: "765611... | explode_data.jsonl/40908 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 200
} | [
2830,
3393,
6464,
3992,
8690,
1474,
1155,
353,
8840,
836,
8,
341,
6725,
19367,
445,
24617,
7890,
20,
342,
29528,
8423,
33093,
32917,
11,
1848,
1669,
47900,
98462,
445,
16,
17,
22,
13,
15,
13,
15,
13,
16,
25,
20,
15,
15,
20,
20,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestServerTimeout(t *testing.T) {
// Limit runtime in case of deadlocks
lim := test.TimeOut(time.Second * 20)
defer lim.Stop()
// Check for leaking routines
report := test.CheckRoutines(t)
defer report()
cookie := make([]byte, 20)
_, err := rand.Read(cookie)
if err != nil {
t.Fatal(err)
}
var rand ... | explode_data.jsonl/40941 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1257
} | [
2830,
3393,
5475,
7636,
1155,
353,
8840,
836,
8,
341,
197,
322,
28008,
15592,
304,
1142,
315,
5593,
34936,
198,
197,
4659,
1669,
1273,
16299,
2662,
9730,
32435,
353,
220,
17,
15,
340,
16867,
4568,
30213,
2822,
197,
322,
4248,
369,
518... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestTypeSystem_SchemaMustContainUniquelyNamedTypes_RejectsASchemaWhichDefinesAnObjectTypeTwice(t *testing.T) {
a := graphql.NewObject(graphql.ObjectConfig{
Name: "SameName",
Fields: graphql.Fields{
"f": &graphql.Field{
Type: graphql.String,
},
},
})
b := graphql.NewObject(graphql.ObjectConfig{
... | explode_data.jsonl/79141 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 382
} | [
2830,
3393,
929,
2320,
1098,
3416,
31776,
46522,
1806,
5011,
974,
15810,
4173,
50693,
583,
82,
1911,
3416,
23085,
73816,
2082,
49530,
22816,
558,
1155,
353,
8840,
836,
8,
1476,
11323,
1669,
48865,
7121,
1190,
24312,
1470,
8348,
2648,
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 TestBuffer_BatchLenUnderfill(t *testing.T) {
m := Metric()
b := setup(NewBuffer("test", 5))
b.Add(m)
batch := b.Batch(2)
require.Len(t, batch, 1)
} | explode_data.jsonl/17665 | {
"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,
4095,
1668,
754,
11271,
16250,
7559,
1155,
353,
8840,
836,
8,
341,
2109,
1669,
52458,
741,
2233,
1669,
6505,
35063,
4095,
445,
1944,
497,
220,
20,
1171,
2233,
1904,
1255,
340,
2233,
754,
1669,
293,
45791,
7,
17,
692,
17957... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestFailedLogin(t *testing.T) {
os.RemoveAll(profile.FullProfilePath(""))
t.Cleanup(func() {
os.RemoveAll(profile.FullProfilePath(""))
})
connector := mockConnector(t)
_, proxyProcess := makeTestServers(t, connector)
proxyAddr, err := proxyProcess.ProxyWebAddr()
require.NoError(t, err)
// build a moc... | explode_data.jsonl/21924 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 310
} | [
2830,
3393,
9408,
6231,
1155,
353,
8840,
836,
8,
341,
25078,
84427,
36606,
32038,
8526,
1820,
73303,
3244,
727,
60639,
18552,
368,
341,
197,
25078,
84427,
36606,
32038,
8526,
1820,
73303,
197,
8824,
32917,
1256,
1669,
7860,
35954,
1155,
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 TestDecimal_Bytes_max_byte_exceeded(t *testing.T) {
dec, err := decimal.NewFromString("999999999999999999999999999999999999999999999999999999999")
assert.NoError(t, err)
d := new(Decimal)
d.dec = dec
buf, err := d.Bytes()
assert.Error(t, err)
assert.Contains(t, err.Error(), "max byte length exceeded")
asse... | explode_data.jsonl/31237 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 129
} | [
2830,
3393,
11269,
62,
7078,
6345,
19737,
2702,
94206,
1155,
353,
8840,
836,
8,
341,
197,
8169,
11,
1848,
1669,
12122,
7121,
44491,
445,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
24,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestSendAlert(t *testing.T) {
sqsMock := &mockSqs{}
sqsClient = sqsMock
mockRoundTripper := &mockRoundTripper{}
httpClient = &http.Client{Transport: mockRoundTripper}
policyConfig = policiesclient.DefaultTransportConfig().
WithHost("host").
WithBasePath("path")
policyClient = policiesclient.NewHTTPClien... | explode_data.jsonl/39035 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 605
} | [
2830,
3393,
11505,
9676,
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,
16094,
28080,
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 TestAppSimulationAfterImport(t *testing.T) {
config, db, dir, logger, skip, err := simapp.SetupSimulation("leveldb-app-sim", "Simulation")
if skip {
t.Skip("skipping application simulation after import")
}
require.NoError(t, err, "simulation setup failed")
defer func() {
db.Close()
require.NoError(t, o... | explode_data.jsonl/23011 | {
"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,
2164,
64554,
6025,
11511,
1155,
353,
8840,
836,
8,
341,
25873,
11,
2927,
11,
5419,
11,
5925,
11,
10706,
11,
1848,
1669,
1643,
676,
39820,
64554,
445,
3449,
783,
65,
20023,
1331,
318,
497,
330,
64554,
1138,
743,
10706,
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 TestMergeConflictHeuristicRules(t *testing.T) {
common.Log.Debug("Entering function: %s", common.GetFunctionName())
tmpRules := make(map[string]Rule)
for item, val := range HeuristicRules {
tmpRules[item] = val
}
err := common.GoldenDiff(func() {
suggest := MergeConflictHeuristicRules(tmpRules)
var sort... | explode_data.jsonl/76850 | {
"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,
52096,
57974,
1519,
34456,
26008,
1155,
353,
8840,
836,
8,
341,
83825,
5247,
20345,
445,
82867,
729,
25,
1018,
82,
497,
4185,
2234,
5152,
675,
2398,
20082,
26008,
1669,
1281,
9147,
14032,
60,
11337,
340,
2023,
1509,
11,
1044... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestIsYaml(t *testing.T) {
var resp bool
resp = isYaml("test.yaml")
assert.True(t, resp)
resp = isYaml("test.yml")
assert.True(t, resp)
resp = isYaml("test.exe")
assert.False(t, resp)
} | explode_data.jsonl/36224 | {
"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,
3872,
56,
9467,
1155,
353,
8840,
836,
8,
341,
2405,
9039,
1807,
198,
34653,
284,
374,
56,
9467,
445,
1944,
33406,
1138,
6948,
32443,
1155,
11,
9039,
340,
34653,
284,
374,
56,
9467,
445,
1944,
33936,
1138,
6948,
32443,
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 |
func TestBytes2BigInt(t *testing.T) {
b := big.NewInt(0)
b.SetString("ffffffffffffffff", 16)
assert.EqualValues(t, b, Bytes2BigInt([]byte{0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff}))
} | explode_data.jsonl/31338 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 87
} | [
2830,
3393,
7078,
17,
87474,
1155,
353,
8840,
836,
8,
341,
2233,
1669,
2409,
7121,
1072,
7,
15,
340,
2233,
97304,
445,
53697,
53697,
497,
220,
16,
21,
340,
6948,
12808,
6227,
1155,
11,
293,
11,
30024,
17,
87474,
10556,
3782,
90,
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 TestSortAndMergeFileEdits(t *testing.T) {
tests := []struct {
name string
fileEdits []*FileEdit
want []*FileEdit
}{
{name: "no edits"},
{
name: "one edit",
fileEdits: []*FileEdit{
{toText: "one edit"},
},
want: []*FileEdit{
{toText: "one edit"},
},
},
{
name: "tw... | explode_data.jsonl/50639 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 2369
} | [
2830,
3393,
10231,
3036,
52096,
1703,
2715,
1199,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
1235,
341,
197,
11609,
414,
914,
198,
197,
17661,
2715,
1199,
29838,
1703,
4036,
198,
197,
50780,
414,
29838,
1703,
4036,
198,
197,
59403... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestMilestone_State(t *testing.T) {
assert.Equal(t, api.StateOpen, (&Milestone{IsClosed: false}).State())
assert.Equal(t, api.StateClosed, (&Milestone{IsClosed: true}).State())
} | explode_data.jsonl/21818 | {
"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,
44,
93028,
24773,
1155,
353,
8840,
836,
8,
341,
6948,
12808,
1155,
11,
6330,
18942,
5002,
11,
15899,
44,
93028,
90,
3872,
26884,
25,
895,
16630,
1397,
2398,
6948,
12808,
1155,
11,
6330,
18942,
26884,
11,
15899,
44,
93028,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSetICMPFilter(t *testing.T) {
switch runtime.GOOS {
case "linux":
default:
t.Skipf("not supported on %s", runtime.GOOS)
}
if m, ok := nettest.SupportsRawIPSocket(); !ok {
t.Skip(m)
}
c, err := net.ListenPacket("ip4:icmp", "127.0.0.1")
if err != nil {
t.Fatal(err)
}
defer c.Close()
p := ipv4.... | explode_data.jsonl/55242 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 317
} | [
2830,
3393,
1649,
1317,
5781,
5632,
1155,
353,
8840,
836,
8,
341,
8961,
15592,
97574,
3126,
341,
2722,
330,
14210,
4660,
11940,
510,
197,
3244,
57776,
69,
445,
1921,
7248,
389,
1018,
82,
497,
15592,
97574,
3126,
340,
197,
532,
743,
29... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestTemplateDependencies(t *testing.T) {
b := newTestSitesBuilder(t).Running()
b.WithTemplates("index.html", `
{{ $p := site.GetPage "p1" }}
{{ partial "p1.html" $p }}
{{ partialCached "p2.html" "foo" }}
{{ partials.Include "p3.html" "data" }}
{{ partials.IncludeCached "p4.html" "foo" }}
{{ $p := partial "p5" ... | explode_data.jsonl/60660 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 558
} | [
2830,
3393,
7275,
48303,
1155,
353,
8840,
836,
8,
341,
2233,
1669,
501,
2271,
93690,
3297,
1155,
568,
18990,
2822,
2233,
26124,
51195,
445,
1252,
2564,
497,
22074,
2979,
400,
79,
1669,
2747,
2234,
2665,
330,
79,
16,
1,
8096,
2979,
713... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestNullsOr(t *testing.T) {
length1, length2 := uint64(300), uint64(400)
n1 := nulls3.Slice(0, length1)
n2 := nulls5.Slice(0, length2)
or := n1.Or(&n2)
require.True(t, or.hasNulls)
for i := uint64(0); i < length2; i++ {
if i < length1 && n1.NullAt64(i) || i < length2 && n2.NullAt64(i) {
require.True(t, ... | explode_data.jsonl/37161 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 226
} | [
2830,
3393,
3280,
82,
2195,
1155,
353,
8840,
836,
8,
341,
49046,
16,
11,
3084,
17,
1669,
2622,
21,
19,
7,
18,
15,
15,
701,
2622,
21,
19,
7,
19,
15,
15,
340,
9038,
16,
1669,
845,
82,
18,
95495,
7,
15,
11,
3084,
16,
340,
9038,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 Test_PackToGoFile(t *testing.T) {
gtest.C(t, func(t *gtest.T) {
srcPath := gdebug.TestDataPath("files")
goFilePath := gdebug.TestDataPath("testdata.go")
pkgName := "testdata"
err := gres.PackToGoFile(srcPath, goFilePath, pkgName)
t.Assert(err, nil)
})
} | explode_data.jsonl/26296 | {
"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,
1088,
473,
1249,
10850,
1703,
1155,
353,
8840,
836,
8,
341,
3174,
1944,
727,
1155,
11,
2915,
1155,
353,
82038,
836,
8,
341,
197,
41144,
1820,
1669,
342,
8349,
8787,
1043,
1820,
445,
7198,
1138,
197,
30680,
19090,
1669,
342... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestFindFiles(t *testing.T) {
type args struct {
dir string
pattern string
}
tests := []struct {
name string
args args
want []string
}{
{"basic", args{"testdata/js", "models/{*}.js"}, []string{"models/Bar.js", "models/Foo.js"}},
{"recursive", args{"testdata/js", "models/{**}.js"}, []string{"m... | explode_data.jsonl/73556 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 338
} | [
2830,
3393,
9885,
10809,
1155,
353,
8840,
836,
8,
341,
13158,
2827,
2036,
341,
197,
48532,
257,
914,
198,
197,
3223,
3227,
914,
198,
197,
532,
78216,
1669,
3056,
1235,
341,
197,
11609,
914,
198,
197,
31215,
2827,
198,
197,
50780,
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 TestResolver_SetRepositoryPermissionsForUsers(t *testing.T) {
t.Run("authenticated as non-admin", func(t *testing.T) {
db.Mocks.Users.GetByCurrentAuthUser = func(context.Context) (*types.User, error) {
return &types.User{}, nil
}
defer func() {
db.Mocks.Users.GetByCurrentAuthUser = nil
}()
ctx :=... | explode_data.jsonl/14713 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 2018
} | [
2830,
3393,
18190,
14812,
4624,
23851,
2461,
7137,
1155,
353,
8840,
836,
8,
341,
3244,
16708,
445,
57707,
438,
2477,
27225,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
20939,
24664,
82,
36782,
2234,
1359,
5405,
5087,
1474,
284,
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... | 1 |
func TestSQLParamsHolder_AddParam(t *testing.T) {
holder := NewSQLParamsHolder("mysql")
t.Log(holder.Add(123))
t.Log(holder.Add("456"))
logs.PrintAsJSON(holder.Params, t)
t.Log(holder.Parse("SELECT * FROM t WHERE a=:HOLDER0 AND b=:HOLDER1"))
logs.PrintAsJSON(holder.Args, t)
} | explode_data.jsonl/55709 | {
"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,
6688,
4870,
8589,
21346,
2001,
1155,
353,
8840,
836,
8,
341,
88559,
1669,
1532,
6688,
4870,
8589,
445,
12272,
1138,
3244,
5247,
46826,
1904,
7,
16,
17,
18,
1171,
3244,
5247,
46826,
1904,
445,
19,
20,
21,
5455,
6725,
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... | 1 |
func TestSwitch(t *testing.T) {
const SCRIPT = `
function F(x) {
var i = 0;
switch (x) {
case 0:
i++;
case 1:
i++;
default:
i++;
case 2:
i++;
break;
case 3:
i++;
}
return i;
}
F(0) + F(1) + F(2) + F(4);
`
testScript1(SCRIPT, intToValue(10), t)
} | explode_data.jsonl/75294 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 163
} | [
2830,
3393,
16837,
1155,
353,
8840,
836,
8,
341,
4777,
53679,
284,
22074,
7527,
434,
2075,
8,
341,
197,
2405,
600,
284,
220,
15,
280,
197,
8961,
320,
87,
8,
341,
197,
2722,
220,
15,
510,
298,
8230,
3507,
197,
2722,
220,
16,
510,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func Test_DocumentProperties_UpdateDocumentProperty(t *testing.T) {
config := ReadConfiguration(t)
client, ctx := PrepareTest(t, config)
remoteDataFolder := remoteBaseTestDataFolder + "/DocumentElements/DocumentProperties"
localFile := "Common/test_multi_pages.docx"
remoteFileName := "TestUpdateDocu... | explode_data.jsonl/26161 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 470
} | [
2830,
3393,
1557,
1452,
7903,
47393,
7524,
3052,
1155,
353,
8840,
836,
8,
341,
262,
2193,
1669,
4457,
7688,
1155,
340,
262,
2943,
11,
5635,
1669,
31166,
2271,
1155,
11,
2193,
340,
262,
8699,
1043,
13682,
1669,
8699,
3978,
83920,
13682,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestMkdir(t *testing.T) {
type args struct {
dirName string
}
tests := []struct {
name string
args args
wantErr bool
}{
{
"test crete dri",
args{dirName: "./test/deep/dir/test"},
false,
},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
if err := NewFilesystem... | explode_data.jsonl/64621 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 222
} | [
2830,
3393,
44,
12438,
1155,
353,
8840,
836,
8,
341,
13158,
2827,
2036,
341,
197,
48532,
675,
914,
198,
197,
532,
78216,
1669,
3056,
1235,
341,
197,
11609,
262,
914,
198,
197,
31215,
262,
2827,
198,
197,
50780,
7747,
1807,
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... | 2 |
func TestOctetStreamAction(t *testing.T) {
cr := getCredential()
cpf := profile.NewClientProfile()
cpf.HttpProfile.Endpoint = "cls.tencentcloudapi.com"
cpf.HttpProfile.ReqMethod = "POST"
client, _ := cls.NewClient(cr, regions.Guangzhou, cpf)
request := cls.NewUploadLogRequest()
request.TopicId = common.StringPtr... | explode_data.jsonl/13613 | {
"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,
18053,
295,
3027,
2512,
1155,
353,
8840,
836,
8,
341,
91492,
1669,
43099,
30320,
741,
1444,
15897,
1669,
5526,
7121,
2959,
8526,
741,
1444,
15897,
9524,
8526,
90409,
284,
330,
18074,
39926,
12361,
2068,
905,
698,
1444,
15897,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestNonEscapingMap(t *testing.T) {
n := testing.AllocsPerRun(1000, func() {
m := map[int]int{}
m[0] = 0
})
if n != 0 {
t.Fatalf("mapliteral: want 0 allocs, got %v", n)
}
n = testing.AllocsPerRun(1000, func() {
m := make(map[int]int)
m[0] = 0
})
if n != 0 {
t.Fatalf("no hint: want 0 allocs, got %... | explode_data.jsonl/19926 | {
"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,
8121,
36121,
14216,
2227,
1155,
353,
8840,
836,
8,
341,
9038,
1669,
7497,
9636,
83629,
3889,
6727,
7,
16,
15,
15,
15,
11,
2915,
368,
341,
197,
2109,
1669,
2415,
18640,
63025,
16094,
197,
2109,
58,
15,
60,
284,
220,
15,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestFlow_InvalidCoding(t *testing.T) {
_, err := DecodeFlow("INVALID")
if err == nil {
t.Errorf("Unable to detect invalid flow from %s\n", "INVALID")
}
_, err = DecodeFlow("Y291Y291")
if err == nil {
t.Errorf("Unable to detect invalid flow from %s\n", "INVALID")
}
} | explode_data.jsonl/69663 | {
"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,
18878,
62,
7928,
77513,
1155,
353,
8840,
836,
8,
1476,
197,
6878,
1848,
1669,
50194,
18878,
445,
46859,
1138,
743,
1848,
621,
2092,
341,
197,
3244,
13080,
445,
17075,
311,
11140,
8318,
6396,
504,
1018,
82,
1699,
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... | 3 |
func TestExecConntrackTool(t *testing.T) {
fcmd := exec.FakeCmd{
CombinedOutputScript: []exec.FakeCombinedOutputAction{
func() ([]byte, error) { return []byte("1 flow entries have been deleted"), nil },
func() ([]byte, error) { return []byte("1 flow entries have been deleted"), nil },
func() ([]byte, error)... | explode_data.jsonl/9287 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 666
} | [
2830,
3393,
10216,
9701,
13131,
7740,
1155,
353,
8840,
836,
8,
341,
1166,
8710,
1669,
3883,
991,
726,
15613,
515,
197,
197,
94268,
5097,
5910,
25,
3056,
11748,
991,
726,
94268,
5097,
2512,
515,
298,
29244,
368,
34923,
3782,
11,
1465,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestGenerateNodesAddress(t *testing.T) {
assert := assert.New(t)
cluster := testCluster(t)
nodesURI := generateNodesAddress(cluster)
assert.Equal(1, len(nodesURI))
assert.NotNil(nodesURI[succeededNodeId])
assert.Equal(
fmt.Sprintf("%s-%d-node.%s.svc.cluster.local:%d",
clusterName, succeededNodeId, clu... | explode_data.jsonl/28889 | {
"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,
31115,
12288,
4286,
1155,
353,
8840,
836,
8,
341,
6948,
1669,
2060,
7121,
1155,
692,
197,
18855,
1669,
1273,
28678,
1155,
340,
79756,
10301,
1669,
6923,
12288,
4286,
48030,
692,
6948,
12808,
7,
16,
11,
2422,
38705,
10301,
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 TestRoaringPostingsListIterInsertAfter(t *testing.T) {
d := NewPostingsList()
d.Insert(1)
d.Insert(2)
require.Equal(t, 2, d.Len())
it := d.Iterator()
defer it.Close()
numElems := 0
d.Insert(3)
require.Equal(t, 3, d.Len())
found := map[postings.ID]bool{
1: false,
2: false,
}
for it.Next() {
found... | explode_data.jsonl/64021 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 207
} | [
2830,
3393,
38872,
3249,
4133,
819,
852,
8537,
13780,
6025,
1155,
353,
8840,
836,
8,
341,
2698,
1669,
1532,
4133,
819,
852,
741,
2698,
23142,
7,
16,
340,
2698,
23142,
7,
17,
340,
17957,
12808,
1155,
11,
220,
17,
11,
294,
65819,
1236... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestValidateAndBuildCellKeySuccess(t *testing.T) {
cellId := "aaaa"
prefix := "CELL"
delimiter := ":"
key, err := ValidateAndBuildCellIdKey(cellId)
if err != nil{
t.Errorf("#utils_test.TestValidateAndBuildCellKey - failed to validate key parameter")
}
assert.Contains(t, key, cellId)
assert.Contains(t, ke... | explode_data.jsonl/33035 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 138
} | [
2830,
3393,
17926,
3036,
11066,
3599,
1592,
7188,
1155,
353,
8840,
836,
8,
341,
45987,
764,
1669,
330,
28458,
698,
3223,
5060,
1669,
330,
63555,
698,
69509,
17700,
1669,
13022,
698,
23634,
11,
1848,
1669,
23282,
3036,
11066,
3599,
764,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 Test_indices_aliases_dfccd8ff46a6b44d2776951ea83e5a84(t *testing.T) {
es, _ := elasticsearch.NewDefaultClient()
// tag:dfccd8ff46a6b44d2776951ea83e5a84[]
res, err := es.Indices.UpdateAliases(strings.NewReader(`{
"actions": [
{
"add": {
"indices": [
"test1",
"... | explode_data.jsonl/50103 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 320
} | [
2830,
3393,
18333,
90233,
10894,
95840,
23,
542,
19,
21,
64,
21,
65,
19,
19,
67,
17,
22,
22,
21,
24,
20,
16,
12508,
23,
18,
68,
20,
64,
23,
19,
1155,
353,
8840,
836,
8,
341,
78966,
11,
716,
1669,
655,
27791,
7121,
3675,
2959,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestNewFeatureUsers(t *testing.T) {
featureA := &wave.Feature{Name: "test", Groups: nil, Users: []string{"test"}}
featureB := wave.NewFeatureUsers("test", []string{"test"})
if featureA.Name != featureB.Name {
t.Errorf("Feature names do not match")
}
if featureA.Users[0] != featureB.Users[0] {
t.Errorf("... | explode_data.jsonl/10798 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 154
} | [
2830,
3393,
3564,
13859,
7137,
1155,
353,
8840,
836,
8,
341,
1166,
15208,
32,
1669,
609,
30398,
58434,
63121,
25,
330,
1944,
497,
34580,
25,
2092,
11,
14627,
25,
3056,
917,
4913,
1944,
95642,
1166,
15208,
33,
1669,
12060,
7121,
13859,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestValidate_AnonymousOperationMustBeAlone_MultipleNamedOperations(t *testing.T) {
testutil.ExpectPassesRule(t, graphql.LoneAnonymousOperationRule, `
query Foo {
field
}
query Bar {
field
}
`)
} | explode_data.jsonl/78444 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 106
} | [
2830,
3393,
17926,
1566,
6280,
89392,
8432,
31776,
3430,
2101,
603,
1245,
12229,
15810,
35120,
1155,
353,
8840,
836,
8,
341,
18185,
1314,
81893,
12187,
288,
11337,
1155,
11,
48865,
1214,
603,
32684,
8432,
11337,
11,
22074,
414,
3239,
3342... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestMultiChannelConfig(t *testing.T) {
// Scenario: node 1 is knows node 2 only in channel "foo"
// and knows node 3 only in channel "bar".
// Messages that are received, are routed according to their corresponding channels
// and when node 2 sends a message for channel "bar" to node 1, it is rejected.
// Sam... | explode_data.jsonl/39843 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1094
} | [
2830,
3393,
20358,
9629,
2648,
1155,
353,
8840,
836,
8,
341,
197,
322,
58663,
25,
2436,
220,
16,
374,
8788,
2436,
220,
17,
1172,
304,
5496,
330,
7975,
698,
197,
322,
323,
8788,
2436,
220,
18,
1172,
304,
5496,
330,
2257,
22956,
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 TestCreatesAllServicesReleaseData(t *testing.T) {
t.Parallel()
const (
service1NameStr string = "service-1"
service1Name = voyager.ServiceName(service1NameStr)
service2NameStr string = "service-2"
service2Name = voyager.ServiceName(service2NameStr)
)
service1 := &core_v1.Namespace{... | explode_data.jsonl/4277 | {
"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,
54868,
2403,
11025,
16077,
1043,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
4777,
2399,
197,
52934,
16,
675,
2580,
914,
284,
330,
7936,
12,
16,
698,
197,
52934,
16,
675,
1843,
284,
23063,
1409,
13860,
675,
2165... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestQueueStorePut(t *testing.T) {
defer func() {
if err := tearDownStore(); err != nil {
t.Fatal("Failed to tear down store ", err)
}
}()
store, err := setUpStore(queueDir, 100)
if err != nil {
t.Fatal("Failed to create a queue store ", err)
}
// Put 100 events.
for i := 0; i < 100; i++ {
if err... | explode_data.jsonl/53359 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 242
} | [
2830,
3393,
7554,
6093,
19103,
1155,
353,
8840,
836,
8,
341,
16867,
2915,
368,
341,
197,
743,
1848,
1669,
32825,
6093,
2129,
1848,
961,
2092,
341,
298,
3244,
26133,
445,
9408,
311,
17576,
1495,
3553,
3670,
1848,
340,
197,
197,
532,
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 Test_TableBorder_GetBorders(t *testing.T) {
config := ReadConfiguration(t)
client, ctx := PrepareTest(t, config)
remoteDataFolder := remoteBaseTestDataFolder + "/DocumentElements/Tables"
localFile := "DocumentElements/Tables/TablesGet.docx"
remoteFileName := "TestGetBorders.docx"
UploadNex... | explode_data.jsonl/16252 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 458
} | [
2830,
3393,
42544,
10691,
13614,
85037,
1155,
353,
8840,
836,
8,
341,
262,
2193,
1669,
4457,
7688,
1155,
340,
262,
2943,
11,
5635,
1669,
31166,
2271,
1155,
11,
2193,
340,
262,
8699,
1043,
13682,
1669,
8699,
3978,
83920,
13682,
488,
3521... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCodeBool(t *testing.T) {
var buf = make([]byte, 9)
var v bool = true
var n uint64
n = EncodeBool(buf, v)
var d bool
n = DecodeBool(buf[:n], &d)
if v != d {
t.Errorf("error %t != %t", v, d)
}
if n != SizeofBool(v) {
t.Errorf("error %d != %d", n, len(buf[:n]))
}
v = false
n = EncodeBool(buf, v)
... | explode_data.jsonl/58553 | {
"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,
2078,
11233,
1155,
353,
8840,
836,
8,
341,
2405,
6607,
284,
1281,
10556,
3782,
11,
220,
24,
340,
2405,
348,
1807,
284,
830,
198,
2405,
308,
2622,
21,
19,
198,
9038,
284,
56562,
11233,
10731,
11,
348,
340,
2405,
294,
1807... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestListenNotify(t *testing.T) {
t.Parallel()
listener := mustConnectString(t, os.Getenv("PGX_TEST_DATABASE"))
defer closeConn(t, listener)
if listener.PgConn().ParameterStatus("crdb_version") != "" {
t.Skip("Server does not support LISTEN / NOTIFY (https://github.com/cockroachdb/cockroach/issues/41522)")
... | explode_data.jsonl/40016 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 513
} | [
2830,
3393,
38714,
28962,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
14440,
798,
1669,
1969,
14611,
703,
1155,
11,
2643,
64883,
445,
11383,
55,
11641,
45510,
5455,
16867,
3265,
9701,
1155,
11,
11446,
692,
743,
11446,
1069,
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... | 2 |
func TestGetUsersWithInvalidEmails(t *testing.T) {
th := Setup(t).InitBasic()
defer th.TearDown()
client := th.SystemAdminClient
user := model.User{
Email: "ben@invalid.mattermost.com",
Nickname: "Ben Cooke",
Password: "hello1",
Username: GenerateTestUsername(),
Roles: model.SystemAdminRoleId + " "... | explode_data.jsonl/47582 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 516
} | [
2830,
3393,
1949,
7137,
2354,
7928,
4781,
82,
1155,
353,
8840,
836,
8,
341,
70479,
1669,
18626,
1155,
568,
3803,
15944,
741,
16867,
270,
836,
682,
4454,
741,
25291,
1669,
270,
16620,
7210,
2959,
271,
19060,
1669,
1614,
7344,
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... | 1 |
func TestSimpleOrphanChain(t *testing.T) {
t.Parallel()
harness, spendableOuts, err := newPoolHarness(&chaincfg.MainNetParams)
if err != nil {
t.Fatalf("unable to create test pool: %v", err)
}
tc := &testContext{t, harness}
// Create a chain of transactions rooted with the first spendable output
// provided ... | explode_data.jsonl/53795 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 705
} | [
2830,
3393,
16374,
2195,
9943,
18837,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
9598,
23518,
11,
8329,
480,
2662,
82,
11,
1848,
1669,
501,
10551,
74248,
2099,
8819,
14072,
23873,
6954,
4870,
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... | 9 |
func TestAuthzCheckMissing(t *testing.T) {
t.Parallel()
checker := NewMiddleware()
nocheck := func(context.Context, interface{}) (interface{}, error) { return struct{}{}, nil }
nocheck = checker.AuthzCheck()(nocheck)
_, err := nocheck(context.Background(), struct{}{})
assert.Error(t, err)
} | explode_data.jsonl/24360 | {
"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,
5087,
89,
3973,
25080,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
25157,
261,
1669,
1532,
24684,
2822,
72104,
2028,
1669,
2915,
5378,
9328,
11,
3749,
28875,
320,
4970,
22655,
1465,
8,
314,
470,
2036,
6257,
22655,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCreateASGSession(t *testing.T) {
testAWSClient(
t,
"ASG",
func(t *testing.T, s *session.Session, region *string, role Role, fips bool) {
iface := createASGSession(s, region, role, fips)
if iface == nil {
t.Fail()
}
})
} | explode_data.jsonl/18787 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 114
} | [
2830,
3393,
4021,
1911,
38,
5283,
1155,
353,
8840,
836,
8,
341,
18185,
36136,
2959,
1006,
197,
3244,
345,
197,
197,
1,
1911,
38,
756,
197,
29244,
1155,
353,
8840,
836,
11,
274,
353,
5920,
20674,
11,
5537,
353,
917,
11,
3476,
15404,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCreateSQLTask(t *testing.T) {
a := assert.New(t)
ali := newAlisaFromEnv(t)
code := "SELECT 2;"
taskID, _, err := ali.createSQLTask(code)
time.Sleep(time.Second * 2) // to avoid touching the flow-control
a.NoError(err)
a.NotEmpty(taskID)
} | explode_data.jsonl/9342 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 102
} | [
2830,
3393,
4021,
6688,
6262,
1155,
353,
8840,
836,
8,
341,
11323,
1669,
2060,
7121,
1155,
340,
197,
7956,
1669,
501,
2101,
10761,
3830,
14359,
1155,
340,
43343,
1669,
330,
4858,
220,
17,
41655,
49115,
915,
11,
8358,
1848,
1669,
18991,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPopulateAccountEntry(t *testing.T) {
tt := assert.New(t)
ctx, _ := test.ContextWithLogBuffer()
hAccount := Account{}
err := PopulateAccountEntry(ctx, &hAccount, account, data, signers, trustLines, ledgerWithCloseTime)
tt.NoError(err)
tt.Equal(account.AccountID, hAccount.ID)
tt.Equal(account.AccountID, ... | explode_data.jsonl/9834 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1963
} | [
2830,
3393,
11598,
6334,
7365,
5874,
1155,
353,
8840,
836,
8,
341,
3244,
83,
1669,
2060,
7121,
1155,
340,
20985,
11,
716,
1669,
1273,
9328,
2354,
2201,
4095,
741,
9598,
7365,
1669,
8615,
16094,
9859,
1669,
70938,
7365,
5874,
7502,
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... | 8 |
func TestNewApplicationGroupSkipAsForeign(t *testing.T) {
t.Parallel()
gt := NewGomegaWithT(t)
application := baseApplication()
application.Organizations[0].SkipAsForeign = true
application.Organizations[1].SkipAsForeign = true
mspConfig := &mb.MSPConfig{}
applicationGroup, err := NewApplicationGroup(applica... | explode_data.jsonl/51981 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 326
} | [
2830,
3393,
3564,
4988,
2808,
35134,
2121,
58632,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
3174,
83,
1669,
1532,
38,
32696,
2354,
51,
1155,
692,
197,
5132,
1669,
2331,
4988,
741,
197,
5132,
8382,
8443,
8040,
58,
15,
936,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestProxyDefaults(t *testing.T) {
p := proxy{}
assert.Equal(t, p.path(), defaultProxyPath, "default proxy path wrong")
path := "/foo/bar/baz/proxy"
p.Path = path
assert.Equal(t, p.path(), path, "custom proxy path wrong")
} | explode_data.jsonl/5130 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 87
} | [
2830,
3393,
16219,
16273,
1155,
353,
8840,
836,
8,
341,
3223,
1669,
13291,
31483,
6948,
12808,
1155,
11,
281,
3875,
1507,
1638,
16219,
1820,
11,
330,
2258,
13291,
1815,
4969,
5130,
26781,
1669,
3521,
7975,
49513,
3470,
1370,
18008,
4130,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPolicyTransportScopesWithTransportUnmarshalJSON(t *testing.T) {
var pts PolicyTransportScopes
dest := policyTransportScopesWithTransport{
transport: docker.Transport,
dest: &pts,
}
testInvalidJSONInput(t, &dest)
// Start with a valid JSON.
validPTS := PolicyTransportScopes{
"docker.io/librar... | explode_data.jsonl/36495 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1065
} | [
2830,
3393,
13825,
27560,
3326,
18523,
2354,
27560,
1806,
27121,
5370,
1155,
353,
8840,
836,
8,
341,
2405,
29993,
10974,
27560,
3326,
18523,
271,
49616,
1669,
4842,
27560,
3326,
18523,
2354,
27560,
515,
197,
197,
26445,
25,
26588,
87669,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestRebuildIndexDamage(t *testing.T) {
testRebuildIndex(t, func(r restic.Backend) (restic.Backend, error) {
return &indexErrorBackend{
Backend: r,
}, nil
})
} | explode_data.jsonl/43566 | {
"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,
693,
5834,
1552,
24261,
1155,
353,
8840,
836,
8,
341,
18185,
693,
5834,
1552,
1155,
11,
2915,
2601,
2732,
292,
8864,
408,
8,
320,
3927,
292,
8864,
408,
11,
1465,
8,
341,
197,
853,
609,
1252,
1454,
29699,
515,
298,
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 |
func TestFeeBumpInvalidInnerTransactionType(t *testing.T) {
kp0 := newKeypair0()
sourceAccount := NewSimpleAccount(kp0.Address(), 1)
tx, err := NewTransaction(
TransactionParams{
SourceAccount: &sourceAccount,
IncrementSequenceNum: false,
Operations: []Operation{&Inflation{}},
BaseFee... | explode_data.jsonl/67675 | {
"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,
41941,
33,
1510,
7928,
31597,
8070,
929,
1155,
353,
8840,
836,
8,
341,
16463,
79,
15,
1669,
501,
6608,
1082,
1310,
15,
741,
47418,
7365,
1669,
1532,
16374,
7365,
5969,
79,
15,
26979,
1507,
220,
16,
692,
46237,
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... | 1 |
func TestBadSeparator(t *testing.T) {
type config struct {
WontWork []int `env:"WONTWORK" envSeparator:":"`
}
cfg := &config{}
os.Setenv("WONTWORK", "1,2,3,4")
defer os.Clearenv()
assert.EqualError(t, Parse(cfg), "env: parse error on field \"WontWork\" of type \"[]int\": strconv.ParseInt: parsing \"1,2,3,4\":... | explode_data.jsonl/78777 | {
"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,
17082,
16409,
1155,
353,
8840,
836,
8,
341,
13158,
2193,
2036,
341,
197,
17300,
544,
6776,
3056,
396,
1565,
3160,
2974,
54,
10232,
18470,
1,
6105,
16409,
25,
3252,
3989,
197,
630,
50286,
1669,
609,
1676,
16094,
25078,
4202,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestJolokia2_MetricCompaction(t *testing.T) {
config := `
[jolokia2_agent]
urls = ["%s"]
[[jolokia2_agent.metric]]
name = "compact_metric"
mbean = "scalar_value:flavor=chocolate"
tag_keys = ["flavor"]
[[jolokia2_agent.metric]]
name = "compact_metric"
mbean = "scalar_value:flavor=van... | explode_data.jsonl/5359 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 839
} | [
2830,
3393,
41,
337,
27552,
17,
1245,
16340,
13552,
1311,
1155,
353,
8840,
836,
8,
341,
25873,
1669,
22074,
197,
3809,
337,
27552,
17,
25730,
921,
197,
19320,
82,
284,
4383,
4,
82,
25912,
197,
15505,
73,
337,
27552,
17,
25730,
85816,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestGroupsListAllIntegrationFilterForNonexistentName(t *testing.T) {
c := client()
zones, err := c.ZonesListAll(ListFilter{
NameFilter: "foo",
})
if err != nil {
t.Error(err)
}
if len(zones) > 0 {
t.Error("Expected GroupsListAll for groups named 'foo' to yield no results")
}
} | explode_data.jsonl/12112 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 115
} | [
2830,
3393,
22173,
852,
2403,
52464,
5632,
2461,
8121,
64085,
675,
1155,
353,
8840,
836,
8,
341,
1444,
1669,
2943,
741,
20832,
3154,
11,
1848,
1669,
272,
13476,
3154,
852,
2403,
10278,
5632,
515,
197,
21297,
5632,
25,
330,
7975,
756,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestDataPath(t *testing.T) {
os.Unsetenv(xdg.DataHomeEnvVar)
expected := filepath.Join(homedir.HomeDir(), "Library", appName, testFile)
if lazy.dataPath(testFile) != expected {
t.Errorf("expected '%s', got '%s'", expected, lazy.dataPath(testFile))
}
os.Setenv(xdg.DataHomeEnvVar, "/tmp")
expected = file... | explode_data.jsonl/26075 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 185
} | [
2830,
93200,
1820,
1155,
353,
8840,
836,
8,
341,
25078,
10616,
746,
3160,
2075,
35138,
3336,
7623,
14359,
3962,
692,
42400,
1669,
26054,
22363,
3203,
24139,
404,
59965,
6184,
1507,
330,
16915,
497,
67819,
11,
1273,
1703,
692,
743,
15678,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestQuery(t *testing.T) {
common.Config.QueryTimeOut = 1
_, err := connTest.Query("select sleep(2)")
if err == nil {
t.Error("connTest.Query not timeout")
}
} | explode_data.jsonl/69283 | {
"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,
2859,
1155,
353,
8840,
836,
8,
341,
83825,
10753,
15685,
1462,
2662,
284,
220,
16,
198,
197,
6878,
1848,
1669,
4534,
2271,
15685,
445,
1742,
6084,
7,
17,
19107,
743,
1848,
621,
2092,
341,
197,
3244,
6141,
445,
5148,
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
] | 2 |
func TestRuntimeParameters(t *testing.T) {
tests := []struct {
conninfo string
param string
expected string
success bool
}{
// invalid parameter
{"DOESNOTEXIST=foo", "", "", false},
// we can only work with a specific value for these two
{"client_encoding=SQL_ASCII", "", "", false},
{"datestyle=... | explode_data.jsonl/73504 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 773
} | [
2830,
3393,
15123,
9706,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
1235,
341,
197,
32917,
2733,
914,
198,
197,
36037,
262,
914,
198,
197,
42400,
914,
198,
197,
30553,
220,
1807,
198,
197,
59403,
197,
197,
322,
8318,
5733,
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... | 2 |
func TestMvToDir(t *testing.T) {
file := "sample.md"
attachment := "images/sample.png"
dest := "folder"
testFs := newTmpFS(t)
copyFile(t, testFs, filepath.Join("testdata", file), file)
copyFile(t, testFs, filepath.Join("testdata", attachment), attachment)
err := testFs.Mkdir(dest, os.ModePerm)
failOn(t, err, "... | explode_data.jsonl/36830 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 259
} | [
2830,
3393,
44,
85,
1249,
6184,
1155,
353,
8840,
836,
8,
341,
17661,
1669,
330,
13611,
21324,
698,
197,
21981,
1669,
330,
3642,
69851,
3508,
698,
49616,
1669,
330,
17668,
1837,
18185,
48300,
1669,
501,
35986,
8485,
1155,
340,
49124,
170... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestWatchingTimeouts(t *testing.T) {
listener, addr := tmpSock(t)
defer listener.Close()
defer os.Remove(addr)
config := &Config{
Endpoint: fmt.Sprintf("unix://%s", addr),
Timeout: 50 * time.Millisecond,
}
cli, err := newPodmanClient(zap.NewNop(), config)
assert.NotNil(t, cli)
assert.Nil(t, err)
e... | explode_data.jsonl/43767 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 291
} | [
2830,
3393,
95737,
7636,
82,
1155,
353,
8840,
836,
8,
341,
14440,
798,
11,
10789,
1669,
4174,
79812,
1155,
340,
16867,
11446,
10421,
741,
16867,
2643,
13270,
24497,
692,
25873,
1669,
609,
2648,
515,
197,
197,
27380,
25,
8879,
17305,
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 TestRequestRoute(t *testing.T) {
const (
height = 10
)
findPath := func(g *graphParams, r *RestrictParams,
source, target route.Vertex, amt lnwire.MilliSatoshi) (
[]*channeldb.ChannelEdgePolicy, error) {
// We expect find path to receive a cltv limit excluding the
// final cltv delta.
if *r.CltvLi... | explode_data.jsonl/6989 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 446
} | [
2830,
3393,
1900,
4899,
1155,
353,
8840,
836,
8,
341,
4777,
2399,
197,
30500,
284,
220,
16,
15,
198,
197,
692,
80603,
1820,
1669,
2915,
3268,
353,
4439,
4870,
11,
435,
353,
50360,
849,
4870,
345,
197,
47418,
11,
2169,
6021,
72594,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestORM_Get(t *testing.T) {
orm, _ := NewSqlite3ORM(false, "/tmp/", "test.db", nil)
r, e := orm.getLatestKlineM1ByProduct("abc_bcd", 100)
assert.True(t, r != nil && e == nil)
fmt.Printf("%+v\n", r)
fmt.Printf("%+v\n", *r)
for i, v := range *r {
fmt.Printf("%+v, %+v\n", i, types.TimeString(v.Timestamp))
... | explode_data.jsonl/77881 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 162
} | [
2830,
3393,
4365,
13614,
1155,
353,
8840,
836,
8,
1476,
197,
493,
11,
716,
1669,
1532,
8269,
632,
18,
4365,
3576,
11,
3521,
5173,
28105,
330,
1944,
7076,
497,
2092,
340,
7000,
11,
384,
1669,
67602,
670,
31992,
42,
1056,
44,
16,
1359... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestClientDevice(t *testing.T) {
db := tests.Tempfile()
defer os.Remove(db)
// Create the app
app := glusterfs.NewTestApp(db)
defer app.Close()
// Setup the server
ts := setupHeketiServer(app)
defer ts.Close()
// Create cluster
c := NewClient(ts.URL, "admin", TEST_ADMIN_KEY)
tests.Assert(t, c != nil)... | explode_data.jsonl/18014 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1234
} | [
2830,
3393,
2959,
6985,
1155,
353,
8840,
836,
8,
341,
20939,
1669,
7032,
65009,
1192,
741,
16867,
2643,
13270,
9791,
692,
197,
322,
4230,
279,
906,
198,
28236,
1669,
2770,
4993,
3848,
7121,
2271,
2164,
9791,
340,
16867,
906,
10421,
2822... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestReplaceNullables(t *testing.T) {
testCases := []struct {
name string
in interface{}
expect interface{}
}{
{
name: "nothing",
in: nil,
expect: nil,
},
{
name: "NullableBool",
in: &struct {
B option.NullableBool
}{
B: option.NullBool,
},
expect: &struct {... | explode_data.jsonl/73735 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 901
} | [
2830,
3393,
23107,
3280,
4788,
1155,
353,
8840,
836,
8,
341,
18185,
37302,
1669,
3056,
1235,
341,
197,
11609,
256,
914,
198,
197,
17430,
257,
3749,
16094,
197,
24952,
3749,
16094,
197,
59403,
197,
197,
515,
298,
11609,
25,
256,
330,
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 TestQueryWithBuilder(t *testing.T) {
assert.NoError(t, prepareEngine())
type QueryWithBuilder struct {
Id int64 `xorm:"autoincr pk"`
Msg string `xorm:"varchar(255)"`
Age int
Money float32
Created time.Time `xorm:"created"`
}
testEngine.ShowSQL(true)
assert.NoError(t, testEngine.Sy... | explode_data.jsonl/70221 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 499
} | [
2830,
3393,
2859,
2354,
3297,
1155,
353,
8840,
836,
8,
341,
6948,
35699,
1155,
11,
10549,
4571,
12367,
13158,
11361,
2354,
3297,
2036,
341,
197,
67211,
414,
526,
21,
19,
220,
1565,
87,
493,
2974,
3902,
98428,
22458,
8805,
197,
197,
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 TestRegister_ok(t *testing.T) {
ctx := context.Background()
cfgBloomFilter :=
rpc.Config{
Config: rotate.Config{
Config: bloomfilter.Config{
N: 10000000,
P: 0.0000001,
HashName: "optimal",
},
TTL: 1500,
},
Port: 1234,
}
cfgConsul := consul.Config{
Address:... | explode_data.jsonl/48331 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 534
} | [
2830,
3393,
8690,
19817,
1155,
353,
8840,
836,
8,
341,
20985,
1669,
2266,
19047,
741,
50286,
33,
18474,
5632,
19687,
197,
7000,
3992,
10753,
515,
298,
66156,
25,
16919,
10753,
515,
571,
66156,
25,
51454,
5315,
10753,
515,
464,
18317,
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... | 2 |
func TestDownloadTLS(t *testing.T) {
cd := "../../testdata"
ca, pub, priv := filepath.Join(cd, "rootca.crt"), filepath.Join(cd, "crt.pem"), filepath.Join(cd, "key.pem")
tlsSrv := httptest.NewUnstartedServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {}))
tlsConf, err := tlsutil.NewClientTLS(pub,... | explode_data.jsonl/53168 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 545
} | [
2830,
3393,
11377,
45439,
1155,
353,
8840,
836,
8,
341,
72826,
1669,
10208,
92425,
698,
197,
924,
11,
6675,
11,
6095,
1669,
26054,
22363,
75912,
11,
330,
2888,
924,
93869,
3975,
26054,
22363,
75912,
11,
330,
66,
3342,
49373,
3975,
26054... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestIngressHandler_Receive_Succeed(t *testing.T) {
client := &fakeClient{}
reporter := &mockReporter{}
handler := Handler{
Logger: zaptest.NewLogger(t, zaptest.WrapOptions(zap.AddCaller())),
CeClient: client,
Reporter: reporter,
Defaulter: broker.TTLDefaulter(zap.NewNop(), 5),
}
event := cloudev... | explode_data.jsonl/11032 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 305
} | [
2830,
3393,
641,
2483,
3050,
62,
14742,
1098,
29264,
1155,
353,
8840,
836,
8,
341,
25291,
1669,
609,
30570,
2959,
16094,
69931,
261,
1669,
609,
16712,
52766,
16094,
53326,
1669,
19954,
515,
197,
55861,
25,
262,
32978,
1944,
7121,
7395,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestIntegrationsCreateAws(t *testing.T) {
var (
intgGUID = intgguid.New()
fakeServer = lacework.MockServer()
)
fakeServer.MockAPI("external/integrations", func(w http.ResponseWriter, r *http.Request) {
assert.Equal(t, "POST", r.Method, "CreateAws should be a POST method")
if assert.NotNil(t, r.Body)... | explode_data.jsonl/81113 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 751
} | [
2830,
3393,
1072,
14412,
804,
4021,
47359,
1155,
353,
8840,
836,
8,
341,
2405,
2399,
197,
2084,
70,
41778,
256,
284,
526,
14398,
2423,
7121,
741,
197,
1166,
726,
5475,
284,
45693,
1778,
24664,
5475,
741,
197,
692,
1166,
726,
5475,
246... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSelector(t *testing.T) {
podSelector := features.New("PodNetworking/PodSelector").WithLabel("env", "trunking").
Setup(func(ctx context.Context, t *testing.T, config *envconf.Config) context.Context {
pn := newPodNetworking(defaultPodNetworkingName, nil, nil, &metav1.LabelSelector{
MatchLabels: map[st... | explode_data.jsonl/4260 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1811
} | [
2830,
3393,
5877,
1155,
353,
8840,
836,
8,
341,
3223,
347,
5877,
1669,
4419,
7121,
445,
23527,
78007,
16341,
347,
5877,
1827,
2354,
2476,
445,
3160,
497,
330,
376,
3122,
287,
38609,
197,
197,
21821,
18552,
7502,
2266,
9328,
11,
259,
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 TestErrorMessage1(t *testing.T) {
msg := &Error{Type: uint32(M_USER_CREATE_ACCOUNT), Error: E_EMAIL_EXISTS}
if msg.Type != uint32(M_USER_CREATE_ACCOUNT) || msg.Error != E_EMAIL_EXISTS {
t.Fail()
}
} | explode_data.jsonl/29151 | {
"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,
21349,
16,
1155,
353,
8840,
836,
8,
341,
21169,
1669,
609,
1454,
90,
929,
25,
2622,
18,
17,
3189,
9107,
25823,
38831,
701,
4600,
25,
468,
29548,
70042,
532,
743,
3750,
10184,
961,
2622,
18,
17,
3189,
9107,
25823,
38831,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_CfgBool(t *testing.T) {
testDate := time.Now().Unix()
data := true
key := fmt.Sprintf("test bool %d", testDate)
err := conn.SetCfgBool(key, data)
if err != nil {
t.Fatal(err)
}
val, err := conn.GetCfgBool(key, !data)
if err != nil {
t.Fatal(err)
}
if data != val {
t.Fatalf("cfg bool mismatc... | explode_data.jsonl/22020 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 305
} | [
2830,
3393,
920,
4817,
11233,
1155,
353,
8840,
836,
8,
341,
18185,
1916,
1669,
882,
13244,
1005,
55832,
741,
8924,
1669,
830,
198,
23634,
1669,
8879,
17305,
445,
1944,
1807,
1018,
67,
497,
1273,
1916,
692,
9859,
1669,
4534,
4202,
42467,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCreateModule_Interdependent(t *testing.T) {
const multiModule = `
-- moda/a/go.mod --
module a.com
require b.com v1.2.3
-- moda/a/go.sum --
b.com v1.2.3 h1:tXrlXP0rnjRpKNmkbLYoWBdq0ikb3C3bKK9//moAWBI=
b.com v1.2.3/go.mod h1:D+J7pfFBZK5vdIdZEFquR586vKKIkqG7Qjw9AxG5BQ8=
-- moda/a/a.go --
package a
import (
"... | explode_data.jsonl/37365 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 623
} | [
2830,
3393,
4021,
3332,
79717,
37555,
1155,
353,
8840,
836,
8,
341,
4777,
7299,
3332,
284,
22074,
313,
90668,
14186,
25525,
10929,
39514,
4352,
264,
905,
271,
4310,
293,
905,
348,
16,
13,
17,
13,
18,
198,
313,
90668,
14186,
25525,
131... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestMonitor_SetPointsWriter_StoreDisabled(t *testing.T) {
s := monitor.New(nil, monitor.Config{})
core, logs := observer.New(zap.DebugLevel)
s.WithLogger(zap.New(core))
// Setting the points writer should open the monitor.
var pw PointsWriter
if err := s.SetPointsWriter(&pw); err != nil {
t.Fatalf("unexpe... | explode_data.jsonl/7523 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 186
} | [
2830,
3393,
30098,
14812,
11411,
6492,
92684,
25907,
1155,
353,
8840,
836,
8,
341,
1903,
1669,
8718,
7121,
27907,
11,
8718,
10753,
37790,
71882,
11,
18422,
1669,
22067,
7121,
13174,
391,
20345,
4449,
340,
1903,
26124,
7395,
13174,
391,
71... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestTaskExecIDFails(t *testing.T) {
testcases := []struct {
taskID string
execID string
}{
{
taskID: "ta/sk",
execID: "",
},
{
taskID: "ta/sk",
execID: "exec",
},
{
taskID: "task",
execID: "ex/ec",
},
{
taskID: "ta/sk",
execID: "ex/ec",
},
{
taskID: "task/",
ex... | explode_data.jsonl/22773 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 291
} | [
2830,
3393,
6262,
10216,
915,
37,
6209,
1155,
353,
8840,
836,
8,
341,
18185,
23910,
1669,
3056,
1235,
341,
197,
49115,
915,
914,
198,
197,
67328,
915,
914,
198,
197,
59403,
197,
197,
515,
298,
49115,
915,
25,
330,
2565,
2687,
74,
75... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPayloadDataForTransaction(t *testing.T) {
// add test data for testing
// * specific edge cases
// * multiple allowed dataypes
// * regex pattern, time formats
// * length restrictions, other than keyword length restrictions
transactionProcSetup().DataValidation(t,
[]tests.SchemaTestData{
{Key: "tr... | explode_data.jsonl/65350 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1403
} | [
2830,
3393,
29683,
1043,
2461,
8070,
1155,
353,
8840,
836,
8,
341,
197,
322,
912,
1273,
821,
369,
7497,
198,
197,
322,
353,
3151,
6821,
5048,
198,
197,
322,
353,
5248,
5420,
3258,
352,
20352,
198,
197,
322,
353,
20180,
5383,
11,
882... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestString(t *testing.T) {
input := "\"egghead\""
lex := lexer.NewLexer(input)
tokens, _ := lex.GetTokens()
parser := NewParser(tokens)
expressions, _ := parser.GetExpressions()
assertString(t, "egghead", expressions[0].(expr.Atom).Value.(string))
} | explode_data.jsonl/43719 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 98
} | [
2830,
3393,
703,
1155,
353,
8840,
836,
8,
341,
22427,
1669,
15898,
28368,
1983,
2105,
698,
197,
2571,
1669,
53259,
7121,
92847,
5384,
340,
3244,
9713,
11,
716,
1669,
22429,
2234,
29300,
741,
55804,
1669,
1532,
6570,
34052,
340,
8122,
39... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestReadWithSignaturesWithBaseDir(t *testing.T) {
signedTokenHS256 := `eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImZvbyJ9.eyJmaWxlcyI6W3sibmFtZSI6ImZvby9iYXIvLm1hbmlmZXN0IiwiaGFzaCI6IjUwN2EyYzM4YTE0NDFkYjU4ZDJjYjg3OTgyYzQyYWE5MWE0MzQyZWY0MjJhNmI1NDJlZGRlYmVlZjZmMDQxMmYiLCJhbGdvcml0aG0iOiJTSEEtMjU2In0seyJuYW1lIj... | explode_data.jsonl/55371 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 826
} | [
2830,
3393,
4418,
2354,
7264,
2789,
2354,
3978,
6184,
1155,
353,
8840,
836,
8,
341,
1903,
1542,
3323,
11961,
17,
20,
21,
1669,
1565,
84609,
49039,
38,
5855,
81096,
45064,
52,
89,
40,
16,
56494,
3872,
641,
49,
20,
66,
11237,
21,
40,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.