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 TestSingleObject(t *testing.T) {
// Create a request to pass to our handler. We don't have any query parameters for now, so we'll
// pass 'nil' as the third parameter.
userJson := `{"username": "dennis", "balance": 200}`
reader := strings.NewReader(userJson)
req, err := http.NewRequest("GET", "/health-check"... | explode_data.jsonl/32026 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 179
} | [
2830,
3393,
10888,
1190,
1155,
353,
8840,
836,
8,
1476,
197,
322,
4230,
264,
1681,
311,
1494,
311,
1039,
7013,
13,
1205,
1513,
944,
614,
894,
3239,
5029,
369,
1431,
11,
773,
582,
3278,
198,
197,
322,
1494,
364,
8385,
6,
438,
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... | 3 |
func TestCRMAddressesEndpoint_GetPrimary(t *testing.T) {
var want int64
n := &CRMAddresses{Timestamp: &want}
if got := n.GetPrimary(); !reflect.DeepEqual(*got, want) {
t.Errorf("CRMAddressesEndpoint.GetPrimary() failed, got: %v, want: %v", *got, want)
}
} | explode_data.jsonl/63530 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 103
} | [
2830,
3393,
43516,
52290,
27380,
13614,
15972,
1155,
353,
8840,
836,
8,
341,
2405,
1366,
526,
21,
19,
198,
9038,
1669,
609,
43516,
52290,
90,
20812,
25,
609,
52657,
630,
743,
2684,
1669,
308,
2234,
15972,
2129,
753,
34913,
94750,
4071,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCmp(t *testing.T) {
for i, tc := range cmpTests {
t.Run(fmt.Sprintf("%d", i), func(t *testing.T) {
is := errors.Is(tc.err, tc.target)
if is != tc.is {
t.Errorf("unexpected comparison, want=%t, got=%t", tc.is, is)
}
})
}
} | explode_data.jsonl/33540 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 125
} | [
2830,
3393,
34,
1307,
1155,
353,
8840,
836,
8,
341,
2023,
600,
11,
17130,
1669,
2088,
26089,
18200,
341,
197,
3244,
16708,
28197,
17305,
4430,
67,
497,
600,
701,
2915,
1155,
353,
8840,
836,
8,
341,
298,
19907,
1669,
5975,
4506,
44415,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestNewTokenResponse(t *testing.T) {
r := NewTokenResponse("foo", "bar", 1)
assert.Equal(t, "foo", r.TokenType)
assert.Equal(t, "bar", r.AccessToken)
assert.Equal(t, 1, r.ExpiresIn)
assert.Equal(t, map[string]string{
"token_type": "foo",
"access_token": "bar",
"expires_in": "1",
}, r.Map())
} | explode_data.jsonl/1726 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 141
} | [
2830,
3393,
3564,
3323,
2582,
1155,
353,
8840,
836,
8,
341,
7000,
1669,
1532,
3323,
2582,
445,
7975,
497,
330,
2257,
497,
220,
16,
340,
6948,
12808,
1155,
11,
330,
7975,
497,
435,
32277,
929,
340,
6948,
12808,
1155,
11,
330,
2257,
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 TestCACommon_GenerateRSACertificateRequestWithPass_Fail(t *testing.T) {
priData, errECC = ioutil.ReadFile(filepath.Join(pathcaeccpemp384, caPriKeyFileName))
if nil != errECC {
t.Error(errECC)
}
_, errCA = CAGenerateRSACertificateRequestWithPass(&CertRequest{
PrivateKeyData: priData,
Certifica... | explode_data.jsonl/24081 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 240
} | [
2830,
3393,
5049,
10839,
2646,
13220,
11451,
1706,
20962,
1900,
2354,
12187,
1400,
604,
1155,
353,
8840,
836,
8,
341,
3223,
461,
1043,
11,
1848,
36,
3706,
284,
43144,
78976,
34793,
22363,
5581,
924,
71325,
79,
3262,
18,
23,
19,
11,
21... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestTCPResetsSentNoICMP(t *testing.T) {
c := context.New(t, defaultMTU)
defer c.Cleanup()
stats := c.Stack().Stats()
// Send a SYN request for a closed port. This should elicit an RST
// but NOT an ICMPv4 DstUnreachable packet.
iss := seqnum.Value(context.TestInitialSequenceNumber)
c.SendPacket(nil, &conte... | explode_data.jsonl/75923 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 361
} | [
2830,
3393,
49896,
1061,
1415,
31358,
2753,
1317,
5781,
1155,
353,
8840,
836,
8,
341,
1444,
1669,
2266,
7121,
1155,
11,
1638,
8505,
52,
340,
16867,
272,
727,
60639,
741,
79659,
1669,
272,
58646,
1005,
16635,
2822,
197,
322,
11000,
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... | 3 |
func TestRolling_deployRolling(t *testing.T) {
latestConfig := appstest.OkDeploymentConfig(1)
latestConfig.Spec.Strategy = appstest.OkRollingStrategy()
latest, _ := appsinternalutil.MakeDeploymentV1(latestConfig)
config := appstest.OkDeploymentConfig(2)
config.Spec.Strategy = appstest.OkRollingStrategy()
deployme... | explode_data.jsonl/64615 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1128
} | [
2830,
3393,
32355,
287,
91890,
32355,
287,
1155,
353,
8840,
836,
8,
341,
197,
19350,
2648,
1669,
906,
267,
477,
54282,
75286,
2648,
7,
16,
340,
197,
19350,
2648,
36473,
27318,
10228,
284,
906,
267,
477,
54282,
32355,
287,
19816,
741,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestRegexpLinkMatchPrefix(t *testing.T) {
specs := []struct {
expectedMatch bool
path string
link string
}{
{true, "same", "same"},
{false, "same", "different"},
{true, "same/", "same/"},
{true, "same/", "same"},
{true, "same", "same/"},
{true, "same/", "same/xyz"},
}
for _... | explode_data.jsonl/30804 | {
"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,
3477,
4580,
3939,
8331,
14335,
1155,
353,
8840,
836,
8,
341,
98100,
82,
1669,
3056,
1235,
341,
197,
42400,
8331,
1807,
198,
197,
26781,
688,
914,
198,
197,
54238,
688,
914,
198,
197,
59403,
197,
197,
90,
1866,
11,
330,
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 TestEnvironmentInterpolation(t *testing.T) {
config, err := loadYAML(`
version: "3"
services:
test:
image: busybox
labels:
- home1=$HOME
- home2=${HOME}
- nonexistent=$NONEXISTENT
- default=${NONEXISTENT-default}
networks:
test:
driver: $HOME
volumes:
test:
driver: $H... | explode_data.jsonl/16391 | {
"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,
12723,
3306,
44686,
1155,
353,
8840,
836,
8,
341,
25873,
11,
1848,
1669,
2795,
56,
31102,
61528,
4366,
25,
330,
18,
698,
12779,
510,
220,
1273,
510,
262,
2168,
25,
13028,
2011,
198,
262,
9201,
510,
414,
481,
2114,
16,
31... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestSnapshotFailure(t *testing.T) {
storage := NewMemoryStorage()
sm := newTestRaft(1, []uint64{1, 2}, 10, 1, storage)
sm.restore(testingSnap)
sm.becomeCandidate()
sm.becomeLeader()
sm.prs[2].Next = 1
sm.prs[2].becomeSnapshot(11)
sm.Step(pb.Message{From: 2, To: 1, Type: pb.MsgSnapStatus, Reject: true})
... | explode_data.jsonl/12909 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 273
} | [
2830,
3393,
15009,
17507,
1155,
353,
8840,
836,
8,
341,
197,
16172,
1669,
1532,
10642,
5793,
741,
72023,
1669,
501,
2271,
55535,
723,
7,
16,
11,
3056,
2496,
21,
19,
90,
16,
11,
220,
17,
2137,
220,
16,
15,
11,
220,
16,
11,
5819,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSerializePktID(t *testing.T) {
testCasesSerialize := map[string]struct {
PktID epic.PktID
Serialized []byte
}{
"Basic": {
PktID: epic.PktID{
Timestamp: 1,
Counter: 0x02000003,
},
Serialized: []byte{0, 0, 0, 1, 2, 0, 0, 3},
},
"Max. timestamp": {
PktID: epic.PktID{
Tim... | explode_data.jsonl/16864 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 332
} | [
2830,
3393,
15680,
47,
5840,
915,
1155,
353,
8840,
836,
8,
341,
18185,
37302,
15680,
1669,
2415,
14032,
60,
1235,
341,
197,
10025,
5840,
915,
414,
24679,
1069,
5840,
915,
198,
197,
197,
77521,
3056,
3782,
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 TestKillContainer(t *testing.T) {
kubelet, _, fakeDocker := makeTestKubelet(t)
fakeDocker.containerList = []docker.APIContainers{
{
ID: "1234",
Names: []string{"/k8s--foo--qux--1234"},
},
{
ID: "5678",
Names: []string{"/k8s--bar--qux--5678"},
},
}
fakeDocker.container = &docker.Contai... | explode_data.jsonl/2826 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 231
} | [
2830,
3393,
53734,
4502,
1155,
353,
8840,
836,
8,
341,
16463,
3760,
1149,
11,
8358,
12418,
35,
13659,
1669,
1281,
2271,
42,
3760,
1149,
1155,
340,
1166,
726,
35,
13659,
18357,
852,
284,
3056,
28648,
24922,
74632,
515,
197,
197,
515,
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 TestCreateDuplicateMigrations(t *testing.T) {
defer resetTest()
createMigrationAndVerify(t, "createmigration", "default", "clusterpair1", []string{"namespace1"}, "", "")
cmdArgs := []string{"create", "migrations", "-c", "clusterpair1", "--namespaces", "namespace1", "createmigration"}
expected := "Error from s... | explode_data.jsonl/18258 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 149
} | [
2830,
3393,
4021,
53979,
44,
17824,
1155,
353,
8840,
836,
8,
341,
16867,
7585,
2271,
741,
39263,
20168,
3036,
32627,
1155,
11,
330,
837,
37246,
5033,
497,
330,
2258,
497,
330,
18855,
12670,
16,
497,
3056,
917,
4913,
2231,
16,
14345,
7... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestRunTLSServer(t *testing.T) {
cfg := initTest()
cfg.Core.SSL = true
cfg.Core.Port = "8087"
cfg.Core.CertPath = "../certificate/localhost.cert"
cfg.Core.KeyPath = "../certificate/localhost.key"
ctx, cancel := context.WithCancel(context.Background())
go func() {
assert.NoError(t, RunHTTPServer(ctx, cfg... | explode_data.jsonl/67601 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 212
} | [
2830,
3393,
6727,
13470,
1220,
2836,
1155,
353,
8840,
836,
8,
341,
50286,
1669,
2930,
2271,
2822,
50286,
12777,
808,
7984,
284,
830,
198,
50286,
12777,
43013,
284,
330,
23,
15,
23,
22,
698,
50286,
12777,
727,
529,
1820,
284,
7005,
635... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_Auto_HTML_Update_Redirect_Error(t *testing.T) {
r := require.New(t)
err := withHTMLFile("cars/edit.html", "Update: <%= car.Name %>", func(e *render.Engine) {
app := buffalo.New(buffalo.Options{})
app.PUT("/cars/{id}", func(c buffalo.Context) error {
b := Car{
ID: 1,
Name: "Honda",
}
... | explode_data.jsonl/2631 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 239
} | [
2830,
3393,
1566,
1535,
56726,
47393,
92940,
1226,
28651,
1155,
353,
8840,
836,
8,
341,
7000,
1669,
1373,
7121,
1155,
692,
9859,
1669,
448,
5835,
1703,
445,
50708,
21345,
2564,
497,
330,
4289,
25,
90194,
1803,
2967,
1018,
21156,
2915,
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 TestRuleHeadEquals(t *testing.T) {
assertHeadsEqual(t, &Head{}, &Head{})
// Same name/key/value
assertHeadsEqual(t, &Head{Name: Var("p")}, &Head{Name: Var("p")})
assertHeadsEqual(t, &Head{Key: VarTerm("x")}, &Head{Key: VarTerm("x")})
assertHeadsEqual(t, &Head{Value: VarTerm("x")}, &Head{Value: VarTerm("x")})... | explode_data.jsonl/65307 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 348
} | [
2830,
3393,
11337,
12346,
4315,
1155,
353,
8840,
836,
8,
341,
6948,
1519,
7664,
2993,
1155,
11,
609,
12346,
22655,
609,
12346,
6257,
692,
197,
322,
25739,
829,
68864,
57542,
198,
6948,
1519,
7664,
2993,
1155,
11,
609,
12346,
63121,
25,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func Test_GetAllTeams(t *testing.T) {
w := httptest.NewRecorder()
req, _ := http.NewRequest("GET", "/api/manager/teams", nil)
req.Header.Set("Authorization", managerToken)
router.ServeHTTP(w, req)
assert.Equal(t, 200, w.Code)
} | explode_data.jsonl/77158 | {
"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,
13614,
2403,
60669,
1155,
353,
8840,
836,
8,
341,
6692,
1669,
54320,
70334,
7121,
47023,
741,
24395,
11,
716,
1669,
1758,
75274,
445,
3806,
497,
3521,
2068,
14,
13297,
14,
38496,
497,
2092,
340,
24395,
15753,
4202,
445,
1812... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestBoundQueryInfo(t *testing.T) {
session := createSession(t)
defer session.Close()
if err := createTable(session, "CREATE TABLE gocql_test.clustered_query_info (id int, cluster int, value text, PRIMARY KEY (id, cluster))"); err != nil {
t.Fatalf("failed to create table with error '%v'", err)
}
write :=... | explode_data.jsonl/11155 | {
"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,
19568,
2859,
1731,
1155,
353,
8840,
836,
8,
1476,
25054,
1669,
1855,
5283,
1155,
340,
16867,
3797,
10421,
2822,
743,
1848,
1669,
1855,
2556,
16264,
11,
330,
22599,
14363,
342,
509,
1470,
4452,
40501,
291,
5738,
3109,
320,
30... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestMoment(t *testing.T) {
for i, test := range []struct {
x []float64
weights []float64
moment float64
ans float64
}{
{
x: []float64{6, 2, 4, 8, 10},
moment: 5,
ans: 0,
},
{
x: []float64{6, 2, 4, 8, 10},
weights: []float64{1, 2, 2, 2, 1},
moment: 5,
a... | explode_data.jsonl/1778 | {
"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,
83817,
1155,
353,
8840,
836,
8,
341,
2023,
600,
11,
1273,
1669,
2088,
3056,
1235,
341,
197,
10225,
981,
3056,
3649,
21,
19,
198,
197,
197,
13327,
3056,
3649,
21,
19,
198,
197,
2109,
12913,
220,
2224,
21,
19,
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 TestDefaultConfig(t *testing.T) {
err := LoadConf("default.config")
assert.Nil(t, err)
assert.Equal(t, conf, SetupConfig)
f, err := os.Open("default.config")
assert.Nil(t, err)
err = LoadConfData(f)
assert.Nil(t, err)
SetupConfig = Config{
Assets{"a/", "a/", "i/", "f/"},
Debug{"FILTER", "INFO"},
Scre... | explode_data.jsonl/13314 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 267
} | [
2830,
3393,
3675,
2648,
1155,
353,
8840,
836,
8,
341,
9859,
1669,
8893,
15578,
445,
2258,
5423,
1138,
6948,
59678,
1155,
11,
1848,
340,
6948,
12808,
1155,
11,
2335,
11,
18626,
2648,
340,
1166,
11,
1848,
1669,
2643,
12953,
445,
2258,
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 TestOpen(t *testing.T) {
path := tempfile()
defer os.RemoveAll(path)
db, err := bolt.Open(path, 0666, nil)
if err != nil {
t.Fatal(err)
} else if db == nil {
t.Fatal("expected db")
}
if s := db.Path(); s != path {
t.Fatalf("unexpected path: %s", s)
}
if err := db.Close(); err != nil {
t.Fatal(e... | explode_data.jsonl/27456 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 147
} | [
2830,
3393,
5002,
1155,
353,
8840,
836,
8,
341,
26781,
1669,
54819,
741,
16867,
2643,
84427,
5581,
692,
20939,
11,
1848,
1669,
31842,
12953,
5581,
11,
220,
15,
21,
21,
21,
11,
2092,
340,
743,
1848,
961,
2092,
341,
197,
3244,
26133,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestLookupFieldOrMethod(t *testing.T) {
// Test cases assume a lookup of the form a.f or x.f, where a stands for an
// addressable value, and x for a non-addressable value (even though a variable
// for ease of test case writing).
var tests = []struct {
src string
found bool
index []int
indi... | explode_data.jsonl/29387 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1475
} | [
2830,
3393,
34247,
1877,
2195,
3523,
1155,
353,
8840,
836,
8,
341,
197,
322,
3393,
5048,
9658,
264,
18615,
315,
279,
1352,
264,
833,
476,
856,
833,
11,
1380,
264,
13352,
369,
458,
198,
197,
322,
2621,
480,
897,
11,
323,
856,
369,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 Test_resolveDependencies(t *testing.T) {
g := gomega.NewGomegaWithT(t)
cached := NewAddonVersionCacheClient()
// Add core/A
cached.AddVersion(Version{
PackageSpec: addonmgrv1alpha1.PackageSpec{
PkgName: "core/A",
PkgVersion: "1.0.3",
PkgDeps: map[string]string{
"core/C": "*",
},
},
P... | explode_data.jsonl/2961 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 756
} | [
2830,
3393,
77291,
48303,
1155,
353,
8840,
836,
8,
341,
3174,
1669,
342,
32696,
7121,
38,
32696,
2354,
51,
1155,
692,
1444,
3854,
1669,
1532,
84312,
5637,
8233,
2959,
2822,
197,
322,
2691,
6200,
10360,
198,
1444,
3854,
1904,
5637,
7,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestMonitor_Open(t *testing.T) {
s := monitor.New(nil, monitor.Config{})
if err := s.Open(); err != nil {
t.Fatalf("unexpected open error: %s", err)
}
// Verify that opening twice is fine.
if err := s.Open(); err != nil {
s.Close()
t.Fatalf("unexpected error on second open: %s", err)
}
if err := s.C... | explode_data.jsonl/7521 | {
"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,
30098,
51747,
1155,
353,
8840,
836,
8,
341,
1903,
1669,
8718,
7121,
27907,
11,
8718,
10753,
37790,
743,
1848,
1669,
274,
12953,
2129,
1848,
961,
2092,
341,
197,
3244,
30762,
445,
53859,
1787,
1465,
25,
1018,
82,
497,
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... | 5 |
func TestGetMinimumDifference(t *testing.T) {
tests := []param{
{
[]int{1, tree.NULL, 4, 3, 5},
1,
},
{
[]int{1, tree.NULL, 3, 2},
1,
},
{
[]int{1, tree.NULL, 3, 3, 4},
0,
},
{
[]int{1, 0},
1,
},
{
[]int{1, tree.NULL, 3},
2,
},
{
[]int{236, 104, 701, tree.NULL, 22... | explode_data.jsonl/57471 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 386
} | [
2830,
3393,
1949,
28695,
62707,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
903,
515,
197,
197,
515,
298,
197,
1294,
396,
90,
16,
11,
4916,
90312,
11,
220,
19,
11,
220,
18,
11,
220,
20,
1583,
298,
197,
16,
345,
197,
197,
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... | 3 |
func TestCreateFullFleetAndCantGameServerAllocate(t *testing.T) {
t.Parallel()
fixtures := []apis.SchedulingStrategy{apis.Packed, apis.Distributed}
for _, strategy := range fixtures {
strategy := strategy
t.Run(string(strategy), func(t *testing.T) {
t.Parallel()
fleets := framework.AgonesClient.AgonesV... | explode_data.jsonl/63308 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 638
} | [
2830,
3393,
4021,
9432,
37,
18973,
3036,
34,
517,
4868,
5475,
75380,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
1166,
941,
18513,
1669,
3056,
13725,
808,
44356,
19816,
90,
13725,
1069,
11191,
11,
97723,
909,
25146,
630,
2023... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestResponseMarshalJSON_Notif(t *testing.T) {
tests := map[*jsonrpc2.Request]bool{
&jsonrpc2.Request{ID: jsonrpc2.ID{Num: 0}}: true,
&jsonrpc2.Request{ID: jsonrpc2.ID{Num: 1}}: true,
&jsonrpc2.Request{ID: jsonrpc2.ID{Str: "", IsString: true}}: true,
&jsonrpc2.Request{I... | explode_data.jsonl/50179 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 360
} | [
2830,
3393,
2582,
55438,
5370,
60816,
333,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
2415,
33836,
2236,
29414,
17,
9659,
96436,
515,
197,
197,
5,
2236,
29414,
17,
9659,
90,
915,
25,
2951,
29414,
17,
9910,
90,
4651,
25,
220,
15,
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... | 4 |
func TestNormalizeIndexCleaner(t *testing.T) {
trueVar := true
falseVar := false
days7 := 7
days55 := 55
tests := []struct {
underTest v1.JaegerEsIndexCleanerSpec
expected v1.JaegerEsIndexCleanerSpec
}{
{underTest: v1.JaegerEsIndexCleanerSpec{},
expected: v1.JaegerEsIndexCleanerSpec{Schedule: "55 23 * *... | explode_data.jsonl/21857 | {
"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,
87824,
1552,
27529,
261,
1155,
353,
8840,
836,
8,
341,
42808,
3962,
1669,
830,
198,
36012,
3962,
1669,
895,
198,
2698,
942,
22,
1669,
220,
22,
198,
2698,
942,
20,
20,
1669,
220,
20,
20,
198,
78216,
1669,
3056,
1235,
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... | 2 |
func TestSequenceGetStatus(t *testing.T) {
r := &Sequence{
Status: SequenceStatus{},
}
if got, want := r.GetStatus(), &r.Status.Status; got != want {
t.Errorf("GetStatus=%v, want=%v", got, want)
}
} | explode_data.jsonl/42756 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 85
} | [
2830,
3393,
14076,
1949,
2522,
1155,
353,
8840,
836,
8,
341,
7000,
1669,
609,
14076,
515,
197,
58321,
25,
28871,
2522,
38837,
197,
532,
743,
2684,
11,
1366,
1669,
435,
2234,
2522,
1507,
609,
81,
10538,
10538,
26,
2684,
961,
1366,
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
] | 2 |
func TestGetConfigForClient(t *testing.T) {
serverConfig := testConfig.Clone()
clientConfig := testConfig.Clone()
clientConfig.MinVersion = VersionTLS12
for i, test := range getConfigForClientTests {
if test.setup != nil {
test.setup(serverConfig)
}
var configReturned *Config
serverConfig.GetConfigForC... | explode_data.jsonl/36354 | {
"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,
1949,
2648,
2461,
2959,
1155,
353,
8840,
836,
8,
341,
41057,
2648,
1669,
1273,
2648,
64463,
741,
25291,
2648,
1669,
1273,
2648,
64463,
741,
25291,
2648,
17070,
5637,
284,
6079,
45439,
16,
17,
271,
2023,
600,
11,
1273,
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 Test_Max(t *testing.T) {
expected := 5
input := []int{1, 2, 3, 4, 5}
actual := slices.Max(input)
assert.Equal(t, expected, actual)
} | explode_data.jsonl/23109 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 59
} | [
2830,
3393,
58843,
1155,
353,
8840,
836,
8,
341,
42400,
1669,
220,
20,
271,
22427,
1669,
3056,
396,
90,
16,
11,
220,
17,
11,
220,
18,
11,
220,
19,
11,
220,
20,
532,
88814,
1669,
34254,
14535,
5384,
692,
6948,
12808,
1155,
11,
3601... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSSHPublicKey(t *testing.T) {
cases := []struct {
name string
key string
valid bool
}{
{
name: "valid",
key: "ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAklOUpkDHrfHY17SbrmTIpNLTGK9Tjom/BWDSUGPl+nafzlHDTYW7hdI4yZ5ew18JH4JW9jbhUFrviQzM7xlELEVf4h9lFX5QVkbPppSwg0cda3Pbv7kOdJ/MTyBlWXFCR+HAo3FXRitBqxiX... | explode_data.jsonl/56441 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1166
} | [
2830,
3393,
1220,
6610,
475,
1592,
1155,
353,
8840,
836,
8,
341,
1444,
2264,
1669,
3056,
1235,
341,
197,
11609,
220,
914,
198,
197,
23634,
256,
914,
198,
197,
56322,
1807,
198,
197,
59403,
197,
197,
515,
298,
11609,
25,
220,
330,
18... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestReplaceUnescaped(t *testing.T) {
defer leaktest.AfterTest(t)()
defer log.Scope(t).Close(t)
testCases := []struct {
pattern string
old string
new string
escapeToken string
expected string
}{
{``, `B`, `DEF`, `\`, ``},
{`ABC`, `B`, `DEF`, `\`, `ADEFC`},
{`A\BC`, `B`, `D... | explode_data.jsonl/24153 | {
"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,
23107,
1806,
65826,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
36892,
2271,
1155,
8,
741,
16867,
1487,
77940,
1155,
568,
7925,
1155,
340,
18185,
37302,
1669,
3056,
1235,
341,
197,
3223,
3227,
257,
914,
198,
197,
61828... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestUnmarshalArrayThatContainsObject(t *testing.T) {
data := "a:3:{i:0;O:7:\"struct1\":2:{s:3:\"foo\";i:10;s:3:\"baz\";s:3:\"yay\";}i:1;i:8;i:2;i:9;}"
var result []interface{}
err := phpserialize.Unmarshal([]byte(data), &result)
expectErrorToNotHaveOccurred(t, err)
expected := []interface{}{
map[interface{... | explode_data.jsonl/27031 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 253
} | [
2830,
3393,
1806,
27121,
1857,
4792,
23805,
1190,
1155,
353,
8840,
836,
8,
341,
8924,
1669,
330,
64,
25,
18,
12547,
72,
25,
15,
26,
46,
25,
22,
75035,
1235,
16,
11693,
17,
12547,
82,
25,
18,
75035,
7975,
2105,
26,
72,
25,
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... | 2 |
func TestEndpointsDiscoveryDeleteUnknownCacheState(t *testing.T) {
n, _, eps, _ := makeTestEndpointsDiscovery()
eps.GetStore().Add(makeEndpoints())
k8sDiscoveryTest{
discovery: n,
afterStart: func() { go func() { eps.Delete(cache.DeletedFinalStateUnknown{Obj: makeEndpoints()}) }() },
expectedRes: []*targetgr... | explode_data.jsonl/36699 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 156
} | [
2830,
3393,
80786,
67400,
6435,
13790,
8233,
1397,
1155,
353,
8840,
836,
8,
341,
9038,
11,
8358,
17986,
11,
716,
1669,
1281,
2271,
80786,
67400,
741,
197,
7124,
2234,
6093,
1005,
2212,
36944,
80786,
12367,
16463,
23,
82,
67400,
2271,
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... | 1 |
func TestNodeJoin(t *testing.T) {
defer leaktest.AfterTest(t)()
engineStopper := stop.NewStopper()
defer engineStopper.Stop(context.TODO())
e := engine.NewInMem(roachpb.Attributes{}, 1<<20)
engineStopper.AddCloser(e)
cfg := bootstrapNodeConfig()
if _, err := bootstrapCluster(
context.TODO(), cfg, []engine.Eng... | explode_data.jsonl/52654 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 862
} | [
2830,
3393,
1955,
12292,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
36892,
2271,
1155,
8,
741,
80118,
10674,
712,
1669,
2936,
7121,
10674,
712,
741,
16867,
4712,
10674,
712,
30213,
5378,
90988,
2398,
7727,
1669,
4712,
7121,
641,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestApplicationContext_PrototypeBean(t *testing.T) {
c, _ := container()
gs := &GreetingService{}
c.Object(gs)
s := &PrototypeBeanService{}
c.Object(s)
f := &PrototypeBeanFactory{}
c.Object(f)
c.Object(c)
err := c.Refresh()
assert.Nil(t, err)
s.Service("Li Lei")
time.Sleep(50 * time.Millisecond)
... | explode_data.jsonl/17398 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 171
} | [
2830,
3393,
19736,
1088,
4640,
4156,
10437,
1155,
353,
8840,
836,
8,
341,
1444,
11,
716,
1669,
5476,
2822,
3174,
82,
1669,
609,
38,
43632,
1860,
16094,
1444,
8348,
83394,
692,
1903,
1669,
609,
32906,
10437,
1860,
16094,
1444,
8348,
1141... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCatchUpClient_PullBlocksCancel(t *testing.T) {
lg, err := logger.New(&logger.Config{
Level: "info",
OutputPath: []string{"stdout"},
ErrOutputPath: []string{"stderr"},
Encoding: "console",
})
require.NoError(t, err)
mn := comm.RetryIntervalMin
mx := comm.RetryIntervalMax
comm.Retr... | explode_data.jsonl/70498 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 459
} | [
2830,
3393,
57760,
2324,
2959,
1088,
617,
29804,
9269,
1155,
353,
8840,
836,
8,
341,
8810,
70,
11,
1848,
1669,
5925,
7121,
2099,
9786,
10753,
515,
197,
197,
4449,
25,
260,
330,
2733,
756,
197,
80487,
1820,
25,
262,
3056,
917,
4913,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestChatSrvGetThreadNonblockSupersedes(t *testing.T) {
runWithMemberTypes(t, func(mt chat1.ConversationMembersType) {
ctc := makeChatTestContext(t, "GetThreadNonblockSupersedes", 1)
defer ctc.cleanup()
users := ctc.users()
uid := gregor1.UID(users[0].GetUID().ToBytes())
ui := kbtest.NewChatUI()
ctc.a... | explode_data.jsonl/63693 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 2363
} | [
2830,
3393,
15672,
50,
10553,
1949,
6855,
8121,
4574,
10048,
39919,
288,
1155,
353,
8840,
836,
8,
341,
56742,
2354,
9366,
4173,
1155,
11,
2915,
81618,
6236,
16,
4801,
22323,
24371,
929,
8,
341,
197,
89216,
66,
1669,
1281,
15672,
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... | 1 |
func TestGenerateSaveCoinKeyOverwriteFlag(t *testing.T) {
t.Parallel()
kb, err := keyring.New(t.Name(), "test", t.TempDir(), nil)
require.NoError(t, err)
keyname := "justakey"
addr1, _, err := server.GenerateSaveCoinKey(kb, keyname, false, hd.Secp256k1)
require.NoError(t, err)
// Test overwrite with overwrite... | explode_data.jsonl/54500 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 238
} | [
2830,
3393,
31115,
8784,
41180,
1592,
1918,
4934,
12135,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
16463,
65,
11,
1848,
1669,
1376,
12640,
7121,
1155,
2967,
1507,
330,
1944,
497,
259,
65009,
6184,
1507,
2092,
340,
17957,
35... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestAppLabels(t *testing.T) {
Given(t).
Path("config-map").
When().
CreateApp("-l", "foo=bar").
Then().
And(func(app *Application) {
assert.Contains(t, FailOnErr(RunCli("app", "list")), Name())
assert.Contains(t, FailOnErr(RunCli("app", "list", "-l", "foo=bar")), Name())
assert.NotContains(t, F... | explode_data.jsonl/35624 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 299
} | [
2830,
3393,
2164,
23674,
1155,
353,
8840,
836,
8,
341,
9600,
2071,
1155,
4292,
197,
69640,
445,
1676,
25858,
38609,
197,
197,
4498,
25829,
197,
75569,
2164,
13645,
75,
497,
330,
7975,
28,
2257,
38609,
197,
197,
12209,
25829,
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 |
func TestUndelay(t *testing.T) {
c := context.New(t, defaultMTU)
defer c.Cleanup()
c.CreateConnected(789, 30000, nil)
c.EP.SetSockOpt(tcpip.DelayOption(1))
allData := [][]byte{{0}, {1, 2, 3}}
for i, data := range allData {
view := buffer.NewViewFromBytes(data)
if _, _, err := c.EP.Write(tcpip.SlicePayload(... | explode_data.jsonl/22298 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 844
} | [
2830,
3393,
19957,
6895,
1155,
353,
8840,
836,
8,
341,
1444,
1669,
2266,
7121,
1155,
11,
1638,
8505,
52,
340,
16867,
272,
727,
60639,
2822,
1444,
7251,
21146,
7,
22,
23,
24,
11,
220,
18,
15,
15,
15,
15,
11,
2092,
692,
1444,
5142,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestIssue10213(t *testing.T) {
var src = `
var (
A = 1 // foo
)
var (
B = 2
// foo
)
var C = 3 // foo
var D = 4
// foo
func anycode() {
// foo
}
`
var s Scanner
s.Init(fset.AddFile("", fset.Base(), len(src)), []byte(src), nil, 0)
for {
pos, tok, lit := s.Scan()
class := to... | explode_data.jsonl/1844 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 258
} | [
2830,
3393,
42006,
16,
15,
17,
16,
18,
1155,
353,
8840,
836,
8,
341,
2405,
2286,
284,
22074,
197,
2405,
2399,
298,
22985,
284,
220,
16,
442,
15229,
198,
197,
197,
692,
197,
2405,
2399,
298,
12791,
284,
220,
17,
198,
298,
197,
322,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestDoGroupCreate_Success(t *testing.T) {
t.Parallel()
actionsClient := &mocks.ActionsClient{}
teamsClient := &mocks.TeamsClient{}
usersClient := &mocks.UsersClient{}
logger, _ := test.NewNullLogger()
manager := &Manager{
ActionsClient: actionsClient,
Config: &Config{},
CreateMaintainershipClie... | explode_data.jsonl/27799 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 602
} | [
2830,
3393,
5404,
2808,
4021,
87161,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
197,
4020,
2959,
1669,
609,
16712,
82,
72044,
2959,
16094,
197,
38496,
2959,
1669,
609,
16712,
82,
94849,
4122,
2959,
16094,
90896,
2959,
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 TestKubernetesPlugin(t *testing.T) {
RegisterFailHandler(Fail)
RunSpecsWithDefaultAndCustomReporters(t,
"Controller Suite",
[]Reporter{printer.NewlineReporter{}})
} | explode_data.jsonl/43028 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 63
} | [
2830,
3393,
42,
29827,
11546,
1155,
353,
8840,
836,
8,
341,
79096,
19524,
3050,
7832,
604,
692,
85952,
8327,
16056,
3675,
3036,
10268,
10361,
388,
1155,
345,
197,
197,
1,
2051,
20977,
756,
197,
197,
1294,
52766,
90,
62956,
7121,
1056,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPinGC(t *testing.T) {
chunkCount := 150
pinChunksCount := 50
dbCapacity := uint64(100)
var closed chan struct{}
testHookCollectGarbageChan := make(chan uint64)
t.Cleanup(setTestHookCollectGarbage(func(collectedCount uint64) {
// don't trigger if we haven't collected anything - this may
// result in ... | explode_data.jsonl/11630 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1162
} | [
2830,
3393,
19861,
22863,
1155,
353,
8840,
836,
8,
341,
23049,
3122,
2507,
1669,
220,
16,
20,
15,
198,
3223,
258,
89681,
2507,
1669,
220,
20,
15,
198,
20939,
29392,
1669,
2622,
21,
19,
7,
16,
15,
15,
692,
2405,
7877,
26023,
2036,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCharge(t *testing.T) {
c := ChargeCarrier{}
c.Charge(0.5)
if !testutils.FloatsAreEqual(c.currentCharge, 0.5) {
t.Errorf("Charged by 0.5, but have %v ChargeCarrier.", c.currentCharge)
}
} | explode_data.jsonl/66635 | {
"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,
55363,
1155,
353,
8840,
836,
8,
341,
1444,
1669,
36795,
96294,
16094,
1444,
6353,
2744,
7,
15,
13,
20,
692,
743,
753,
1944,
6031,
29794,
82,
11526,
2993,
1337,
4952,
55363,
11,
220,
15,
13,
20,
8,
341,
197,
3244,
13080,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestEngineProcessor_Stop(t *testing.T) {
sendCommandPoolMock := new(task.MockedPool)
cancelCommandPoolMock := new(task.MockedPool)
ctx := context.NewMockDefault()
resChan := make(chan contracts.DocumentResult)
processor := EngineProcessor{
sendCommandPool: sendCommandPoolMock,
cancelCommandPool: cancelC... | explode_data.jsonl/526 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 360
} | [
2830,
3393,
4571,
22946,
80308,
1155,
353,
8840,
836,
8,
341,
32817,
4062,
10551,
11571,
1669,
501,
17483,
24664,
291,
10551,
340,
84441,
4062,
10551,
11571,
1669,
501,
17483,
24664,
291,
10551,
340,
20985,
1669,
2266,
7121,
11571,
3675,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestStorageMemoryOnlyUsedWithAllInOneStrategy(t *testing.T) {
jaeger := &v1.Jaeger{
Spec: v1.JaegerSpec{
Strategy: v1.DeploymentStrategyProduction,
Storage: v1.JaegerStorageSpec{
Type: "memory",
},
},
}
For(context.TODO(), jaeger)
assert.Equal(t, v1.DeploymentStrategyAllInOne, jaeger.Spec.Stra... | explode_data.jsonl/21851 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 145
} | [
2830,
3393,
5793,
10642,
7308,
22743,
2354,
2403,
641,
3966,
19816,
1155,
353,
8840,
836,
8,
341,
197,
5580,
1878,
1669,
609,
85,
16,
3503,
64,
1878,
515,
197,
7568,
992,
25,
348,
16,
3503,
64,
1878,
8327,
515,
298,
197,
19816,
25,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestCRIPods(t *testing.T) {
tst := makeVirtletCRITester(t)
defer tst.teardown()
tst.listPodSandbox(nil)
tst.listContainers(nil)
sandboxes := criapi.GetSandboxes(2)
containers := criapi.GetContainersConfig(sandboxes)
tst.pullImage(cirrosImg())
tst.runPodSandbox(sandboxes[0])
tst.listPodSandbox(nil)
tst.p... | explode_data.jsonl/15663 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 690
} | [
2830,
3393,
8973,
3298,
29697,
1155,
353,
8840,
836,
8,
341,
3244,
267,
1669,
1281,
53,
2106,
1149,
8973,
952,
5191,
1155,
340,
16867,
71707,
31853,
37496,
741,
3244,
267,
6420,
23527,
50,
31536,
27907,
340,
3244,
267,
6420,
74632,
2790... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestRecordSetDeleteIntegration(t *testing.T) {
c := client()
zs, err := c.ZonesListAll(ListFilter{})
if err != nil {
t.Error(err)
}
z := zs[0].ID
rs, err := c.RecordSetsListAll(z, ListFilter{})
if err != nil {
t.Error(err)
}
var r string
for _, rec := range rs {
if rec.Name == "integration-test" ... | explode_data.jsonl/12126 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 195
} | [
2830,
3393,
6471,
1649,
6435,
52464,
1155,
353,
8840,
836,
8,
341,
1444,
1669,
2943,
741,
20832,
82,
11,
1848,
1669,
272,
13476,
3154,
852,
2403,
10278,
5632,
37790,
743,
1848,
961,
2092,
341,
197,
3244,
6141,
3964,
340,
197,
532,
208... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestProcessProposalGoodDial(t *testing.T) {
srv := &mocks.MockEndorserServer{}
addr := srv.Start(testAddress)
defer srv.Stop()
_, err := testProcessProposal(t, "grpc://"+addr)
if err != nil {
t.Fatalf("Process proposal failed (%s)", err)
}
} | explode_data.jsonl/45092 | {
"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,
7423,
98637,
15216,
35,
530,
1155,
353,
8840,
836,
8,
341,
1903,
10553,
1669,
609,
16712,
82,
24664,
3727,
269,
799,
5475,
16094,
53183,
1669,
43578,
12101,
8623,
4286,
340,
16867,
43578,
30213,
2822,
197,
6878,
1848,
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... | 2 |
func TestFilterServicePlans(t *testing.T) {
cases := []struct {
name string
requirements []string
accepted int
rejected int
catalog string
}{
{
name: "no restriction",
accepted: 2,
rejected: 0,
catalog: testCatalog,
},
{
name: "by external name",
re... | explode_data.jsonl/40490 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 765
} | [
2830,
3393,
5632,
1860,
97728,
1155,
353,
8840,
836,
8,
1476,
1444,
2264,
1669,
3056,
1235,
341,
197,
11609,
260,
914,
198,
197,
17957,
1368,
3056,
917,
198,
197,
197,
54574,
257,
526,
198,
197,
17200,
28303,
257,
526,
198,
197,
1444,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestNoCacheRequestExpiration(t *testing.T) {
resetTest()
respHeaders := http.Header{}
respHeaders.Set("Cache-Control", "max-age=7200")
reqHeaders := http.Header{}
reqHeaders.Set("Cache-Control", "no-cache")
if getFreshness(respHeaders, reqHeaders) != transparent {
t.Fatal("freshness isn't transparent")
}... | explode_data.jsonl/77628 | {
"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,
2753,
8233,
1900,
66301,
1155,
353,
8840,
836,
8,
341,
70343,
2271,
741,
34653,
10574,
1669,
1758,
15753,
16094,
34653,
10574,
4202,
445,
8233,
25056,
497,
330,
2810,
42941,
28,
22,
17,
15,
15,
5130,
24395,
10574,
1669,
1758... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestEdgeutilInterpolateOverLongEdge(t *testing.T) {
lng := math.Pi - 1e-2
a := Point{PointFromLatLng(LatLng{0, 0}).Normalize()}
b := Point{PointFromLatLng(LatLng{0, s1.Angle(lng)}).Normalize()}
for f := 0.4; f > 1e-15; f *= 0.1 {
// Test that interpolation is accurate on a long edge (but not so long that
... | explode_data.jsonl/74789 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 401
} | [
2830,
3393,
11656,
1314,
3306,
45429,
1918,
6583,
11656,
1155,
353,
8840,
836,
8,
341,
8810,
968,
1669,
6888,
1069,
72,
481,
220,
16,
68,
12,
17,
198,
11323,
1669,
5126,
90,
2609,
3830,
64922,
4957,
32738,
90,
15,
11,
220,
15,
16630... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
func TestGetFundingHistory(t *testing.T) {
t.Parallel()
if !areTestAPIKeysSet() {
t.Skip("API keys required but not set, skipping test")
}
_, err := f.GetFundingHistory(context.Background())
if err != nil {
t.Error(err)
}
} | explode_data.jsonl/15231 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 90
} | [
2830,
3393,
1949,
37,
37189,
13424,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
743,
753,
546,
2271,
7082,
8850,
1649,
368,
341,
197,
3244,
57776,
445,
7082,
6894,
2567,
714,
537,
738,
11,
42659,
1273,
1138,
197,
532,
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 TestDeviceTokenSucceedsWithIntermediateSlowDown(t *testing.T) {
sender := newDeviceTokenSender("slow_down")
_, err := WaitForUserCompletion(sender, deviceCode())
if err != nil {
t.Fatalf("unexpected error occurred")
}
} | explode_data.jsonl/27508 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 79
} | [
2830,
3393,
6985,
3323,
50,
29264,
16056,
98961,
58289,
4454,
1155,
353,
8840,
836,
8,
341,
1903,
1659,
1669,
501,
6985,
3323,
20381,
445,
35211,
13998,
5130,
197,
6878,
1848,
1669,
37601,
1474,
33190,
19377,
11,
3671,
2078,
2398,
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
] | 2 |
func TestCopyFile(t *testing.T) {
ctx := context.Background()
r := fstest.NewRun(t)
defer r.Finalise()
file1 := r.WriteFile("file1", "file1 contents", t1)
fstest.CheckItems(t, r.Flocal, file1)
file2 := file1
file2.Path = "sub/file2"
err := operations.CopyFile(ctx, r.Fremote, r.Flocal, file2.Path, file1.Path)... | explode_data.jsonl/51942 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 344
} | [
2830,
3393,
12106,
1703,
1155,
353,
8840,
836,
8,
341,
20985,
1669,
2266,
19047,
741,
7000,
1669,
48434,
477,
7121,
6727,
1155,
340,
16867,
435,
991,
977,
1064,
2822,
17661,
16,
1669,
435,
4073,
1703,
445,
1192,
16,
497,
330,
1192,
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 TestTerraformAzureVmExample(t *testing.T) {
t.Parallel()
subscriptionID := ""
uniquePostfix := random.UniqueId()
// Configure Terraform setting up a path to Terraform code.
terraformOptions := &terraform.Options{
// The path to where our Terraform code is located.
TerraformDir: "../../examples/azure/ter... | explode_data.jsonl/10743 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 353
} | [
2830,
3393,
51,
13886,
627,
78107,
88124,
13314,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
28624,
12124,
915,
1669,
8389,
197,
9587,
4133,
5743,
1669,
4194,
87443,
764,
2822,
197,
322,
22169,
49426,
627,
6243,
705,
264,
181... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestDatasources_Vault_DynamicAuth(t *testing.T) {
v := setupDatasourcesVaultTest(t)
err := v.vc.Sys().Mount("ssh/", &vaultapi.MountInput{Type: "ssh"})
require.NoError(t, err)
defer v.vc.Sys().Unmount("ssh")
_, err = v.vc.Logical().Write("ssh/roles/test", map[string]interface{}{
"key_type": "otp", "default... | explode_data.jsonl/57235 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 524
} | [
2830,
3393,
47663,
2360,
2334,
945,
1557,
5040,
5087,
1155,
353,
8840,
836,
8,
341,
5195,
1669,
6505,
47663,
2360,
79177,
2271,
1155,
692,
9859,
1669,
348,
3133,
66,
59418,
1005,
16284,
445,
25537,
28105,
609,
82983,
2068,
1321,
629,
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 TestWordCountWithAllCJKRunesHasCJKLanguage(t *testing.T) {
t.Parallel()
settings := map[string]interface{}{"hasCJKLanguage": true}
assertFunc := func(t *testing.T, ext string, pages page.Pages) {
p := pages[0]
if p.WordCount() != 15 {
t.Fatalf("[%s] incorrect word count, expected %v, got %v", ext, 15, p... | explode_data.jsonl/60623 | {
"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,
10879,
2507,
2354,
2403,
89349,
6727,
288,
10281,
89349,
13806,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
62930,
1669,
2415,
14032,
31344,
6257,
4913,
4648,
89349,
13806,
788,
830,
630,
6948,
9626,
1669,
2915,
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... | 2 |
func TestTempRand(t *testing.T) {
seed := time.Now().UnixNano()
r := rand.New(rand.NewSource(1527819448507607163))
n := r.Intn(10) + 5
m := r.Intn(50) + 1
edges := make([][]int, m)
for i := range edges {
s := r.Intn(n) + 1
t := r.Intn(n) + 1
c := r.Intn(1000)
edges[i] = []int{s, t, c}
}
temp(n, edges)
... | explode_data.jsonl/52287 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 205
} | [
2830,
3393,
12151,
56124,
1155,
353,
8840,
836,
8,
341,
197,
22602,
1669,
882,
13244,
1005,
55832,
83819,
741,
7000,
1669,
10382,
7121,
37595,
7121,
3608,
7,
16,
20,
17,
22,
23,
16,
24,
19,
19,
23,
20,
15,
22,
21,
15,
22,
16,
21... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestEvaluateCondition_False1(t *testing.T) {
condition := "services.database[1].name == \"postgres\""
result := EvaluateCondition(condition, templateData, varMap)
assert.False(t, result)
} | explode_data.jsonl/67927 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 63
} | [
2830,
3393,
82345,
10547,
1400,
710,
16,
1155,
353,
8840,
836,
8,
341,
197,
9056,
1669,
330,
12779,
15062,
58,
16,
936,
606,
621,
7245,
43070,
2105,
698,
9559,
1669,
54115,
10547,
47489,
11,
3811,
1043,
11,
762,
2227,
340,
6948,
50757... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestField_Unexported(t *testing.T) {
type (
Src struct {
Exported int
unexported string
}
Dst struct {
Exported int
unexported string
}
)
src := &Src{Exported: 1, unexported: "unexported"}
//
// To()
//
dst := &Dst{}
assert.Nil(t, Copy(src).To(dst))
assert.Equal(t, "", dst.unex... | explode_data.jsonl/13663 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 213
} | [
2830,
3393,
1877,
40687,
1533,
291,
1155,
353,
8840,
836,
8,
341,
13158,
2399,
197,
7568,
1287,
2036,
341,
298,
197,
16894,
291,
256,
526,
198,
298,
20479,
1533,
291,
914,
198,
197,
197,
630,
197,
10957,
267,
2036,
341,
298,
197,
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 TestReplayExtent(t *testing.T) {
extentName := "localtest.ext"
cases := []*pb.Block{
generateBlock(4096),
generateBlock(4096),
generateBlock(8192),
generateBlock(4096),
}
extent, err := CreateExtent(extentName, 100)
//extent.ResetWriter()
defer os.Remove(extentName)
assert.Nil(t, err)
extent.Lock... | explode_data.jsonl/14632 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 459
} | [
2830,
3393,
693,
1363,
49818,
1155,
353,
8840,
836,
8,
1476,
197,
70172,
675,
1669,
330,
2438,
1944,
9220,
698,
1444,
2264,
1669,
29838,
16650,
28477,
515,
197,
3174,
13220,
4713,
7,
19,
15,
24,
21,
1326,
197,
3174,
13220,
4713,
7,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestTransactionReal(t *testing.T) {
s := createRealSessionWithFixtures(t, nil)
defer testCloser(t, s)
tx, err := s.BeginTx(context.TODO(), nil)
assert.NoError(t, err)
s.RegisterByQueryBuilder(map[string]QueryBuilder{
"insert01": NewInsert("dml_people").AddColumns("name", "email"),
"selectID": NewSelect(... | explode_data.jsonl/11092 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 351
} | [
2830,
3393,
8070,
12768,
1155,
353,
8840,
836,
8,
341,
1903,
1669,
1855,
12768,
5283,
2354,
25958,
18513,
1155,
11,
2092,
340,
16867,
1273,
51236,
799,
1155,
11,
274,
692,
46237,
11,
1848,
1669,
274,
28467,
31584,
5378,
90988,
1507,
209... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestActivityService_GetThreadSubscription(t *testing.T) {
setup()
defer teardown()
mux.HandleFunc("/notifications/threads/1/subscription", func(w http.ResponseWriter, r *http.Request) {
testMethod(t, r, "GET")
fmt.Fprint(w, `{"subscribed":true}`)
})
sub, _, err := client.Activity.GetThreadSubscription("... | explode_data.jsonl/6721 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 216
} | [
2830,
3393,
4052,
1860,
13614,
6855,
33402,
1155,
353,
8840,
836,
8,
341,
84571,
741,
16867,
49304,
2822,
2109,
2200,
63623,
4283,
38188,
14,
27286,
14,
16,
14,
34404,
497,
2915,
3622,
1758,
37508,
11,
435,
353,
1254,
9659,
8,
341,
19... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestGlCanvas_FocusHandlingWhenActivatingOrDeactivatingTheMenu(t *testing.T) {
w := createWindow("Test")
w.SetPadded(false)
w.SetMainMenu(
fyne.NewMainMenu(
fyne.NewMenu("test", fyne.NewMenuItem("item", func() {})),
),
)
c := w.Canvas().(*glCanvas)
ce1 := &focusable{id: "ce1"}
ce2 := &focusable{id: "... | explode_data.jsonl/32520 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 571
} | [
2830,
3393,
31541,
18226,
1400,
3384,
38606,
4498,
23179,
1095,
2195,
1912,
8859,
1095,
785,
3514,
1155,
353,
8840,
836,
8,
341,
6692,
1669,
1855,
4267,
445,
2271,
1138,
6692,
4202,
47,
16828,
3576,
340,
6692,
4202,
86228,
1006,
197,
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 TestShouldUsersync(t *testing.T) {
doTest := func(gdprApplies string, consent string, allowBidderSync bool, allowHostCookies bool, expectAllow bool) {
t.Helper()
deps := auction{
cfg: nil,
syncers: nil,
gdprPerms: &auctionMockPermissions{
allowBidderSync: allowBidderSync,
allowHostCookie... | explode_data.jsonl/35893 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 359
} | [
2830,
3393,
14996,
7137,
1721,
1155,
353,
8840,
836,
8,
341,
19935,
2271,
1669,
2915,
3268,
67,
649,
10611,
7202,
914,
11,
14433,
914,
11,
2138,
65452,
1107,
12154,
1807,
11,
2138,
9296,
50672,
1807,
11,
1720,
18605,
1807,
8,
341,
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 TestClusterIPReject(t *testing.T) {
ipt := iptablestest.NewFake()
fp := NewFakeProxier(ipt)
svcName := "svc1"
svcIP := net.IPv4(10, 20, 30, 41)
svc := proxy.ServicePortName{NamespacedName: types.NamespacedName{Namespace: "ns1", Name: svcName}, Port: "80"}
fp.serviceMap[svc] = newFakeServiceInfo(svc, svcIP, ... | explode_data.jsonl/9292 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 361
} | [
2830,
3393,
28678,
3298,
78413,
1155,
353,
8840,
836,
8,
341,
8230,
417,
1669,
66068,
480,
267,
477,
7121,
52317,
741,
65219,
1669,
1532,
52317,
1336,
87,
1268,
1956,
417,
340,
1903,
7362,
675,
1669,
330,
58094,
16,
698,
1903,
7362,
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 TestValidateSecret(t *testing.T) {
g := gomega.NewGomegaWithT(t)
mgr, err := manager.New(cfg, manager.Options{MetricsBindAddress: "0"})
g.Expect(err).NotTo(gomega.HaveOccurred())
c = mgr.GetClient()
stopMgr, mgrStopped := StartTestManager(mgr, g)
defer func() {
close(stopMgr)
mgrStopped.Wait()
}()
... | explode_data.jsonl/59428 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 298
} | [
2830,
3393,
17926,
19773,
1155,
353,
8840,
836,
8,
341,
3174,
1669,
342,
32696,
7121,
38,
32696,
2354,
51,
1155,
692,
2109,
901,
11,
1848,
1669,
6645,
7121,
28272,
11,
6645,
22179,
90,
27328,
9950,
4286,
25,
330,
15,
23625,
3174,
8189... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestParseConfigGood(t *testing.T) {
c, err := ParseFile("../../../../test/fixture/config/server_good.conf", false)
require.NoError(t, err)
// Check for server configurations
assert.Equal(t, c.Server.BindAddress, "127.0.0.1")
assert.Equal(t, c.Server.BindPort, 8081)
assert.Equal(t, c.Server.RegistrationUDSPa... | explode_data.jsonl/51900 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 977
} | [
2830,
3393,
14463,
2648,
15216,
1155,
353,
8840,
836,
8,
341,
1444,
11,
1848,
1669,
14775,
1703,
36800,
2748,
1944,
14,
59612,
14730,
37255,
44781,
13937,
497,
895,
340,
17957,
35699,
1155,
11,
1848,
692,
197,
322,
4248,
369,
3538,
3238... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestGetAllTeamsSanitization(t *testing.T) {
th := Setup(t)
defer th.TearDown()
team, resp := th.Client.CreateTeam(&model.Team{
DisplayName: t.Name() + "_1",
Name: GenerateTestTeamName(),
Email: th.GenerateTestEmail(),
Type: model.TEAM_OPEN,
AllowedDomains: "simula... | explode_data.jsonl/70714 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 835
} | [
2830,
3393,
1949,
2403,
60669,
23729,
275,
2022,
1155,
353,
8840,
836,
8,
341,
70479,
1669,
18626,
1155,
340,
16867,
270,
836,
682,
4454,
2822,
197,
9196,
11,
9039,
1669,
270,
11716,
7251,
14597,
2099,
2528,
65842,
515,
197,
197,
26456,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestReconcilePropagateAnnotations(t *testing.T) {
names.TestingSeed()
ps := []*v1beta1.Pipeline{simpleHelloWorldPipeline}
prs := []*v1beta1.PipelineRun{{
ObjectMeta: metav1.ObjectMeta{
Name: "test-pipeline-run-with-annotations",
Namespace: "foo",
Annotations: map[string]string{"PipelineRunA... | explode_data.jsonl/27305 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 739
} | [
2830,
3393,
693,
40446,
457,
2008,
46836,
21418,
1155,
353,
8840,
836,
8,
341,
93940,
8787,
287,
41471,
2822,
35009,
1669,
29838,
85,
16,
19127,
16,
1069,
8790,
90,
22944,
9707,
10134,
34656,
532,
25653,
82,
1669,
29838,
85,
16,
19127,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestParsePkixPrivateKeyPem(t *testing.T) {
tcs := []struct {
name string
privateKey []byte
expectedError bool
}{
{
name: "parse rsa pkcs8 key successful",
privateKey: []byte(rsa2048PrivateKey),
expectedError: false,
}, {
name: "parse ecdsa pkcs8 key successf... | explode_data.jsonl/59156 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 539
} | [
2830,
3393,
14463,
58415,
941,
75981,
47,
336,
1155,
353,
8840,
836,
8,
341,
3244,
4837,
1669,
3056,
1235,
341,
197,
11609,
688,
914,
198,
197,
2455,
1592,
262,
3056,
3782,
198,
197,
42400,
1454,
1807,
198,
197,
59403,
197,
197,
515,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
func TestWorkerUpdate(t *testing.T) {
db, cleanup := storageTestEnv(t)
defer cleanup()
ctx := context.Background()
executor := &mockExecutor{t: t, dependencies: NewDependencyManager()}
worker := newWorker(db, executor, &testPublisherProvider{})
reporter := statusReporterFunc(func(ctx context.Context, taskID stri... | explode_data.jsonl/11419 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 3189
} | [
2830,
3393,
21936,
4289,
1155,
353,
8840,
836,
8,
341,
20939,
11,
21290,
1669,
5819,
2271,
14359,
1155,
340,
16867,
21290,
2822,
20985,
1669,
2266,
19047,
741,
67328,
4831,
1669,
609,
16712,
25255,
90,
83,
25,
259,
11,
19543,
25,
1532,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestOptionalValueFrom(t *testing.T) {
type args struct {
v *Value
}
tests := []struct {
name string
args args
want *OptionalValue
}{
{
name: "default type",
args: args{
v: ValueTypeString.ValueFrom("foo"),
},
want: &OptionalValue{ov: *value.NewOptional(value.TypeString, value.TypeStri... | explode_data.jsonl/8888 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 315
} | [
2830,
3393,
15309,
1130,
3830,
1155,
353,
8840,
836,
8,
341,
13158,
2827,
2036,
341,
197,
5195,
353,
1130,
198,
197,
532,
78216,
1669,
3056,
1235,
341,
197,
11609,
914,
198,
197,
31215,
2827,
198,
197,
50780,
353,
15309,
1130,
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... | 1 |
func TestGetServiceLogs(t *testing.T) {
handler := func(w http.ResponseWriter, r *http.Request) {
testutils.AssertEqual(t, r.Method, "GET")
testutils.AssertEqual(t, r.URL.Path, "/service/id/logs")
testutils.AssertEqual(t, r.URL.Query().Get("tail"), "100")
testutils.AssertEqual(t, r.URL.Query().Get("start"), "2... | explode_data.jsonl/24181 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 373
} | [
2830,
3393,
1949,
1860,
51053,
1155,
353,
8840,
836,
8,
341,
53326,
1669,
2915,
3622,
1758,
37508,
11,
435,
353,
1254,
9659,
8,
341,
197,
18185,
6031,
11711,
2993,
1155,
11,
435,
20798,
11,
330,
3806,
1138,
197,
18185,
6031,
11711,
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... | 1 |
func TestInsertLedger(t *testing.T) {
tt := test.Start(t)
defer tt.Finish()
test.ResetHorizonDB(t, tt.HorizonDB)
q := &Q{tt.HorizonSession()}
expectedLedger := Ledger{
Sequence: 69859,
LedgerHash: "4db1e4f145e9ee75162040d26284795e0697e2e84084624e7c6c723ebbf80118",
PreviousL... | explode_data.jsonl/31527 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1428
} | [
2830,
3393,
13780,
60850,
1389,
1155,
353,
8840,
836,
8,
341,
3244,
83,
1669,
1273,
12101,
1155,
340,
16867,
17853,
991,
18176,
741,
18185,
36660,
39601,
16973,
3506,
1155,
11,
17853,
3839,
269,
16973,
3506,
340,
18534,
1669,
609,
48,
9... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestDatabaseSettings(t *testing.T) {
t.Parallel()
Convey("New: ok", t, func() {
s := New(context.Background())
So(s, ShouldNotBeNil)
So(s.Server, ShouldEqual, "")
So(s.Username, ShouldEqual, "")
So(s.Password, ShouldEqual, "")
})
Convey("GetUncached: returns defaults", t, func() {
s, e := GetUnca... | explode_data.jsonl/72094 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 433
} | [
2830,
3393,
5988,
6086,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
93070,
5617,
445,
3564,
25,
5394,
497,
259,
11,
2915,
368,
341,
197,
1903,
1669,
1532,
5378,
19047,
2398,
197,
76912,
1141,
11,
12260,
2623,
3430,
19064,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestPath(t *testing.T) {
expected := []string{"1", "2", "3", "4", "5"}
join := filepath.Join(expected...)
result := PathToArray(join)
if !lang.EqualArrays(result, expected) {
t.Errorf("expected %v result %v", expected, result)
}
} | explode_data.jsonl/7248 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 93
} | [
2830,
3393,
1820,
1155,
353,
8840,
836,
8,
341,
42400,
1669,
3056,
917,
4913,
16,
497,
330,
17,
497,
330,
18,
497,
330,
19,
497,
330,
20,
16707,
197,
5987,
1669,
26054,
22363,
15253,
31218,
9559,
1669,
7933,
29512,
60715,
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... | 2 |
func TestIntegrationClose(t *testing.T) {
queueName, _, cleanup := newTestQueue(t, "close")
defer cleanup()
label := "link"
t.Run(label, func(t *testing.T) {
checkLeaks := leaktest.CheckTimeout(t, 60*time.Second)
// Create client
client := newClient(t, label)
defer client.Close()
// Open a session
se... | explode_data.jsonl/60649 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1017
} | [
2830,
3393,
52464,
7925,
1155,
353,
8840,
836,
8,
341,
46993,
675,
11,
8358,
21290,
1669,
501,
2271,
7554,
1155,
11,
330,
5552,
1138,
16867,
21290,
2822,
29277,
1669,
330,
2080,
698,
3244,
16708,
13345,
11,
2915,
1155,
353,
8840,
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... | 2 |
func TestNXDomainJob(t *testing.T) {
host := "notadomainatallforsure.notadomain.notatldreally"
port := uint16(1234)
event := testTCPCheck(t, host, port)
dialErr := fmt.Sprintf("lookup %s", host)
testslike.Test(
t,
lookslike.Strict(lookslike.Compose(
hbtest.BaseChecks("", "down", "tcp"),
hbtest.SummaryCh... | explode_data.jsonl/54641 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 208
} | [
2830,
3393,
43304,
13636,
12245,
1155,
353,
8840,
836,
8,
341,
63104,
1669,
330,
1921,
329,
3121,
266,
541,
69,
1087,
552,
11971,
329,
3121,
11971,
266,
507,
53660,
698,
52257,
1669,
2622,
16,
21,
7,
16,
17,
18,
19,
340,
28302,
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 TestIntArray_FilterEmpty(t *testing.T) {
gtest.C(t, func(t *gtest.T) {
array := garray.NewIntArrayFrom(g.SliceInt{0, 1, 2, 3, 4, 0})
t.Assert(array.FilterEmpty(), g.SliceInt{1, 2, 3, 4})
})
gtest.C(t, func(t *gtest.T) {
array := garray.NewIntArrayFrom(g.SliceInt{1, 2, 3, 4})
t.Assert(array.FilterEmpty()... | explode_data.jsonl/47631 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 173
} | [
2830,
3393,
95338,
68935,
3522,
1155,
353,
8840,
836,
8,
341,
3174,
1944,
727,
1155,
11,
2915,
1155,
353,
82038,
836,
8,
341,
197,
11923,
1669,
342,
1653,
7121,
95338,
3830,
3268,
95495,
1072,
90,
15,
11,
220,
16,
11,
220,
17,
11,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestGetConsulServiceDetail(t *testing.T) {
ctrl := gomock.NewController(assert.Tracing(t))
defer ctrl.Finish()
catalog := newMockCatalogInterface(ctrl)
svcname := "test-svc"
svctag := ""
svcs := []*consulapi.CatalogService{
{Node: "nodeid", Address: "bob", ServicePort: 3},
}
catalog.EXPECT().Service(s... | explode_data.jsonl/71899 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 210
} | [
2830,
3393,
1949,
15220,
360,
1860,
10649,
1155,
353,
8840,
836,
8,
341,
84381,
1669,
342,
316,
1176,
7121,
2051,
75846,
8240,
4527,
1155,
1171,
16867,
23743,
991,
18176,
2822,
1444,
7750,
1669,
501,
11571,
41606,
5051,
62100,
340,
1903,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAddVariadicRandomly(t *testing.T) {
t.Parallel()
rand.Seed(time.Now().UnixNano())
// rand.Float64() returns a number in 0.0-1.0
// Use another randomly-generated int to vary the whole number.
a := rand.Float64() * float64(rand.Intn(500))
b := rand.Float64() * float64(rand.Intn(500))
// v will be assign... | explode_data.jsonl/12259 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 295
} | [
2830,
3393,
2212,
56135,
36214,
13999,
398,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
7000,
437,
5732,
291,
9730,
13244,
1005,
55832,
83819,
12367,
197,
322,
10382,
29794,
21,
19,
368,
4675,
264,
1372,
304,
220,
15,
13,
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... | 3 |
func TestArray(t *testing.T) {
testStr := `<?
$var = array("one", "two", "three");`
p := NewParser()
p.disableScoping = true
p.Debug = true
a, _ := p.Parse("test.php", testStr)
if len(a.Nodes) == 0 {
t.Fatalf("Array did not correctly parse")
}
tree := ast.ExprStmt{
Expr: ast.AssignmentExpr{
Assignee: a... | explode_data.jsonl/28437 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 393
} | [
2830,
3393,
1857,
1155,
353,
8840,
836,
8,
341,
18185,
2580,
1669,
1565,
53075,
220,
400,
947,
284,
1334,
445,
603,
497,
330,
19789,
497,
330,
27856,
5038,
3989,
3223,
1669,
1532,
6570,
741,
3223,
42628,
3326,
33707,
284,
830,
198,
32... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAuthorization(t *testing.T) {
config := ensureIntegrationEnvironment(t)
podName := os.Getenv("AKV2K8S_K8S_TEST_POD")
podNamespace := os.Getenv("AKV2K8S_K8S_TEST_NAMESPACE")
podIP := os.Getenv("AKV2K8S_K8S_TEST_POD_IP")
cfg, err := clientcmd.BuildConfigFromFlags(config.master, config.config)
if err != n... | explode_data.jsonl/46382 | {
"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,
18124,
1155,
353,
8840,
836,
8,
341,
25873,
1669,
5978,
52464,
12723,
1155,
692,
3223,
347,
675,
1669,
2643,
64883,
445,
11907,
53,
17,
42,
23,
50,
10102,
23,
50,
11641,
1088,
2069,
1138,
3223,
347,
22699,
1669,
2643,
6488... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestClientGetVcsRootMissing(t *testing.T) {
client, err := NewRealTestClient(t)
require.NoError(t, err, "Expected no error")
config, err := client.GetVcsRoot("Empty_")
require.NoError(t, err, "Expected no error")
require.Nil(t, config, "Expected no config")
} | explode_data.jsonl/36874 | {
"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,
2959,
1949,
53,
4837,
8439,
25080,
1155,
353,
8840,
836,
8,
341,
25291,
11,
1848,
1669,
1532,
12768,
2271,
2959,
1155,
340,
17957,
35699,
1155,
11,
1848,
11,
330,
18896,
902,
1465,
5130,
25873,
11,
1848,
1669,
2943,
2234,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestGetAddress(t *testing.T) {
n := New("testgetaddress", lookupFunc)
// Get an address from an empty set (should error)
if rv := n.GetAddress(); rv != nil {
t.Errorf("GetAddress failed: got: %v want: %v\n", rv, nil)
}
// Add a new address and get it
err := n.addAddressByIP(someIP + ":8333")
if err != n... | explode_data.jsonl/26482 | {
"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,
1949,
4286,
1155,
353,
8840,
836,
8,
341,
9038,
1669,
1532,
445,
1944,
455,
4995,
497,
18615,
9626,
692,
197,
322,
2126,
458,
2621,
504,
458,
4287,
738,
320,
5445,
1465,
340,
743,
17570,
1669,
308,
2234,
4286,
2129,
17570,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestInitializeConnection(t *testing.T) {
th.SetupHTTP()
defer th.TeardownHTTP()
MockInitializeConnectionResponse(t)
options := &volumeactions.InitializeConnectionOpts{
IP: "127.0.0.1",
Host: "stack",
Initiator: "iqn.1994-05.com.redhat:17cf566367d2",
Multipath: gophercloud.Disabled,
Plat... | explode_data.jsonl/20630 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 221
} | [
2830,
3393,
9928,
4526,
1155,
353,
8840,
836,
8,
341,
70479,
39820,
9230,
741,
16867,
270,
94849,
37496,
9230,
2822,
9209,
1176,
9928,
4526,
2582,
1155,
692,
35500,
1669,
609,
25060,
4020,
45829,
4526,
43451,
515,
197,
197,
3298,
25,
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 TestInstrumentationLibrarySpans_SchemaUrl(t *testing.T) {
ms := NewInstrumentationLibrarySpans()
assert.EqualValues(t, "", ms.SchemaUrl())
testValSchemaUrl := "https://opentelemetry.io/schemas/1.5.0"
ms.SetSchemaUrl(testValSchemaUrl)
assert.EqualValues(t, testValSchemaUrl, ms.SchemaUrl())
} | explode_data.jsonl/63254 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 117
} | [
2830,
3393,
56324,
367,
16915,
6406,
596,
1098,
3416,
2864,
1155,
353,
8840,
836,
8,
341,
47691,
1669,
1532,
56324,
367,
16915,
6406,
596,
741,
6948,
12808,
6227,
1155,
11,
7342,
9829,
21105,
2864,
2398,
18185,
2208,
8632,
2864,
1669,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestStackUnderflow(t *testing.T) {
patch := sointu.Patch{sointu.Instrument{NumVoices: 1, Units: []sointu.Unit{
sointu.Unit{Type: "pop", Parameters: map[string]int{}},
}}}
synth, err := vm.Synth(patch)
if err != nil {
t.Fatalf("bridge compile error: %v", err)
}
buffer := make([]float32, 2)
err = sointu.R... | explode_data.jsonl/39022 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 171
} | [
2830,
3393,
4336,
16250,
4965,
1155,
353,
8840,
836,
8,
341,
3223,
754,
1669,
773,
396,
84,
1069,
754,
90,
704,
396,
84,
5337,
19474,
90,
4651,
27515,
1216,
25,
220,
16,
11,
35181,
25,
3056,
704,
396,
84,
25159,
515,
197,
197,
704... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestDealTwinAdd(t *testing.T) {
optionTrue := true
str := typeString
doc := make(map[string]*dttype.TwinDoc)
doc[key1] = &dttype.TwinDoc{}
sync := make(map[string]*dttype.MsgTwin)
sync[key1] = &dttype.MsgTwin{}
result := make(map[string]*dttype.MsgTwin)
result[key1] = &dttype.MsgTwin{}
twinDelete := make... | explode_data.jsonl/30642 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 2763
} | [
2830,
3393,
72841,
51,
7526,
2212,
1155,
353,
8840,
836,
8,
341,
80845,
2514,
1669,
830,
198,
11355,
1669,
943,
703,
198,
59536,
1669,
1281,
9147,
14032,
8465,
8047,
1313,
836,
7526,
9550,
340,
59536,
8157,
16,
60,
284,
609,
8047,
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... | 2 |
func TestPageBundlerSiteWitSymbolicLinksInContent(t *testing.T) {
if runtime.GOOS == "windows" && os.Getenv("CI") == "" {
t.Skip("Skip TestPageBundlerSiteWitSymbolicLinksInContent as os.Symlink needs administrator rights on Windows")
}
assert := require.New(t)
ps, clean, workDir := newTestBundleSymbolicSources(t... | explode_data.jsonl/68129 | {
"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,
2665,
33,
85365,
17597,
54,
275,
15090,
292,
24089,
641,
2762,
1155,
353,
8840,
836,
8,
341,
743,
15592,
97574,
3126,
621,
330,
27077,
1,
1009,
2643,
64883,
445,
11237,
899,
621,
1591,
341,
197,
3244,
57776,
445,
35134,
33... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestGrpcRegisterGameServer(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.RegisterGameServerRequest{
U... | explode_data.jsonl/40912 | {
"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,
6464,
3992,
8690,
4868,
5475,
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,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestGrossAmountRemittanceAmountValid(t *testing.T) {
gard := mockGrossAmountRemittanceDocument()
gard.RemittanceAmount.Amount = "X,"
require.EqualError(t, gard.Validate(), fieldError("Amount", ErrNonAmount, gard.RemittanceAmount.Amount).Error())
} | explode_data.jsonl/41407 | {
"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,
38,
2128,
10093,
6590,
87191,
10093,
4088,
1155,
353,
8840,
836,
8,
341,
3174,
567,
1669,
7860,
38,
2128,
10093,
6590,
87191,
7524,
741,
3174,
567,
11398,
87191,
10093,
62192,
284,
330,
55,
1335,
271,
17957,
12808,
1454,
115... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
func TestScaleUpAndDownInParallelStressTest(t *testing.T) {
t.Parallel()
alpha1 := framework.AgonesClient.StableV1alpha1()
fleetCount := 2
fleetSize := int32(10)
repeatCount := 3
deadline := time.Now().Add(1 * time.Minute)
logrus.WithField("fleetCount", fleetCount).
WithField("fleetSize", fleetSize).
WithF... | explode_data.jsonl/9442 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 935
} | [
2830,
3393,
6947,
2324,
3036,
4454,
641,
16547,
623,
673,
2271,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
73063,
16,
1669,
12626,
49850,
3154,
2959,
7758,
480,
53,
16,
7141,
16,
741,
1166,
18973,
2507,
1669,
220,
17,
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 TestRuntimeReqBeforeHook(t *testing.T) {
modules := map[string]string{
"test": `
local nakama = require("nakama")
function before_storage_write(ctx, payload)
return payload
end
nakama.register_req_before(before_storage_write, "WriteStorageObjects")`,
}
runtime, err := runtimeWithModules(t, modules)
if err ... | explode_data.jsonl/59796 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 351
} | [
2830,
3393,
15123,
27234,
10227,
31679,
1155,
353,
8840,
836,
8,
341,
42228,
2425,
1669,
2415,
14032,
30953,
515,
197,
197,
1,
1944,
788,
22074,
2438,
40886,
3029,
284,
1373,
445,
42874,
3029,
1138,
1688,
1573,
23310,
9165,
7502,
11,
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... | 4 |
func TestNextManyOfAddRangeAcrossContainers(t *testing.T) {
rb := NewBitmap()
rb.AddRange(65530, 65540)
expectedCard := 10
expected := []uint64{65530, 65531, 65532, 65533, 65534, 65535, 65536, 65537, 65538, 65539, 0}
// test where all values can be returned in a single buffer
it := rb.ManyIterator()
buf := make... | explode_data.jsonl/20344 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 303
} | [
2830,
3393,
5847,
8441,
2124,
2212,
6046,
91931,
74632,
1155,
353,
8840,
836,
8,
341,
85589,
1669,
1532,
16773,
741,
85589,
19672,
7,
21,
20,
20,
18,
15,
11,
220,
21,
20,
20,
19,
15,
340,
42400,
5770,
1669,
220,
16,
15,
198,
42400... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.