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 TestTeamsService_DeleteTeamBySlug(t *testing.T) {
client, mux, _, teardown := setup()
defer teardown()
mux.HandleFunc("/orgs/o/teams/s", func(w http.ResponseWriter, r *http.Request) {
testMethod(t, r, "DELETE")
})
ctx := context.Background()
_, err := client.Teams.DeleteTeamBySlug(ctx, "o", "s")
if err ... | explode_data.jsonl/4521 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 279
} | [
2830,
3393,
60669,
1860,
57418,
14597,
1359,
54968,
1155,
353,
8840,
836,
8,
341,
25291,
11,
59807,
11,
8358,
49304,
1669,
6505,
741,
16867,
49304,
2822,
2109,
2200,
63623,
4283,
1775,
82,
20271,
14,
38496,
2687,
497,
2915,
3622,
1758,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestOperatorRestartHostNetwork(t *testing.T) {
namespace := "ns"
context := newTestStartCluster(namespace)
c := newCluster(context, namespace, false, v1.ResourceRequirements{})
c.clusterInfo = test.CreateConfigDir(1)
// start a basic cluster
err := c.Start()
assert.Nil(t, err)
validateStart(t, c)
c = n... | explode_data.jsonl/39527 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 180
} | [
2830,
3393,
18461,
59354,
9296,
12320,
1155,
353,
8840,
836,
8,
341,
56623,
1669,
330,
4412,
698,
28413,
1669,
501,
2271,
3479,
28678,
52397,
340,
1444,
1669,
501,
28678,
5378,
11,
4473,
11,
895,
11,
348,
16,
20766,
59202,
37790,
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... | 1 |
func TestGetChannelStateChannelIdIncorrectSignature(t *testing.T) {
reply, err := stateServiceTest.service.GetChannelState(
nil,
&ChannelStateRequest{
ChannelId: bigIntToBytes(stateServiceTest.defaultChannelId),
Signature: []byte{0x00},
},
)
assert.Equal(t, errors.New("incorrect signature"), err)
asser... | explode_data.jsonl/6073 | {
"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,
1949,
9629,
1397,
9629,
764,
40468,
25088,
1155,
353,
8840,
836,
8,
341,
86149,
11,
1848,
1669,
1584,
1860,
2271,
5736,
2234,
9629,
1397,
1006,
197,
84131,
345,
197,
197,
5,
9629,
1397,
1900,
515,
298,
197,
9629,
764,
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 TestBindRequest_BodyValidation(t *testing.T) {
spec, api := petstore.NewAPI(t)
ctx := NewContext(spec, api, nil)
api.DefaultConsumes = runtime.JSONMime
ctx.router = DefaultRouter(spec, ctx.api)
req, err := http.NewRequest("GET", path.Join(spec.BasePath(), "/pets"), new(eofReader))
if assert.NoError(t, err) ... | explode_data.jsonl/19158 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 322
} | [
2830,
3393,
9950,
1900,
1668,
1076,
13799,
1155,
353,
8840,
836,
8,
341,
98100,
11,
6330,
1669,
6753,
4314,
7121,
7082,
1155,
340,
20985,
1669,
1532,
1972,
38209,
11,
6330,
11,
2092,
340,
54299,
13275,
41966,
288,
284,
15592,
18009,
44,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestValidateChecksum(t *testing.T) {
//goland:noinspection GoImportUsedAsName
assert := assert.New(t)
for _, tt := range tests {
data := append(tt.data, 0, 0)
binary.LittleEndian.PutUint16(data[len(data)-2:], tt.expectedCrc)
assert.True(ValidateChecksum(data))
... | explode_data.jsonl/37606 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 284
} | [
2830,
3393,
17926,
73190,
1155,
353,
8840,
836,
8,
341,
262,
442,
70,
96440,
66479,
53395,
5994,
11511,
22743,
2121,
675,
198,
262,
2060,
1669,
2060,
7121,
1155,
340,
1066,
262,
369,
8358,
17853,
1669,
2088,
7032,
341,
286,
821,
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 TestFStatelessNatsServer(t *testing.T) {
s := runServer(nil)
defer s.Shutdown()
conn, err := nats.Connect(fmt.Sprintf("nats://localhost:%d", defaultOptions.Port))
if err != nil {
t.Fatal(err)
}
processor := &processor{t}
protoFactory := NewFProtocolFactory(thrift.NewTBinaryProtocolFactoryDefault())
serve... | explode_data.jsonl/29847 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 430
} | [
2830,
3393,
37,
1397,
1717,
45,
1862,
5475,
1155,
353,
8840,
836,
8,
341,
1903,
1669,
1598,
5475,
27907,
340,
16867,
274,
10849,
18452,
741,
32917,
11,
1848,
1669,
308,
1862,
43851,
28197,
17305,
445,
77,
1862,
1110,
8301,
7533,
67,
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 TestAuthorizationEndpointDiscovery(t *testing.T) {
mux := http.NewServeMux()
var serverURL string
mux.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
// From the spec (https://www.w3.org/TR/indieauth/#x4-1-discovery-by-clients):
// >>> the first HTTP Link header takes precedence, followed by ... | explode_data.jsonl/7018 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 342
} | [
2830,
3393,
18124,
27380,
67400,
1155,
353,
8840,
836,
8,
341,
2109,
2200,
1669,
1758,
7121,
60421,
44,
2200,
741,
2405,
3538,
3144,
914,
198,
2109,
2200,
63623,
35460,
2915,
3622,
1758,
37508,
11,
435,
353,
1254,
9659,
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,
1... | 1 |
func TestMongo_Last(t *testing.T) {
m, skip := prepMongo(t, true) // adds two comments
if skip {
return
}
res, err := m.Last("radio-t", 0)
assert.Nil(t, err)
assert.Equal(t, 2, len(res))
assert.Equal(t, "some text2", res[0].Text)
res, err = m.Last("radio-t", 1)
assert.Nil(t, err)
assert.Equal(t, 1, len(res... | explode_data.jsonl/54197 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 170
} | [
2830,
3393,
54998,
84672,
1155,
353,
8840,
836,
8,
341,
2109,
11,
10706,
1669,
21327,
54998,
1155,
11,
830,
8,
442,
11367,
1378,
6042,
198,
743,
10706,
341,
197,
853,
198,
197,
532,
10202,
11,
1848,
1669,
296,
24682,
445,
12636,
2385,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPushImages(t *testing.T) {
var privateImgs = map[string]Config{
"test": Config{
name: "test1",
registry: "private.io/sonobuoy",
version: "x.y",
},
}
tests := map[string]struct {
client docker.Docker
privateImgs map[string]Config
wantErrorCount int
}{
"simple": {
cli... | explode_data.jsonl/61546 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 580
} | [
2830,
3393,
16644,
14228,
1155,
353,
8840,
836,
8,
341,
2405,
869,
1427,
5857,
284,
2415,
14032,
60,
2648,
515,
197,
197,
1,
1944,
788,
5532,
515,
298,
11609,
25,
257,
330,
1944,
16,
756,
298,
197,
29172,
25,
330,
1996,
4245,
14,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestChanOfGC(t *testing.T) {
done := make(chan bool, 1)
go func() {
select {
case <-done:
case <-time.After(5 * time.Second):
panic("deadlock in TestChanOfGC")
}
}()
defer func() {
done <- true
}()
type T *uintptr
tt := TypeOf(T(nil))
ct := ChanOf(BothDir, tt)
// NOTE: The garbage collecto... | explode_data.jsonl/29610 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 461
} | [
2830,
3393,
46019,
2124,
22863,
1155,
353,
8840,
836,
8,
341,
40495,
1669,
1281,
35190,
1807,
11,
220,
16,
340,
30680,
2915,
368,
341,
197,
38010,
341,
197,
2722,
9119,
10438,
510,
197,
2722,
9119,
1678,
36892,
7,
20,
353,
882,
32435,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestDeviceFilter_Nil(t *testing.T) {
expected := `
// load parameters into registers
0: LdXMemW dst: r2 src: r1 off: 0 imm: 0
1: And32Imm dst: r2 imm: 65535
2: LdXMemW dst: r3 src: r1 off: 0 imm: 0
3: RSh32Imm dst: r3 imm: 16
4: LdXMemW dst: r4 src: r1 off: 4 imm: 0
... | explode_data.jsonl/2941 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 245
} | [
2830,
3393,
6985,
5632,
1604,
321,
1155,
353,
8840,
836,
8,
341,
42400,
1669,
22074,
322,
2795,
5029,
1119,
24740,
198,
286,
220,
15,
25,
444,
67,
55,
18816,
54,
10648,
25,
435,
17,
2286,
25,
435,
16,
1007,
25,
220,
15,
4893,
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 TestParseCheckLevel(t *testing.T) {
expected := make(map[string]checks.CheckStatus)
expected["Warning"] = checks.Warning
expected["WARNING"] = checks.Warning
expected["warning"] = checks.Warning
expected["WaRnInG"] = checks.Warning
expected["Critical"] = checks.Critical
expected["CRITICAL"] = checks.Critica... | explode_data.jsonl/42336 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 296
} | [
2830,
3393,
14463,
3973,
4449,
1155,
353,
8840,
836,
8,
341,
42400,
1669,
1281,
9147,
14032,
60,
49383,
10600,
2522,
340,
42400,
1183,
12087,
1341,
284,
12341,
51763,
198,
42400,
1183,
32704,
1341,
284,
12341,
51763,
198,
42400,
1183,
189... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestDBAppenderAddRef(t *testing.T) {
db, delete := openTestDB(t, nil)
defer func() {
testutil.Ok(t, db.Close())
delete()
}()
app1 := db.Appender()
ref1, err := app1.Add(labels.FromStrings("a", "b"), 123, 0)
testutil.Ok(t, err)
// Reference should already work before commit.
err = app1.AddFast(ref1, ... | explode_data.jsonl/64362 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 538
} | [
2830,
3393,
3506,
2164,
1659,
2212,
3945,
1155,
353,
8840,
836,
8,
341,
20939,
11,
3698,
1669,
1787,
2271,
3506,
1155,
11,
2092,
340,
16867,
2915,
368,
341,
197,
18185,
1314,
54282,
1155,
11,
2927,
10421,
2398,
197,
15618,
741,
197,
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 TestSqlSecretKeeper_GetSecret(t *testing.T) {
keeper := SqlSecretKeeper{
nil,
"apps",
"app_key",
"app_secret",
}
_, err := keeper.GetSecret("thekey")
assert.NotNil(t, err)
keeper.Db = getdb()
_, err = keeper.GetSecret("thekey")
assert.NotNil(t, err)
val, _ := sqlKeeper.GetSecret("thekey")
assert.T... | explode_data.jsonl/38397 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 152
} | [
2830,
3393,
8269,
19773,
77233,
13614,
19773,
1155,
353,
8840,
836,
8,
341,
197,
18861,
1669,
7224,
19773,
77233,
515,
197,
84131,
345,
197,
197,
1,
27635,
756,
197,
197,
1,
676,
3097,
756,
197,
197,
1,
676,
21962,
756,
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... | 1 |
func TestEngineBlockingChitRequest(t *testing.T) {
vdr, _, sender, vm, te, gBlk := setup(t)
sender.Default(true)
missingBlk := &Blk{
parent: gBlk,
id: GenerateID(),
status: choices.Unknown,
bytes: []byte{1},
}
parentBlk := &Blk{
parent: missingBlk,
id: GenerateID(),
status: choices.Process... | explode_data.jsonl/3570 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 555
} | [
2830,
3393,
4571,
48266,
1143,
275,
1900,
1155,
353,
8840,
836,
8,
341,
5195,
3612,
11,
8358,
4646,
11,
10995,
11,
1013,
11,
342,
4923,
74,
1669,
6505,
1155,
692,
1903,
1659,
13275,
3715,
692,
197,
30616,
4923,
74,
1669,
609,
4923,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestMapProxy_Replace(t *testing.T) {
mp.Put("testingKey1", "testingValue1")
replaced, err := mp.Replace("testingKey1", "testingValue2")
AssertEqualf(t, err, replaced, "testingValue1", "Map Replace returned wrong old value.")
newValue, err := mp.Get("testingKey1")
AssertEqualf(t, err, newValue, "testingValue2"... | explode_data.jsonl/56997 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 124
} | [
2830,
3393,
2227,
16219,
62,
23107,
1155,
353,
8840,
836,
8,
341,
53230,
39825,
445,
8840,
1592,
16,
497,
330,
8840,
1130,
16,
1138,
17200,
36369,
11,
1848,
1669,
10490,
20858,
445,
8840,
1592,
16,
497,
330,
8840,
1130,
17,
1138,
1801... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAuthServer_LoginAPIKey(t *testing.T) {
ctrl := gomock.NewController(t)
defer ctrl.Finish()
_, mockClients, cleanup := testutils.CreateTestAPIEnv(t)
defer cleanup()
md := map[string][]string{
"pixie-api-key": []string{"test-token"},
}
ctx := metadata.NewIncomingContext(context.Background(), md)
mock... | explode_data.jsonl/37840 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 316
} | [
2830,
3393,
5087,
5475,
79232,
7082,
1592,
1155,
353,
8840,
836,
8,
341,
84381,
1669,
342,
316,
1176,
7121,
2051,
1155,
340,
16867,
23743,
991,
18176,
2822,
197,
6878,
7860,
47174,
11,
21290,
1669,
1273,
6031,
7251,
2271,
7082,
14359,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestGetCacheControlOpts(t *testing.T) {
testCases := []struct {
cacheControlHeaderVal string
expiryHeaderVal string
expectedCacheControl cacheControl
expectedErr bool
}{
{"", "", cacheControl{}, false},
{"max-age=2592000, public", "", cacheControl{maxAge: 2592000, sMaxAge: 0, minFres... | explode_data.jsonl/74498 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 645
} | [
2830,
3393,
1949,
8233,
3273,
43451,
1155,
353,
8840,
836,
8,
341,
18185,
37302,
1669,
3056,
1235,
341,
197,
52680,
3273,
4047,
2208,
914,
198,
197,
48558,
33770,
4047,
2208,
981,
914,
198,
197,
42400,
8233,
3273,
220,
6500,
3273,
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... | 7 |
func TestColIdent(t *testing.T) {
str := NewColIdent("Ab")
if str.String() != "Ab" {
t.Errorf("String=%s, want Ab", str.String())
}
if str.String() != "Ab" {
t.Errorf("Val=%s, want Ab", str.String())
}
if str.Lowered() != "ab" {
t.Errorf("Val=%s, want ab", str.Lowered())
}
if !str.Equal(NewColIdent("aB"))... | explode_data.jsonl/3382 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 257
} | [
2830,
3393,
6127,
28301,
1155,
353,
8840,
836,
8,
341,
11355,
1669,
1532,
6127,
28301,
445,
5830,
1138,
743,
607,
6431,
368,
961,
330,
5830,
1,
341,
197,
3244,
13080,
445,
703,
7846,
82,
11,
1366,
3680,
497,
607,
6431,
2398,
197,
53... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 7 |
func TestUpdateBondedValidatorsDecreaseCliff(t *testing.T) {
numVals := 10
maxVals := 5
// create context, keeper, and pool for tests
app, ctx, _, valAddrs := bootstrapValidatorTest(t, 0, 100)
bondedPool := app.StakingKeeper.GetBondedPool(ctx)
notBondedPool := app.StakingKeeper.GetNotBondedPool(ctx)
// create... | explode_data.jsonl/6094 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 891
} | [
2830,
3393,
4289,
89844,
291,
31748,
94843,
519,
5066,
3092,
1155,
353,
8840,
836,
8,
341,
22431,
52452,
1669,
220,
16,
15,
198,
22543,
52452,
1669,
220,
20,
271,
197,
322,
1855,
2266,
11,
53416,
11,
323,
7314,
369,
7032,
198,
28236,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestGetDaemonEndpointsFromStringInvalid1(t *testing.T) { // "udp:127.0.0.5:2001 udp:127.0.0.5:2001"
udpAddr := "127.0.0.2:2001"
tcpAddr := "127.0.0.1:2000"
dAddr := "udp:" + udpAddr + " udp:" + tcpAddr
dEndpt, err := GetDaemonEndpointsFromString(dAddr)
assert.NotNil(t, err)
assert.True(t, strings.Contains(f... | explode_data.jsonl/49936 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 178
} | [
2830,
3393,
1949,
89177,
80786,
44491,
7928,
16,
1155,
353,
8840,
836,
8,
314,
442,
330,
31101,
25,
16,
17,
22,
13,
15,
13,
15,
13,
20,
25,
17,
15,
15,
16,
49219,
25,
16,
17,
22,
13,
15,
13,
15,
13,
20,
25,
17,
15,
15,
16,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestWhiteList(t *testing.T) {
testCases := []struct {
desc string
labels map[string]string
expected *types.WhiteList
}{
{
desc: "should return nil when no white list labels",
labels: map[string]string{},
expected: nil,
},
{
desc: "should return a struct when deprecated label",... | explode_data.jsonl/51857 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 868
} | [
2830,
3393,
14075,
852,
1155,
353,
8840,
836,
8,
341,
18185,
37302,
1669,
3056,
1235,
341,
197,
41653,
257,
914,
198,
197,
95143,
256,
2415,
14032,
30953,
198,
197,
42400,
353,
9242,
20723,
852,
198,
197,
59403,
197,
197,
515,
298,
41... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestRoleDelete(t *testing.T) {
_, roleServ := initRoleTest()
samples := []struct {
fix types.FixedCol
err error
}{
{
fix: types.FixedCol{
ID: 7,
CompanyID: 1001,
NodeID: 101,
},
err: nil,
},
{
fix: types.FixedCol{
ID: 99999999,
CompanyID: 1001,
Nod... | explode_data.jsonl/15123 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 321
} | [
2830,
3393,
9030,
6435,
1155,
353,
8840,
836,
8,
341,
197,
6878,
3476,
39159,
1669,
2930,
9030,
2271,
2822,
1903,
4023,
1669,
3056,
1235,
341,
197,
1166,
941,
4494,
35571,
6127,
198,
197,
9859,
1465,
198,
197,
59403,
197,
197,
515,
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... | 6 |
func TestPageWithZeroFile(t *testing.T) {
newTestSitesBuilder(t).WithLogger(loggers.NewWarningLogger()).WithSimpleConfigFile().
WithTemplatesAdded("index.html", "{{ .File.Filename }}{{ with .File }}{{ .Dir }}{{ end }}").Build(BuildCfg{})
} | explode_data.jsonl/60634 | {
"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,
2665,
2354,
17999,
1703,
1155,
353,
8840,
836,
8,
341,
8638,
2271,
93690,
3297,
1155,
568,
2354,
7395,
12531,
10637,
7121,
12087,
7395,
6011,
2354,
16374,
2648,
1703,
25829,
197,
197,
2354,
51195,
19337,
445,
1252,
2564,
497,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestWSBasicAuth(t *testing.T) {
for _, test := range []struct {
name string
opts func() *Options
user string
pass string
err string
}{
{
"top level auth, no override, wrong u/p",
func() *Options {
o := testWSOptions()
o.Username = "normal"
o.Password = "client"
return o
},
... | explode_data.jsonl/42727 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1147
} | [
2830,
3393,
7433,
15944,
5087,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
1273,
1669,
2088,
3056,
1235,
341,
197,
11609,
914,
198,
197,
64734,
2915,
368,
353,
3798,
198,
197,
19060,
914,
198,
197,
41431,
914,
198,
197,
9859,
220,
914,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestTwilioVoiceStop(t *testing.T) {
t.Parallel()
sql := `
insert into users (id, name, email)
values
({{uuid "user"}}, 'bob', 'joe');
insert into user_contact_methods (id, user_id, name, type, value)
values
({{uuid "cm1"}}, {{uuid "user"}}, 'personal', 'VOICE', {{phone "1"}}),
({{uuid "cm2"}}, {{uu... | explode_data.jsonl/37353 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 594
} | [
2830,
3393,
22816,
33329,
51167,
10674,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
30633,
1669,
22074,
59847,
1119,
3847,
320,
307,
11,
829,
11,
2551,
8,
715,
45939,
715,
197,
197,
2306,
90,
17128,
330,
872,
9207,
2137,
36... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestSigning(t *testing.T) {
sr := newRequest(1)
sr.UnsignedJSON = fmt.Sprintf(`{"camliVersion": 1, "foo": "fooVal", "camliSigner": %q }`, pubKeyBlob1.BlobRef().String())
signed, err := sr.Sign(ctxbg)
AssertNil(t, err, "no error signing")
Assert(t, strings.Contains(signed, `"camliSig":`), "got a camliSig")
... | explode_data.jsonl/44737 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 439
} | [
2830,
3393,
93358,
1155,
353,
8840,
836,
8,
341,
1903,
81,
1669,
501,
1900,
7,
16,
340,
1903,
81,
10616,
2215,
5370,
284,
8879,
17305,
5809,
4913,
11599,
742,
5637,
788,
220,
16,
11,
330,
7975,
788,
330,
7975,
2208,
497,
330,
11599,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestJobSpecsController_Show_FluxMonitorJob(t *testing.T) {
t.Parallel()
rpcClient, gethClient, _, assertMocksCalled := cltest.NewEthMocksWithStartupAssertions(t)
defer assertMocksCalled()
app, cleanup := cltest.NewApplication(t,
eth.NewClientWith(rpcClient, gethClient),
)
defer cleanup()
require.NoError(... | explode_data.jsonl/31819 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 538
} | [
2830,
3393,
12245,
8327,
82,
2051,
79665,
1400,
62859,
30098,
12245,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
7000,
3992,
2959,
11,
633,
71,
2959,
11,
8358,
2060,
72577,
20960,
1669,
1185,
1944,
7121,
65390,
11571,
16056,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestHelmWithMissingValueFiles(t *testing.T) {
service := newService("../..")
missingValuesFile := "values-prod-overrides.yaml"
req := &apiclient.ManifestRequest{
Repo: &argoappv1.Repository{},
AppName: "test",
ApplicationSource: &argoappv1.ApplicationSource{
Path: "./util/helm/testdata/redis",
H... | explode_data.jsonl/5675 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 318
} | [
2830,
3393,
39,
23162,
2354,
25080,
1130,
10809,
1155,
353,
8840,
836,
8,
341,
52934,
1669,
501,
1860,
17409,
496,
1138,
197,
30616,
6227,
1703,
1669,
330,
3661,
9838,
67,
28252,
18245,
33406,
1837,
24395,
1669,
609,
391,
292,
1451,
722... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestReturnsAnnotatedPodRole(t *testing.T) {
defer leaktest.Check(t)()
ctx, cancel := context.WithCancel(context.Background())
defer cancel()
source := kt.NewFakeControllerSource()
defer source.Shutdown()
source.Add(testutil.NewPodWithRole("ns", "name", "192.168.0.1", "Running", "running_role"))
podCache :... | explode_data.jsonl/43096 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 266
} | [
2830,
3393,
16446,
2082,
87029,
23527,
9030,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
10600,
1155,
8,
741,
20985,
11,
9121,
1669,
2266,
26124,
9269,
5378,
19047,
2398,
16867,
9121,
2822,
47418,
1669,
18541,
7121,
52317,
2051,
360... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPublishWithSourceIdInPayload(t *testing.T) {
subject, requestPayload := buildDefaultTestSubjectAndPayload()
sub, _ := sc.Subscribe(subject, func(m *stan.Msg) {
msg = m
})
responseBody, statusCode := performPublishRequest(t, publishServer.URL, requestPayload)
verifyPublish(t, statusCode, sub, responseBod... | explode_data.jsonl/74406 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 111
} | [
2830,
3393,
50145,
2354,
3608,
764,
641,
29683,
1155,
353,
8840,
836,
8,
341,
28624,
583,
11,
1681,
29683,
1669,
1936,
3675,
2271,
13019,
3036,
29683,
741,
28624,
11,
716,
1669,
1136,
82628,
29128,
11,
2915,
1255,
353,
24025,
30365,
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 TestStorageBoxClient_List(t *testing.T) {
client, s := testServer(t)
defer s.Close()
l, err := client.StorageBox().List()
require.NoError(t, err)
expected := []*StorageBoxSummary{
{
ID: 123,
Login: "u1234",
Name: "",
Product: "BX10 - inclusive",
Cancelled: f... | explode_data.jsonl/45862 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 237
} | [
2830,
3393,
5793,
1611,
2959,
27104,
1155,
353,
8840,
836,
8,
341,
25291,
11,
274,
1669,
1273,
5475,
1155,
340,
16867,
274,
10421,
2822,
8810,
11,
1848,
1669,
2943,
43771,
1611,
1005,
852,
741,
17957,
35699,
1155,
11,
1848,
692,
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... | 1 |
func TestCanvas_Dragged(t *testing.T) {
dragged := false
var draggedObj fyne.Draggable
scroll := container.NewScroll(widget.NewLabel("Hi\nHi\nHi"))
c := NewCanvas().(*mobileCanvas)
c.SetContent(scroll)
c.resize(fyne.NewSize(40, 24))
assert.Equal(t, float32(0), scroll.Offset.Y)
c.tapDown(fyne.NewPos(32, 3), 0)
... | explode_data.jsonl/43163 | {
"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,
18226,
1557,
4101,
3556,
1155,
353,
8840,
836,
8,
341,
2698,
4101,
3556,
1669,
895,
198,
2405,
37147,
5261,
51941,
811,
909,
4101,
35034,
198,
75746,
1669,
5476,
7121,
8425,
34690,
7121,
2476,
445,
13048,
1699,
13048,
1699,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPickAvailabilityZone(t *testing.T) {
testCases := []struct {
name string
testFunc func(t *testing.T)
}{
{
name: "requirement missing ",
testFunc: func(t *testing.T) {
expectedresponse := ""
region := "test"
actualresponse := pickAvailabilityZone(nil, region)
if !reflect.DeepEq... | explode_data.jsonl/59397 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 895
} | [
2830,
3393,
36953,
51703,
15363,
1155,
353,
8840,
836,
8,
341,
18185,
37302,
1669,
3056,
1235,
341,
197,
11609,
257,
914,
198,
197,
18185,
9626,
2915,
1155,
353,
8840,
836,
340,
197,
59403,
197,
197,
515,
298,
11609,
25,
330,
4310,
47... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSwitchAccount(t *testing.T) {
th := Setup(t).InitBasic()
defer th.TearDown()
th.App.UpdateConfig(func(cfg *model.Config) { *cfg.GitLabSettings.Enable = true })
th.Client.Logout()
sr := &model.SwitchRequest{
CurrentService: model.UserAuthServiceEmail,
NewService: model.UserAuthServiceGitlab,
E... | explode_data.jsonl/47544 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1354
} | [
2830,
3393,
16837,
7365,
1155,
353,
8840,
836,
8,
341,
70479,
1669,
18626,
1155,
568,
3803,
15944,
741,
16867,
270,
836,
682,
4454,
2822,
70479,
5105,
16689,
2648,
18552,
28272,
353,
2528,
10753,
8,
314,
353,
14072,
1224,
275,
29046,
60... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestStoreSendBadRange(t *testing.T) {
defer leaktest.AfterTest(t)()
stopper := stop.NewStopper()
defer stopper.Stop(context.Background())
store, _ := createTestStore(t, testStoreOpts{createSystemRanges: true}, stopper)
args := getArgs([]byte("0"))
if _, pErr := kv.SendWrappedWith(context.Background(), store.... | explode_data.jsonl/95 | {
"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,
6093,
11505,
17082,
6046,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
36892,
2271,
1155,
8,
741,
62644,
712,
1669,
2936,
7121,
10674,
712,
741,
16867,
2936,
712,
30213,
5378,
19047,
2398,
57279,
11,
716,
1669,
1855,
22... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestBlockingSend(t *testing.T) {
// Scenario: Basic test that spawns 2 nodes and sends from the first node
// to the second node, three SubmitRequests, or three consensus requests.
// SubmitRequests should block, but consensus requests should not.
for _, testCase := range []struct {
description strin... | explode_data.jsonl/39830 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1177
} | [
2830,
3393,
48266,
11505,
1155,
353,
8840,
836,
8,
341,
197,
322,
58663,
25,
14625,
1273,
429,
92676,
220,
17,
7798,
323,
21308,
504,
279,
1156,
2436,
198,
197,
322,
311,
279,
2086,
2436,
11,
2326,
29170,
35295,
11,
476,
2326,
23869,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestEvaluateCondition_True2(t *testing.T) {
condition := "services.frontend[0].name == \"angular\""
result := EvaluateCondition(condition, templateData, varMap)
assert.True(t, result)
} | explode_data.jsonl/67925 | {
"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,
93577,
17,
1155,
353,
8840,
836,
8,
341,
197,
9056,
1669,
330,
12779,
23445,
408,
58,
15,
936,
606,
621,
7245,
4234,
2105,
698,
9559,
1669,
54115,
10547,
47489,
11,
3811,
1043,
11,
762,
2227,
340,
6948,
32443... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestRoles(t *testing.T) {
for _, tc := range rolesTests {
gotRoles := make([]fuzzy.RuneRole, len(tc.str))
fuzzy.RuneRoles([]byte(tc.str), gotRoles)
got := rolesString(gotRoles)
if got != tc.want {
t.Errorf("roles(%s) = %v; want %v", tc.str, got, tc.want)
}
}
} | explode_data.jsonl/58124 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 135
} | [
2830,
3393,
25116,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
17130,
1669,
2088,
12783,
18200,
341,
197,
3174,
354,
25116,
1669,
1281,
10556,
69,
34758,
2013,
2886,
9030,
11,
2422,
44415,
9528,
1171,
197,
1166,
34758,
2013,
2886,
25116,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_hasSecretWhenSSLEnabled(t *testing.T) {
helmChartParser := NewHelmConfigParser(
NewHelmTest(t, helmChartRelativePath, map[string]string{
"traefik.enabled": "true",
"traefik.ports.websecure.tls.enabled": "true",
}),
)
var deployment v12.Deployment
helmChartParser.Find(SearchR... | explode_data.jsonl/14602 | {
"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,
21778,
19773,
4498,
1220,
867,
77,
2312,
1155,
353,
8840,
836,
8,
341,
9598,
23162,
14488,
6570,
1669,
1532,
39,
23162,
2648,
6570,
1006,
197,
197,
3564,
39,
23162,
2271,
1155,
11,
33765,
14488,
28442,
1820,
11,
2415,
14032,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCheckDatabaseNamesAndUsers(t *testing.T) {
roleEmpty := &types.RoleV4{
Metadata: types.Metadata{Name: "roleA", Namespace: apidefaults.Namespace},
Spec: types.RoleSpecV4{
Options: types.RoleOptions{MaxSessionTTL: types.Duration(time.Hour)},
Allow: types.RoleConditions{
Namespaces: []string{apidef... | explode_data.jsonl/40084 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1171
} | [
2830,
3393,
3973,
5988,
7980,
3036,
7137,
1155,
353,
8840,
836,
8,
341,
197,
5778,
3522,
1669,
609,
9242,
35955,
53,
19,
515,
197,
9209,
7603,
25,
4494,
46475,
63121,
25,
330,
5778,
32,
497,
41962,
25,
1443,
577,
59572,
82,
46011,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestConcatStrings(t *testing.T) {
cases := []struct {
args []string
expect string
}{
{
args: []string{},
expect: "",
},
{
args: nil,
expect: "",
},
{
args: []string{"a", "", "b"},
expect: "ab",
},
}
var s string
for _, c := range cases {
s = ConcatStrings(c.args...)... | explode_data.jsonl/76278 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 220
} | [
2830,
3393,
78440,
20859,
1155,
353,
8840,
836,
8,
341,
1444,
2264,
1669,
3056,
1235,
341,
197,
31215,
256,
3056,
917,
198,
197,
24952,
914,
198,
197,
59403,
197,
197,
515,
298,
31215,
25,
256,
3056,
917,
38837,
298,
24952,
25,
8324,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestRouterMultiLevelWildcard(t *testing.T) {
// Create empty handler
h := new(Handler)
// Create empty context
c := new(Context)
c.Params = Params{}
// Create route
r := Route("/a/b/*/d", h)
// Matching routes
rs := []string{"/a/b/c/d", "a/b/c/d", "/a/b/*/d", "a/b/something/d"}
// Check
for _, s := ... | explode_data.jsonl/35796 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 187
} | [
2830,
3393,
9523,
20358,
4449,
92988,
1155,
353,
8840,
836,
8,
341,
197,
322,
4230,
4287,
7013,
198,
9598,
1669,
501,
7,
3050,
692,
197,
322,
4230,
4287,
2266,
198,
1444,
1669,
501,
14001,
340,
1444,
58268,
284,
34352,
31483,
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... | 3 |
func TestSyncReadString(t *testing.T) {
s := NewSyncScanner(strings.NewReader("\005\000\000\000hello"))
str, err := s.ReadString()
assert.NoError(t, err)
assert.Equal(t, "hello", str)
} | explode_data.jsonl/80530 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 75
} | [
2830,
3393,
12154,
4418,
703,
1155,
353,
8840,
836,
8,
341,
1903,
1669,
1532,
12154,
31002,
51442,
68587,
4921,
15,
15,
20,
59,
15,
15,
15,
59,
15,
15,
15,
59,
15,
15,
15,
14990,
5455,
11355,
11,
1848,
1669,
274,
96738,
741,
6948,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
func TestStartStoppedHost(t *testing.T) {
RegisterMockDriver(t)
api := tests.NewMockAPI(t)
// Create an initial host.
h, err := createHost(api, defaultMachineConfig)
if err != nil {
t.Fatalf("Error creating host: %v", err)
}
d := tests.MockDriver{T: t}
h.Driver = &d
d.CurrentState = state.Stopped
md := &te... | explode_data.jsonl/4182 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 328
} | [
2830,
3393,
3479,
59803,
9296,
1155,
353,
8840,
836,
8,
341,
79096,
11571,
11349,
1155,
340,
54299,
1669,
7032,
7121,
11571,
7082,
1155,
340,
197,
322,
4230,
458,
2856,
3468,
624,
9598,
11,
1848,
1669,
1855,
9296,
24827,
11,
1638,
21605... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestLatLng_Clone(t *testing.T) {
tests := []struct {
Name string
LL, Expected *LatLng
}{
{
Name: "nil latlng",
},
{
Name: "cloned",
LL: &LatLng{
Lat: 10,
Lng: 11,
},
Expected: &LatLng{
Lat: 10,
Lng: 11,
},
},
}
for _, tc := range tests {
tc := tc
t.Run... | explode_data.jsonl/10030 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 283
} | [
2830,
3393,
64922,
85110,
603,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
1235,
341,
197,
21297,
260,
914,
198,
197,
93881,
11,
31021,
353,
64922,
198,
197,
59403,
197,
197,
515,
298,
21297,
25,
330,
8385,
6844,
20810,
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... | 2 |
func TestNew(t *testing.T) {
regions := []string{"us-east-1", "us-west25"}
cfg, _ := ptypes.MarshalAny(&awsv1.Config{
Regions: regions,
})
log := zaptest.NewLogger(t)
scope := tally.NewTestScope("", nil)
s, err := New(cfg, log, scope)
assert.NoError(t, err)
// Test conformance to public interface.
_, ok :=... | explode_data.jsonl/3398 | {
"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,
3564,
1155,
353,
8840,
836,
8,
341,
37013,
908,
1669,
3056,
917,
4913,
355,
39507,
12,
16,
497,
330,
355,
37602,
17,
20,
63159,
50286,
11,
716,
1669,
281,
9242,
37271,
8610,
2099,
672,
3492,
16,
10753,
515,
197,
197,
792... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestApplication_Serve(t *testing.T) {
logger := yetlog.NewNullLogger()
serverWrapper := NewEmbeddableServerWrapper(logger, 0)
serverWrapperTestInstance, testPort := serverWrapper.createTestInstance(t)
ctx, cancelFunc := context.WithCancel(context.Background())
t.Run("should successfully start a server", fun... | explode_data.jsonl/48258 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 410
} | [
2830,
3393,
4988,
1098,
5852,
1155,
353,
8840,
836,
8,
341,
17060,
1669,
3602,
839,
7121,
3280,
7395,
741,
41057,
11542,
1669,
1532,
25486,
67,
480,
5475,
11542,
37833,
11,
220,
15,
692,
41057,
11542,
2271,
2523,
11,
1273,
7084,
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 TestWorkflowYAMLAndBack(t *testing.T) {
workflow := &Workflow{
Name: "testWorkflow",
Version: "v0.0.0.0.1",
TaskTemplates: []TaskTemplate{
TaskTemplate{
TaskName: "GetHTML",
Initial: true,
ActionTemplates: []ActionTemplate{
ActionTemplate{
Name: "HTTP1",
StructName:... | explode_data.jsonl/19591 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 2141
} | [
2830,
3393,
62768,
56,
31102,
3036,
3707,
1155,
353,
8840,
836,
8,
341,
197,
56249,
1669,
609,
62768,
515,
197,
21297,
25,
262,
330,
1944,
62768,
756,
197,
77847,
25,
330,
85,
15,
13,
15,
13,
15,
13,
15,
13,
16,
756,
197,
81153,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestGetServiceLoadBalancer(t *testing.T) {
testCases := []struct {
desc string
existingLBs []network.LoadBalancer
service v1.Service
annotations map[string]string
sku string
wantLB bool
expectedLB *network.LoadBalancer
expectedStatus *v1.LoadBalancerSt... | explode_data.jsonl/33999 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 2250
} | [
2830,
3393,
1949,
1860,
5879,
93825,
1155,
353,
8840,
836,
8,
341,
18185,
37302,
1669,
3056,
1235,
341,
197,
41653,
1843,
914,
198,
197,
8122,
11083,
34068,
82,
262,
3056,
17511,
13969,
93825,
198,
197,
52934,
286,
348,
16,
13860,
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... | 4 |
func TestResponseErrorWhenAdapterReturn(t *testing.T) {
a := assert.New(t)
ctx := context.Background()
response := &mavsdk_rpc_action.ReturnToLaunchResponse{
ActionResult: &mavsdk_rpc_action.ActionResult{
Result: mavsdk_rpc_action.ActionResult_BUSY,
},
}
actionMock := &actionServiceClientMock{}
actionMoc... | explode_data.jsonl/76180 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 180
} | [
2830,
3393,
2582,
1454,
4498,
5940,
5598,
1155,
353,
8840,
836,
8,
341,
11323,
1669,
2060,
7121,
1155,
692,
20985,
1669,
2266,
19047,
2822,
21735,
1669,
609,
76,
38751,
7584,
60799,
7931,
46350,
1249,
32067,
2582,
515,
197,
197,
17301,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestIKSEnvVariables(t *testing.T) {
coreops.SetInstance(coreops.New(fakek8sclient.NewSimpleClientset()))
nodeName := "testNode"
cluster := &corev1.StorageCluster{
ObjectMeta: metav1.ObjectMeta{
Name: "px-cluster",
Namespace: "kube-test",
Annotations: map[string]string{
pxutil.AnnotationIsIK... | explode_data.jsonl/55475 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 626
} | [
2830,
3393,
28561,
925,
36941,
22678,
1155,
353,
8840,
836,
8,
341,
71882,
3721,
4202,
2523,
47867,
3721,
7121,
74138,
74,
23,
82,
2972,
7121,
16374,
2959,
746,
12145,
20831,
675,
1669,
330,
1944,
1955,
1837,
197,
18855,
1669,
609,
9864... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestXRateErroring(t *testing.T) {
limit := rate.NewLimiter(rate.Every(time.Minute), 1)
testSuccessThenFailure(
t,
ratelimit.NewErroringLimiter(limit)(nopEndpoint),
ratelimit.ErrLimited.Error())
} | explode_data.jsonl/40233 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 80
} | [
2830,
3393,
55,
11564,
1454,
287,
1155,
353,
8840,
836,
8,
341,
8810,
2353,
1669,
4379,
7121,
43,
17700,
76723,
5142,
1204,
9730,
75770,
701,
220,
16,
340,
18185,
7188,
12209,
17507,
1006,
197,
3244,
345,
197,
7000,
83326,
2353,
7121,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestWritePlanText(t *testing.T) {
inner := bytes.NewBufferString("")
w := NewAnsiColorWriter(inner)
expected := "plain text"
fmt.Fprintf(w, expected)
actual := inner.String()
if actual != expected {
t.Errorf("Get %q, want %q", actual, expected)
}
} | explode_data.jsonl/3540 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 105
} | [
2830,
3393,
7985,
20485,
1178,
1155,
353,
8840,
836,
8,
972,
197,
4382,
1669,
5820,
7121,
4095,
703,
445,
6060,
6692,
1669,
1532,
2082,
6321,
1636,
6492,
68603,
1218,
42400,
1669,
330,
20772,
1467,
5031,
11009,
59559,
3622,
11,
3601,
12... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestStepsFailFast(t *testing.T) {
wf := unmarshalWF(stepsFailFast)
cancel, controller := newController(wf)
defer cancel()
ctx := context.Background()
woc := newWorkflowOperationCtx(wf, controller)
woc.operate(ctx)
assert.Equal(t, wfv1.WorkflowFailed, woc.wf.Status.Phase)
node := woc.wf.Status.Nodes.FindB... | explode_data.jsonl/71041 | {
"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,
33951,
19524,
32174,
1155,
353,
8840,
836,
8,
341,
6692,
69,
1669,
650,
27121,
32131,
84271,
19524,
32174,
340,
84441,
11,
6461,
1669,
501,
2051,
3622,
69,
340,
16867,
9121,
2822,
20985,
1669,
2266,
19047,
741,
6692,
509,
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... | 3 |
func TestNew(t *testing.T) {
s, etcdserver, config, assert := newMaster(t)
defer etcdserver.Terminate(t)
// Verify many of the variables match their config counterparts
assert.Equal(s.legacyAPIGroupPrefixes, config.LegacyAPIGroupPrefixes)
assert.Equal(s.admissionControl, config.AdmissionControl)
assert.Equal(s.R... | explode_data.jsonl/18758 | {
"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,
3564,
1155,
353,
8840,
836,
8,
341,
1903,
11,
1842,
4385,
4030,
11,
2193,
11,
2060,
1669,
501,
18041,
1155,
340,
16867,
1842,
4385,
4030,
836,
261,
34016,
1155,
692,
197,
322,
25429,
1657,
315,
279,
7332,
2432,
862,
2193,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestNodeUnpublishVolumeUnmount(t *testing.T) {
// Create server and client connection
s := newTestServer(t)
defer s.Stop()
// Make a call
c := csi.NewNodeClient(s.Conn())
name := "myvol"
size := uint64(10)
targetPath := "/tmp/mnttest"
gomock.InOrder(
s.MockDriver().
EXPECT().
Inspect([]string{na... | explode_data.jsonl/51453 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 566
} | [
2830,
3393,
1955,
1806,
27502,
18902,
59539,
1155,
353,
8840,
836,
8,
341,
197,
322,
4230,
3538,
323,
2943,
3633,
198,
1903,
1669,
501,
2271,
5475,
1155,
340,
16867,
274,
30213,
2822,
197,
322,
7405,
264,
1618,
198,
1444,
1669,
272,
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 TestSubmitJobInvalidResponse(t *testing.T) {
httpmock.Activate()
defer httpmock.DeactivateAndReset()
ctx := context.Background()
responder, _ := httpmock.NewJsonResponder(200, invalidTestResponse)
httpmock.RegisterResponder("POST", fakeSubmitURL, responder)
client := getTestJobManagerClient()
resp, err := ... | explode_data.jsonl/32365 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 157
} | [
2830,
3393,
8890,
12245,
7928,
2582,
1155,
353,
8840,
836,
8,
341,
28080,
16712,
14140,
731,
741,
16867,
1758,
16712,
8934,
16856,
3036,
14828,
741,
20985,
1669,
2266,
19047,
741,
10202,
20328,
11,
716,
1669,
1758,
16712,
7121,
5014,
3088... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestTLSAuthError(t *testing.T) {
client, err := NewClient(ClientOptions{
URL: serviceURLTLS,
TLSTrustCertsFilePath: caCertsPath,
})
assert.NoError(t, err)
producer, err := client.CreateProducer(ProducerOptions{
Topic: newAuthTopicName(),
})
assert.Error(t, err)
assert.Nil(t, produc... | explode_data.jsonl/69306 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 143
} | [
2830,
3393,
45439,
5087,
1454,
1155,
353,
8840,
836,
8,
341,
25291,
11,
1848,
1669,
1532,
2959,
46851,
3798,
515,
197,
79055,
25,
4293,
2473,
3144,
45439,
345,
197,
10261,
43,
784,
35788,
34,
15546,
19090,
25,
2162,
34,
15546,
1820,
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 TestContentManager_GenerateContent(t *testing.T) {
controller := gomock.NewController(t)
defer controller.Finish()
params := map[string][]string{}
dashConfig := configFake.NewMockDash(controller)
moduleManager := moduleFake.NewMockManagerInterface(controller)
state := octantFake.NewMockState(controller)
... | explode_data.jsonl/1648 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 418
} | [
2830,
3393,
2762,
2043,
2646,
13220,
2762,
1155,
353,
8840,
836,
8,
341,
61615,
1669,
342,
316,
1176,
7121,
2051,
1155,
340,
16867,
6461,
991,
18176,
2822,
25856,
1669,
2415,
14032,
45725,
917,
31483,
2698,
988,
2648,
1669,
2193,
52317,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestCreateEmptyFile1(t *testing.T) {
fi, err := file.CreateFile("D:/tmp/placeholder.txt")
if err != nil {
log.Fatal(err)
}
defer fi.Close()
fmt.Println(fi.WriteAt([]byte{222}, 1023))
//206,905,344
} | explode_data.jsonl/22065 | {
"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,
4021,
3522,
1703,
16,
1155,
353,
8840,
836,
8,
341,
30839,
11,
1848,
1669,
1034,
7251,
1703,
445,
35,
14375,
5173,
14,
12384,
3909,
1138,
743,
1848,
961,
2092,
341,
197,
6725,
26133,
3964,
340,
197,
532,
16867,
9136,
10421... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestInt32_IsEmpty(t *testing.T) {
testcases := []struct {
name string
s Int32
expect bool
}{
{
name: "test Int32 Empty, s is empty",
s: Int32{},
expect: true,
},
{
name: "test interface Empty, s is not empty",
s: map[int32]struct{}{1: {}, 2: {}, 3: {}},
expect: ... | explode_data.jsonl/62322 | {
"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,
1072,
18,
17,
31879,
3522,
1155,
353,
8840,
836,
8,
341,
18185,
23910,
1669,
3056,
1235,
341,
197,
11609,
256,
914,
198,
197,
1903,
414,
1333,
18,
17,
198,
197,
24952,
1807,
198,
197,
59403,
197,
197,
515,
298,
11609,
25... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestDefaults(t *testing.T) {
require.Equal(t, hd.PubKeyType("multi"), hd.MultiType)
require.Equal(t, hd.PubKeyType("secp256k1"), hd.Secp256k1Type)
require.Equal(t, hd.PubKeyType("ed25519"), hd.Ed25519Type)
require.Equal(t, hd.PubKeyType("sr25519"), hd.Sr25519Type)
} | explode_data.jsonl/61736 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 127
} | [
2830,
3393,
16273,
1155,
353,
8840,
836,
8,
341,
17957,
12808,
1155,
11,
17907,
1069,
392,
97964,
445,
26268,
3975,
17907,
57706,
929,
340,
17957,
12808,
1155,
11,
17907,
1069,
392,
97964,
445,
325,
4672,
17,
20,
21,
74,
16,
3975,
179... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestNextInDeferReturn(t *testing.T) {
// runtime.deferreturn updates the G struct in a way that for one
// instruction leaves the curg._defer field non-nil but with curg._defer.fn
// field being nil.
// We need to deal with this without panicing.
protest.AllowRecording(t)
withTestProcess("defercall", t, func... | explode_data.jsonl/56282 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 372
} | [
2830,
3393,
5847,
641,
1912,
802,
5598,
1155,
353,
8840,
836,
8,
341,
197,
322,
15592,
60043,
689,
8837,
279,
479,
2036,
304,
264,
1616,
429,
369,
825,
198,
197,
322,
7600,
10901,
279,
2847,
70,
1436,
62095,
2070,
2477,
83248,
714,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCgoLookupIP(t *testing.T) {
host := "localhost"
_, err, ok := cgoLookupIP(host)
if !ok {
t.Errorf("cgoLookupIP must not be a placeholder")
}
if err != nil {
t.Error(err)
}
if _, err := goLookupIP(host); err != nil {
t.Error(err)
}
} | explode_data.jsonl/8389 | {
"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,
34,
3346,
34247,
3298,
1155,
353,
8840,
836,
8,
341,
63104,
1669,
330,
8301,
698,
197,
6878,
1848,
11,
5394,
1669,
272,
3346,
34247,
3298,
19973,
340,
743,
753,
562,
341,
197,
3244,
13080,
445,
66,
3346,
34247,
3298,
1969,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
func Test_Handler_StructWithValues_ExpectValuesCopied(t *testing.T) {
var mock = mockStruct{
Field1: "moq1", Field2: "moq2",
}
t.Run("Pass struct type by value as ctor",
testForMockFunc(
mock,
func(v reflect.Value) {
assert.Equal(t, v.Interface(), mock)
},
),
)
t.Run("Pass struct pointer as ct... | explode_data.jsonl/45769 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 566
} | [
2830,
3393,
41879,
72246,
2354,
6227,
62,
17536,
6227,
56277,
1122,
1155,
353,
8840,
836,
8,
341,
2405,
7860,
284,
7860,
9422,
515,
197,
94478,
16,
25,
330,
6355,
80,
16,
497,
8601,
17,
25,
330,
6355,
80,
17,
756,
197,
630,
3244,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestSend(t *testing.T) {
ctrl, teardown := setupIpTest(t)
defer teardown()
devMock := mw.NewMockIDevice(ctrl)
devMock.EXPECT().IsUp().Return(true)
devMock.EXPECT().Name().Return("net0")
devMock.EXPECT().Flag().Return(mw.BroadcastFlag | mw.NeedArpFlag)
devMock.EXPECT().MTU().Return(uint16(mw.EthPayloadLenMa... | explode_data.jsonl/8508 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 423
} | [
2830,
3393,
11505,
1155,
353,
8840,
836,
8,
341,
84381,
11,
49304,
1669,
6505,
23378,
2271,
1155,
340,
16867,
49304,
2822,
27302,
11571,
1669,
52810,
7121,
11571,
915,
63924,
62100,
340,
27302,
11571,
22402,
7285,
1005,
3872,
2324,
1005,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestGetPubKey(t *testing.T) {
pv := mock.NewPV()
pk, err := pv.GetPubKey()
require.NoError(t, err)
require.Equal(t, "ed25519", pk.Type())
} | explode_data.jsonl/35537 | {
"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,
1949,
29162,
1592,
1155,
353,
8840,
836,
8,
341,
3223,
85,
1669,
7860,
7121,
48469,
741,
3223,
74,
11,
1848,
1669,
33491,
2234,
29162,
1592,
741,
17957,
35699,
1155,
11,
1848,
340,
17957,
12808,
1155,
11,
330,
291,
17,
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 |
func TestSizeLedgerWithNames(t *testing.T) {
templates, err := testutils.LoadTemplates("test-data-alltemplates.yaml")
if err != nil || len(templates) < 1 {
t.Errorf("cannot load test templates! %v", err)
return
}
ld := NewJSONLedger("flavor")
err = ld.ReadNameMap("test-size-names.json")
if err != nil {
t.E... | explode_data.jsonl/45685 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 308
} | [
2830,
3393,
1695,
60850,
1389,
2354,
7980,
1155,
353,
8840,
836,
8,
341,
197,
15463,
11,
1848,
1669,
1273,
6031,
13969,
51195,
445,
1944,
13945,
22346,
15463,
33406,
1138,
743,
1848,
961,
2092,
1369,
2422,
7,
15463,
8,
366,
220,
16,
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... | 4 |
func TestFSMsgFileWithExtraZeros(t *testing.T) {
cleanupFSDatastore(t)
defer cleanupFSDatastore(t)
s := createDefaultFileStore(t)
defer s.Close()
c := storeCreateChannel(t, s, "foo")
ms := c.Msgs
msg1 := storeMsg(t, c, "foo", 1, []byte("msg1"))
ms.(*FileMsgStore).RLock()
datname := ms.(*FileMsgStore).writeSl... | explode_data.jsonl/7780 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 633
} | [
2830,
3393,
8485,
6611,
1703,
2354,
11612,
57,
6264,
1155,
353,
8840,
836,
8,
341,
1444,
60639,
8485,
1043,
4314,
1155,
340,
16867,
21290,
8485,
1043,
4314,
1155,
692,
1903,
1669,
1855,
3675,
1703,
6093,
1155,
340,
16867,
274,
10421,
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... | 6 |
func TestComplexShowVariables(t *testing.T) {
// This is an example SHOW VARIABLES from mysql-connector-java-5.1.34
// It returns 19 rows in MySQL 5.7 (the language sysvar no longer exists in 5.6+)
// and 16 rows in MySQL 8.0 (the aliases for tx_isolation is removed, along with query cache)
// In the event that we ... | explode_data.jsonl/65591 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 437
} | [
2830,
3393,
31137,
7812,
22678,
1155,
353,
8840,
836,
8,
341,
197,
322,
1096,
374,
458,
3110,
38481,
76753,
504,
10564,
12,
53700,
85339,
12,
20,
13,
16,
13,
18,
19,
198,
197,
322,
1084,
4675,
220,
16,
24,
6978,
304,
26339,
220,
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 TestExecContextFailureWithoutCancelation(t *testing.T) {
t.Parallel()
testWithAndWithoutPreferSimpleProtocol(t, func(t *testing.T, conn *pgx.Conn) {
ctx, cancelFunc := context.WithCancel(context.Background())
defer cancelFunc()
_, err := conn.Exec(ctx, "selct;")
if err == nil {
t.Fatal("Expected SQL... | explode_data.jsonl/40008 | {
"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,
10216,
1972,
17507,
26040,
9269,
367,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
18185,
2354,
3036,
26040,
4703,
802,
16374,
20689,
1155,
11,
2915,
1155,
353,
8840,
836,
11,
4534,
353,
3517,
87,
50422,
8,
341,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestWithdrawInternationalBank(t *testing.T) {
t.Parallel()
_, err := b.WithdrawFiatFundsToInternationalBank(context.Background(),
&withdraw.Request{})
if err != common.ErrFunctionNotSupported {
t.Errorf("Expected '%v', received: '%v'", common.ErrFunctionNotSupported, err)
}
} | explode_data.jsonl/76679 | {
"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,
92261,
33646,
25828,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
197,
6878,
1848,
1669,
293,
26124,
7633,
37,
10358,
37,
42950,
1249,
33646,
25828,
5378,
19047,
3148,
197,
197,
5,
62446,
9659,
37790,
743,
1848,
961... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestNatto(t *testing.T) {
jsre, dir := newWithTestJS(t, `setTimeout(function(){msg = "testMsg"}, 1);`)
defer os.RemoveAll(dir)
err := jsre.Exec("test.js")
if err != nil {
t.Errorf("expected no error, got %v", err)
}
time.Sleep(100 * time.Millisecond)
val, err := jsre.Run("msg")
if err != nil {
t.Error... | explode_data.jsonl/1908 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 243
} | [
2830,
3393,
45,
16755,
1155,
353,
8840,
836,
8,
341,
95636,
265,
11,
5419,
1669,
501,
2354,
2271,
12545,
1155,
11,
1565,
78700,
2920,
11895,
3236,
284,
330,
1944,
6611,
14345,
220,
16,
1215,
24183,
16867,
2643,
84427,
14161,
692,
9859,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestReOpening(t *testing.T) {
catalogStore, err := store.Open("catalog_reopening", store.DefaultOptions())
require.NoError(t, err)
defer os.RemoveAll("catalog_reopening")
dataStore, err := store.Open("sqldata_reopening", store.DefaultOptions())
require.NoError(t, err)
defer os.RemoveAll("sqldata_reopening")... | explode_data.jsonl/64082 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 786
} | [
2830,
3393,
693,
51298,
1155,
353,
8840,
836,
8,
341,
1444,
7750,
6093,
11,
1848,
1669,
3553,
12953,
445,
26539,
1288,
67685,
497,
3553,
13275,
3798,
2398,
17957,
35699,
1155,
11,
1848,
340,
16867,
2643,
84427,
445,
26539,
1288,
67685,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestConstantTimeByteEq(t *testing.T) {
for i, test := range testConstandTimeByteEqData {
if r := ConstantTimeByteEq(test.a, test.b); r != test.out {
t.Errorf("#%d bad result (got %x, want %x)", i, r, test.out)
}
}
err := quick.CheckEqual(ConstantTimeByteEq, byteEq, nil)
if err != nil {
t.Error(err)
}... | explode_data.jsonl/79468 | {
"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,
15472,
1462,
7153,
27312,
1155,
353,
8840,
836,
8,
341,
2023,
600,
11,
1273,
1669,
2088,
1273,
1109,
2685,
1462,
7153,
27312,
1043,
341,
197,
743,
435,
1669,
19305,
1462,
7153,
27312,
8623,
5849,
11,
1273,
948,
1215,
435,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
func TestEndlessWrite(t *testing.T) {
t.Parallel()
c := make(chan bool)
server := func(cs *TCPConn) error {
cs.CloseWrite()
<-c
return nil
}
client := func(ss *TCPConn) error {
// Tell the server to return when we return.
defer close(c)
// Loop writing to the server. The server is not reading
// any... | explode_data.jsonl/22748 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 502
} | [
2830,
3393,
3727,
1717,
7985,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
1444,
1669,
1281,
35190,
1807,
340,
41057,
1669,
2915,
41153,
353,
49896,
9701,
8,
1465,
341,
197,
71899,
10421,
7985,
741,
197,
197,
45342,
66,
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... | 1 |
func TestParseArgsWhenEnv(t *testing.T) {
assertMatchArgs := func(t *testing.T, gotArgs, wantArgs *shell.CommandArgs) {
t.Helper()
if gotArgs.EnvName != wantArgs.EnvName {
t.Errorf("EnvName: got %s want %s", gotArgs.EnvName, wantArgs.EnvName)
}
if gotArgs.Version != wantArgs.Version {
t.Errorf("Version:... | explode_data.jsonl/78059 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1339
} | [
2830,
3393,
14463,
4117,
4498,
14359,
1155,
353,
8840,
836,
8,
1476,
6948,
8331,
4117,
1669,
2915,
1155,
353,
8840,
836,
11,
2684,
4117,
11,
1366,
4117,
353,
21384,
12714,
4117,
8,
341,
197,
3244,
69282,
741,
197,
743,
2684,
4117,
812... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestServerIdleTimeout(t *testing.T) {
if testing.Short() {
t.Skip("skipping in short mode")
}
st := newServerTester(t, func(w http.ResponseWriter, r *http.Request) {
}, func(h2s *Server) {
h2s.IdleTimeout = 500 * time.Millisecond
})
defer st.Close()
st.greet()
ga := st.wantGoAway()
if ga.ErrCode != ... | explode_data.jsonl/71702 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 168
} | [
2830,
3393,
5475,
41370,
7636,
1155,
353,
8840,
836,
8,
341,
743,
7497,
55958,
368,
341,
197,
3244,
57776,
445,
4886,
5654,
304,
2805,
3856,
1138,
197,
630,
18388,
1669,
501,
5475,
58699,
1155,
11,
2915,
3622,
1758,
37508,
11,
435,
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 TestCAConfigSecurityProvider(t *testing.T) {
backend, err := config.FromFile(configTestFilePath)()
if err != nil {
t.Fatal("Failed to get config backend")
}
customBackend := getCustomBackend(backend...)
cryptoConfig := ConfigFromBackend(customBackend).(*Config)
// Test SecurityProvider provider
val, ok... | explode_data.jsonl/58379 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 201
} | [
2830,
3393,
5049,
2648,
15352,
5179,
1155,
353,
8840,
836,
8,
341,
197,
20942,
11,
1848,
1669,
2193,
11439,
1703,
8754,
2271,
19090,
8,
741,
743,
1848,
961,
2092,
341,
197,
3244,
26133,
445,
9408,
311,
633,
2193,
19163,
1138,
197,
630... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 5 |
func TestCSDeleteChannel(t *testing.T) {
for _, st := range testStores {
st := st
t.Run(st.name, func(t *testing.T) {
t.Parallel()
defer endTest(t, st)
s := startTest(t, st)
defer s.Close()
if err := s.DeleteChannel("notfound"); err != ErrNotFound {
t.Fatalf("Expected %v error, got %v", ErrNotF... | explode_data.jsonl/28304 | {
"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,
6412,
6435,
9629,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
357,
1669,
2088,
1273,
69026,
341,
197,
18388,
1669,
357,
198,
197,
3244,
16708,
5895,
2644,
11,
2915,
1155,
353,
8840,
836,
8,
341,
298,
3244,
41288,
7957,
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... | 6 |
func TestParseVolumeWithRW(t *testing.T) {
for _, path := range []string{"./foo", "/home/user"} {
volume, err := parseVolume(path + ":/target:rw")
expected := types.ServiceVolumeConfig{
Type: "bind",
Source: path,
Target: "/target",
ReadOnly: false,
}
assert.NoError(t, err)
assert.Equal(t... | explode_data.jsonl/70104 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 143
} | [
2830,
3393,
14463,
18902,
2354,
56368,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
1815,
1669,
2088,
3056,
917,
4913,
1725,
7975,
497,
3521,
5117,
11739,
9207,
341,
197,
5195,
4661,
11,
1848,
1669,
4715,
18902,
5581,
488,
13022,
14,
5657,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestRuleOrderByExpr(t *testing.T) {
common.Log.Debug("Entering function: %s", common.GetFunctionName())
sqls := [][]string{
{
"SELECT col FROM tbl order by cola - cl;", // order by 列运算
"SELECT cola - cl col FROM tbl order by col;", // 别名为列运算
"SELECT cola FROM tbl order by fro... | explode_data.jsonl/76753 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 654
} | [
2830,
3393,
11337,
34605,
16041,
1155,
353,
8840,
836,
8,
341,
83825,
5247,
20345,
445,
82867,
729,
25,
1018,
82,
497,
4185,
2234,
5152,
675,
2398,
30633,
82,
1669,
52931,
917,
515,
197,
197,
515,
298,
197,
1,
4858,
1375,
4295,
21173,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestConfig_ForEachAdvisory(t *testing.T) {
type args struct {
source string
pkgName string
}
tests := []struct {
name string
args args
fixtures []string
want map[string]types.Advisory
wantErr string
}{
{
name: "single bucket",
args: args{
source: "GitHub Security Adviso... | explode_data.jsonl/72884 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1206
} | [
2830,
3393,
2648,
84368,
4854,
2589,
2682,
679,
1155,
353,
8840,
836,
8,
341,
13158,
2827,
2036,
341,
197,
47418,
220,
914,
198,
197,
3223,
7351,
675,
914,
198,
197,
532,
78216,
1669,
3056,
1235,
341,
197,
11609,
257,
914,
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... | 4 |
func TestBlockNumber(t *testing.T) {
t.Parallel()
client := NewHTTPClient("https://api.myetherapi.com/eth")
const min = 5132536 // Block number at time test was added.
if block, err := client.BlockNumber(); err != nil {
t.Fatal(err)
} else if block < min {
t.Fatal("block number is too low:", block, "<", min... | explode_data.jsonl/80662 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 118
} | [
2830,
3393,
4713,
2833,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
25291,
1669,
1532,
9230,
2959,
445,
2428,
1110,
2068,
12618,
2723,
2068,
905,
14,
769,
5130,
4777,
1308,
284,
220,
20,
16,
18,
17,
20,
18,
21,
442,
8362,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAddress(t *testing.T) {
buf := []byte(`----one dot one
----one dot two
----two dot one
two content
lines
`)
pages, _ := pagesFrom(buf)
want := []int{1, 4}
var got []int
for _, page := range pages {
got = append(got, page.Address())
}
if !reflect.DeepEqual(want, got) {
t.Errorf("\nwant: %v\ngot: ... | explode_data.jsonl/41281 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 146
} | [
2830,
3393,
4286,
1155,
353,
8840,
836,
8,
341,
26398,
1669,
3056,
3782,
5809,
381,
603,
12756,
825,
198,
381,
603,
12756,
1378,
271,
381,
19789,
12756,
825,
271,
19789,
2213,
198,
7969,
271,
24183,
3223,
1134,
11,
716,
1669,
6816,
38... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestMMappedIndex(t *testing.T) {
tempdir, err := ioutil.TempDir("", "weaviate-vector-test")
if err != nil {
t.Errorf("Could not create temporary directory, %v", err)
}
defer os.RemoveAll(tempdir)
// First generate the csv input fileformat based on the test data.
var dataset = ""
for i := 0; i... | explode_data.jsonl/10277 | {
"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,
8035,
5677,
1552,
1155,
353,
8840,
836,
8,
341,
220,
2730,
3741,
11,
1848,
1669,
43144,
65009,
6184,
19814,
330,
896,
6190,
349,
65192,
16839,
5130,
220,
421,
1848,
961,
2092,
341,
262,
259,
13080,
445,
12895,
537,
1855,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestChouonpuA(t *testing.T) {
input := []inp{
{input: "アー", want: "aa"},
{input: "カーカ", want: "kaaka"},
{input: "キャーカ", want: "kyaaka"},
{input: "ガーカ", want: "gaaka"},
{input: "ギャーカ", want: "gyaaka"},
{input: "サーカ", want: "saaka"},
{input: "シャーカ", want: "shaaka"},
{input: "ザーカ", want: "zaaka"},
... | explode_data.jsonl/11357 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 564
} | [
2830,
3393,
1143,
283,
263,
5584,
32,
1155,
353,
8840,
836,
8,
341,
22427,
1669,
3056,
42092,
515,
197,
197,
90,
1355,
25,
330,
127599,
497,
1366,
25,
330,
5305,
7115,
197,
197,
90,
1355,
25,
330,
70393,
37148,
104,
497,
1366,
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 TestValidateDeployNOKNilChaincodeSpec(t *testing.T) {
state := make(map[string]map[string][]byte)
state["lscc"] = make(map[string][]byte)
v := newValidationInstance(state)
ccname := "mycc"
ccver := "1"
defaultPolicy, err := getSignedByMSPAdminPolicy(mspid)
assert.NoError(t, err)
res, err := createCCData... | explode_data.jsonl/42501 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 674
} | [
2830,
3393,
17926,
69464,
45,
3925,
19064,
18837,
1851,
8327,
1155,
353,
8840,
836,
8,
341,
24291,
1669,
1281,
9147,
14032,
60,
2186,
14032,
45725,
3782,
340,
24291,
1183,
4730,
638,
1341,
284,
1281,
9147,
14032,
45725,
3782,
692,
5195,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestStateToTerminalViewPortForwards(t *testing.T) {
m := model.Manifest{
Name: "foo",
}.WithDeployTarget(model.K8sTarget{
KubernetesApplySpec: v1alpha1.KubernetesApplySpec{
PortForwardTemplateSpec: &v1alpha1.PortForwardTemplateSpec{
Forwards: []v1alpha1.Forward{
{LocalPort: 8000, ContainerPort: 5... | explode_data.jsonl/54851 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 251
} | [
2830,
3393,
1397,
1249,
47890,
851,
7084,
2461,
4014,
1155,
353,
8840,
836,
8,
341,
2109,
1669,
1614,
72272,
515,
197,
21297,
25,
330,
7975,
756,
197,
7810,
2354,
69464,
6397,
7635,
11352,
23,
82,
6397,
515,
197,
39340,
29827,
28497,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPSITableType(t *testing.T) {
assert.Equal(t, PSITableTypeBAT, psiTableType(74))
for i := 78; i <= 111; i++ {
assert.Equal(t, PSITableTypeEIT, psiTableType(i))
}
assert.Equal(t, PSITableTypeDIT, psiTableType(126))
for i := 64; i <= 65; i++ {
assert.Equal(t, PSITableTypeNIT, psiTableType(i))
}
assert.... | explode_data.jsonl/25233 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 356
} | [
2830,
3393,
5012,
952,
480,
929,
1155,
353,
8840,
836,
8,
341,
6948,
12808,
1155,
11,
11405,
952,
480,
929,
61303,
11,
38026,
2556,
929,
7,
22,
19,
1171,
2023,
600,
1669,
220,
22,
23,
26,
600,
2651,
220,
16,
16,
16,
26,
600,
102... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCollectorWithKafkaStorageType(t *testing.T) {
jaeger := &v1.Jaeger{
ObjectMeta: metav1.ObjectMeta{
Name: "TestCollectorWithIngesterStorageType",
},
Spec: v1.JaegerSpec{
Strategy: "streaming",
Collector: v1.JaegerCollectorSpec{
Options: v1.NewOptions(map[string]interface{}{
"kafka.produ... | explode_data.jsonl/69129 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 529
} | [
2830,
3393,
53694,
2354,
42,
21883,
5793,
929,
1155,
353,
8840,
836,
8,
341,
197,
5580,
1878,
1669,
609,
85,
16,
3503,
64,
1878,
515,
197,
23816,
12175,
25,
77520,
16,
80222,
515,
298,
21297,
25,
330,
2271,
53694,
2354,
25416,
5191,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestUploadDownloadFilenameEscaping(t *testing.T) {
filename := "file%foo.txt"
id := os.Getenv(apiID)
key := os.Getenv(apiKey)
if id == "" || key == "" {
t.Skipf("B2_ACCOUNT_ID or B2_SECRET_KEY unset; skipping integration tests")
}
ctx := context.Background()
// b2_authorize_account
b2, err := Authoriz... | explode_data.jsonl/46957 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 648
} | [
2830,
3393,
13844,
11377,
20759,
36121,
14216,
1155,
353,
8840,
836,
8,
341,
66434,
1669,
330,
1192,
4,
7975,
3909,
1837,
15710,
1669,
2643,
64883,
24827,
915,
340,
23634,
1669,
2643,
64883,
24827,
1592,
692,
743,
877,
621,
1591,
1369,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestStateInitial_Execute(t *testing.T) {
t.Run("handles inbound invitation", func(t *testing.T) {
s := &stateInitial{}
next, finish, halt, err := s.Execute(&context{Inbound: true}, nil)
require.NoError(t, err)
require.IsType(t, &statePrepareResponse{}, next)
require.NotNil(t, finish)
require.False(t, ... | explode_data.jsonl/11779 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 131
} | [
2830,
3393,
1397,
6341,
83453,
1155,
353,
8840,
836,
8,
341,
3244,
16708,
445,
43931,
64943,
28688,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
1903,
1669,
609,
2454,
6341,
16094,
197,
28144,
11,
6248,
11,
26269,
11,
1848,
1669,
274... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestBatchErrorOneError(t *testing.T) {
var batch BatchError
batch.Add(errors.New(err1))
assert.NotNil(t, batch)
assert.Equal(t, err1, batch.Err().Error())
assert.True(t, batch.NotNil())
} | explode_data.jsonl/43670 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 82
} | [
2830,
3393,
21074,
1454,
3966,
1454,
1155,
353,
8840,
836,
8,
341,
2405,
7162,
33904,
1454,
198,
2233,
754,
1904,
38881,
7121,
3964,
16,
1171,
6948,
93882,
1155,
11,
7162,
340,
6948,
12808,
1155,
11,
1848,
16,
11,
7162,
27862,
1005,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
func TestFileStoreSave(t *testing.T) {
path, tearDown := setupConfigFile(t, minimalConfig)
defer tearDown()
fsInner, err := config.NewFileStore(path, false)
require.NoError(t, err)
fs, err := config.NewStoreFromBacking(fsInner, nil, false)
require.NoError(t, err)
defer fs.Close()
newCfg := &model.Config{
Se... | explode_data.jsonl/32384 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 249
} | [
2830,
3393,
1703,
6093,
8784,
1155,
353,
8840,
836,
8,
341,
26781,
11,
32825,
1669,
6505,
2648,
1703,
1155,
11,
17377,
2648,
340,
16867,
32825,
2822,
53584,
31597,
11,
1848,
1669,
2193,
7121,
1703,
6093,
5581,
11,
895,
340,
17957,
35699... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestFragmentationProcess(t *testing.T) {
for _, c := range processTestCases {
t.Run(c.comment, func(t *testing.T) {
f := NewFragmentation(1024, 512, DefaultReassembleTimeout)
for i, in := range c.in {
vv, done := f.Process(in.id, in.first, in.last, in.more, in.vv)
if !reflect.DeepEqual(vv, c.out[i... | explode_data.jsonl/58450 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 424
} | [
2830,
3393,
9488,
367,
7423,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
272,
1669,
2088,
1882,
2271,
37302,
341,
197,
3244,
16708,
1337,
30970,
11,
2915,
1155,
353,
8840,
836,
8,
341,
298,
1166,
1669,
1532,
9488,
367,
7,
16,
15,
17,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 8 |
func TestValidateCert(t *testing.T) {
testCases := map[string]struct {
CertFile string
Modify func(*x509.Certificate) *x509.Certificate
ExpectedType cppki.CertType
AssertErr assert.ErrorAssertionFunc
}{
"as cert": {
CertFile: "cp-as.crt",
ExpectedType: cppki.AS,
AssertErr: asser... | explode_data.jsonl/9854 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 812
} | [
2830,
3393,
17926,
36934,
1155,
353,
8840,
836,
8,
341,
18185,
37302,
1669,
2415,
14032,
60,
1235,
341,
197,
6258,
529,
1703,
257,
914,
198,
197,
197,
44427,
981,
2915,
4071,
87,
20,
15,
24,
727,
20962,
8,
353,
87,
20,
15,
24,
727... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestServer_NoCrash_HandlerClose_Then_ClientClose(t *testing.T) {
testServerResponse(t, func(w http.ResponseWriter, r *http.Request) error {
// nothing
return nil
}, func(st *serverTester) {
st.writeHeaders(HeadersFrameParam{
StreamID: 1,
BlockFragment: st.encodeHeader(),
EndStream: false,... | explode_data.jsonl/71677 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 737
} | [
2830,
3393,
5475,
36989,
16001,
988,
41879,
7925,
62,
12209,
46102,
7925,
1155,
353,
8840,
836,
8,
341,
18185,
5475,
2582,
1155,
11,
2915,
3622,
1758,
37508,
11,
435,
353,
1254,
9659,
8,
1465,
341,
197,
197,
322,
4302,
198,
197,
853,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAsObjectKey(t *testing.T) {
assert.Equal(t, AsObjectKey(
metav1.ObjectMeta{Namespace: "ns1", Name: "thing"}),
client.ObjectKey{Namespace: "ns1", Name: "thing"})
} | explode_data.jsonl/22343 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 72
} | [
2830,
3393,
2121,
1190,
1592,
1155,
353,
8840,
836,
8,
341,
6948,
12808,
1155,
11,
1634,
1190,
1592,
1006,
197,
2109,
295,
402,
16,
80222,
90,
22699,
25,
330,
4412,
16,
497,
3988,
25,
330,
1596,
67432,
197,
25291,
8348,
1592,
90,
22... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.