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 TestUpdateWithSamplingConfig(t *testing.T) {
uiconfig := v1alpha1.NewFreeForm(map[string]interface{}{
"tracking": map[string]interface{}{
"gaID": "UA-000000-2",
},
})
jaeger := v1alpha1.NewJaeger("TestUpdateWithSamplingConfig")
jaeger.Spec.UI.Options = uiconfig
commonSpec := v1alpha1.JaegerCommonSpec{... | explode_data.jsonl/52380 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 306
} | [
2830,
3393,
4289,
2354,
98622,
2648,
1155,
353,
8840,
836,
8,
341,
10676,
1924,
904,
1669,
348,
16,
7141,
16,
7121,
10940,
1838,
9147,
14032,
31344,
67066,
197,
197,
1,
44553,
788,
2415,
14032,
31344,
67066,
298,
197,
1,
6743,
915,
78... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestInt32_Size(t *testing.T) {
testcases := []struct {
name string
s Int32
expect int
}{
{
name: "test Int32 Size, s is empty",
s: Int32{},
expect: 0,
},
{
name: "test Int32 Size, s is not empty",
s: map[int32]struct{}{1: {}, 2: {}, 3: {}},
expect: 3,
},
}
f... | explode_data.jsonl/62321 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 256
} | [
2830,
3393,
1072,
18,
17,
45553,
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,
526,
198,
197,
59403,
197,
197,
515,
298,
11609,
25,
256,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestClient_AutoLogin(t *testing.T) {
t.Parallel()
app := startNewApplication(t)
user := cltest.MustRandomUser(t)
require.NoError(t, app.SessionORM().CreateUser(&user))
sr := sessions.SessionRequest{
Email: user.Email,
Password: cltest.Password,
}
client, _ := app.NewClientAndRenderer()
client.Coo... | explode_data.jsonl/5276 | {
"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,
2959,
1566,
1535,
6231,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
28236,
1669,
1191,
3564,
4988,
1155,
692,
19060,
1669,
1185,
1944,
50463,
13999,
1474,
1155,
340,
17957,
35699,
1155,
11,
906,
20674,
4365,
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... | 1 |
func TestReplicateQueueDownReplicate(t *testing.T) {
defer leaktest.AfterTest(t)()
defer log.Scope(t).Close(t)
ctx := context.Background()
const replicaCount = 3
// The goal of this test is to ensure that down replication occurs correctly
// using the replicate queue, and to ensure that's the case, the test
// ... | explode_data.jsonl/54893 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 673
} | [
2830,
3393,
18327,
48795,
7554,
4454,
18327,
48795,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
36892,
2271,
1155,
8,
741,
16867,
1487,
77940,
1155,
568,
7925,
1155,
340,
20985,
1669,
2266,
19047,
741,
4777,
36954,
2507,
284,
220,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestTxCannotCommitAfterRollback(t *testing.T) {
db := newTestDB(t, "tx_status")
defer closeDB(t, db)
// First check query reporting is correct.
var txStatus string
err := db.QueryRow("SELECT|tx_status|tx_status|").Scan(&txStatus)
if err != nil {
t.Fatal(err)
}
if g, w := txStatus, "autocommit"; g != w {... | explode_data.jsonl/16015 | {
"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,
51,
12125,
3401,
33441,
6025,
32355,
1419,
1155,
353,
8840,
836,
8,
341,
20939,
1669,
501,
2271,
3506,
1155,
11,
330,
3998,
4773,
1138,
16867,
3265,
3506,
1155,
11,
2927,
692,
197,
322,
5512,
1779,
3239,
12827,
374,
4396,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestReadConfigFile(t *testing.T) {
wd, _ := os.Getwd()
conf := DefaultConfig()
ReadConfigFile(conf, fmt.Sprintf("%s/config_test.yml", wd))
assert.Equal(t, "mysql", conf.Database.Host)
assert.Equal(t, int16(3306), conf.Database.Port)
} | explode_data.jsonl/16776 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 99
} | [
2830,
3393,
4418,
2648,
1703,
1155,
353,
8840,
836,
8,
341,
197,
6377,
11,
716,
1669,
2643,
2234,
6377,
741,
67850,
1669,
7899,
2648,
741,
96043,
2648,
1703,
29879,
11,
8879,
17305,
4430,
82,
14730,
4452,
33936,
497,
45404,
4390,
6948,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestGossipReception(t *testing.T) {
t.Parallel()
signalChan := make(chan struct{})
rawblock := &pcomm.Block{
Header: &pcomm.BlockHeader{
Number: uint64(1),
},
Data: &pcomm.BlockData{
Data: [][]byte{},
},
Metadata: &pcomm.BlockMetadata{
Metadata: [][]byte{
{}, {}, {}, {},
},
},
}
b,... | explode_data.jsonl/5641 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 850
} | [
2830,
3393,
38,
41473,
693,
995,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
81319,
46019,
1669,
1281,
35190,
2036,
37790,
76559,
4574,
1669,
609,
79,
3621,
28477,
515,
197,
197,
4047,
25,
609,
79,
3621,
28477,
4047,
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... | 1 |
func TestCheckForServerUpgrade(t *testing.T) {
now := time.Unix(1552599223, 0).UTC()
serverVersion := "5.10.0"
makePlugin := func(api *plugintest.API) *Plugin {
p := &Plugin{
serverVersion: serverVersion,
}
p.SetAPI(api)
return p
}
t.Run("should return true when an upgrade has occurred", func(t *test... | explode_data.jsonl/50020 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 843
} | [
2830,
3393,
3973,
2461,
5475,
43861,
1155,
353,
8840,
836,
8,
341,
80922,
1669,
882,
10616,
941,
7,
16,
20,
20,
17,
20,
24,
24,
17,
17,
18,
11,
220,
15,
568,
21183,
741,
41057,
5637,
1669,
330,
20,
13,
16,
15,
13,
15,
1837,
77... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestCancelExchangeOrder(t *testing.T) {
b.SetDefaults()
TestSetup(t)
if areTestAPIKeysSet() && !canManipulateRealOrders {
t.Skip("API keys set, canManipulateRealOrders false, skipping test")
}
currencyPair := currency.NewPair(currency.LTC, currency.BTC)
var orderCancellation = &exchange.OrderCancellatio... | explode_data.jsonl/49007 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 282
} | [
2830,
3393,
9269,
31564,
4431,
1155,
353,
8840,
836,
8,
341,
2233,
4202,
16273,
741,
73866,
21821,
1155,
692,
743,
525,
2271,
7082,
8850,
1649,
368,
1009,
753,
4814,
92876,
6334,
12768,
24898,
341,
197,
3244,
57776,
445,
7082,
6894,
738... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestHandshakeClientCertRSAPSS(t *testing.T) {
cert, err := x509.ParseCertificate(testRSAPSSCertificate)
if err != nil {
panic(err)
}
rootCAs := x509.NewCertPool()
rootCAs.AddCert(cert)
config := testConfig.Clone()
// Use GetClientCertificate to bypass the client certificate selection logic.
config.GetCl... | explode_data.jsonl/27712 | {
"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,
2314,
29661,
2959,
36934,
11451,
2537,
1220,
1155,
353,
8840,
836,
8,
341,
1444,
529,
11,
1848,
1669,
856,
20,
15,
24,
8937,
33202,
8623,
11451,
2537,
1220,
33202,
340,
743,
1848,
961,
2092,
341,
197,
30764,
3964,
340,
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 TestValidateQueueFails(t *testing.T) {
tests := []struct {
upstreamQueue *v1.UpstreamQueue
msg string
}{
{
upstreamQueue: &v1.UpstreamQueue{Size: -1, Timeout: "10s"},
msg: "upstream queue with invalid size",
},
{
upstreamQueue: &v1.UpstreamQueue{Size: 10, Timeout: "-10"},
... | explode_data.jsonl/65880 | {
"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,
17926,
7554,
37,
6209,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
1235,
341,
197,
59810,
4027,
7554,
353,
85,
16,
60828,
4027,
7554,
198,
197,
21169,
1843,
914,
198,
197,
59403,
197,
197,
515,
298,
59810,
4027,
7554,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestLocalInvoker(t *testing.T) {
test.IntegrationTest(t)
t.Run("Run local reconciler: successfully finished reconciliation", func(t *testing.T) {
reconRepo, opEntity := runLocalReconciler(t, false)
requireOperationState(t, reconRepo, opEntity, model.OperationStateDone)
})
t.Run("Run local reconciler: fai... | explode_data.jsonl/34704 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 183
} | [
2830,
3393,
7319,
47668,
1155,
353,
8840,
836,
8,
341,
18185,
7371,
17376,
2271,
1155,
692,
3244,
16708,
445,
6727,
2205,
31445,
5769,
25,
7790,
8060,
57655,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
17200,
443,
25243,
11,
1179,
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 TestLegacyQuerySeigniorageProceeds(t *testing.T) {
input := CreateTestInput(t)
querier := NewLegacyQuerier(input.TreasuryKeeper, input.Cdc)
targetSeigniorage := sdk.NewInt(10)
input.TreasuryKeeper.RecordEpochInitialIssuance(input.Ctx)
input.Ctx = input.Ctx.WithBlockHeight(int64(core.BlocksPerWeek))
input.B... | explode_data.jsonl/6693 | {
"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,
77415,
2859,
1514,
622,
2462,
424,
84338,
82,
1155,
353,
8840,
836,
8,
341,
22427,
1669,
4230,
2271,
2505,
1155,
340,
197,
15959,
1268,
1669,
1532,
77415,
2183,
261,
1268,
5384,
836,
265,
26102,
77233,
11,
1946,
727,
7628,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestParseForStatementCondition(t *testing.T) {
p := createParser(`for x < 5 {}`)
bvmUtils.Assert(t, isForStatement(p), "should detect for statement")
parseForStatement(p)
bvmUtils.Assert(t, len(p.errs) == 0, "should be error-free")
first := p.scope.Next()
bvmUtils.Assert(t, first.Type() == ast.ForStatement,... | explode_data.jsonl/49716 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 230
} | [
2830,
3393,
14463,
2461,
8636,
10547,
1155,
353,
8840,
836,
8,
341,
3223,
1669,
1855,
6570,
5809,
1958,
856,
366,
220,
20,
4687,
24183,
2233,
7338,
4209,
11711,
1155,
11,
374,
2461,
8636,
1295,
701,
330,
5445,
11140,
369,
5114,
1138,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestMessagerCacheDupKey(t *testing.T) {
mc := newCache(10)
if !mc.Add(&MessageRow{
TimeNext: 1,
Epoch: 0,
Row: []sqltypes.Value{sqltypes.NewVarBinary("row01")},
}) {
t.Fatal("Add returned false")
}
if !mc.Add(&MessageRow{
TimeNext: 1,
Epoch: 0,
Row: []sqltypes.Value{sqltypes.NewV... | explode_data.jsonl/24949 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 369
} | [
2830,
3393,
84423,
1409,
8233,
85713,
1592,
1155,
353,
8840,
836,
8,
341,
97662,
1669,
501,
8233,
7,
16,
15,
340,
743,
753,
12887,
1904,
2099,
2052,
3102,
515,
197,
67567,
5847,
25,
220,
16,
345,
197,
197,
44338,
25,
262,
220,
15,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 5 |
func TestCreatePipelineVersion_CreatePipelineVersionFileError(t *testing.T) {
store := NewFakeClientManagerOrFatal(util.NewFakeTimeForEpoch())
defer store.Close()
manager := NewResourceManager(store)
// Create a pipeline.
_, err := manager.CreatePipeline("pipeline", "", []byte(strings.TrimSpace(complexPipeline)))... | explode_data.jsonl/77072 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 511
} | [
2830,
3393,
4021,
34656,
5637,
34325,
34656,
5637,
1703,
1454,
1155,
353,
8840,
836,
8,
341,
57279,
1669,
1532,
52317,
2959,
2043,
2195,
62396,
67811,
7121,
52317,
1462,
2461,
44338,
2398,
16867,
3553,
10421,
741,
92272,
1669,
1532,
32498,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestImageIsDirtyAfterContainerBuild(t *testing.T) {
f := newIBDFixture(t, k8s.EnvGKE)
defer f.TearDown()
manifest := NewSanchoDockerBuildManifest(f)
iTargetID1 := manifest.ImageTargets[0].ID()
result1 := store.NewLiveUpdateBuildResult(
iTargetID1,
[]container.ID{container.ID("12345")})
stateSet := stor... | explode_data.jsonl/38258 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 292
} | [
2830,
3393,
1906,
3872,
36485,
6025,
4502,
11066,
1155,
353,
8840,
836,
8,
341,
1166,
1669,
501,
3256,
5262,
12735,
1155,
11,
595,
23,
82,
81214,
38,
3390,
340,
16867,
282,
836,
682,
4454,
2822,
197,
42315,
1669,
1532,
23729,
958,
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... | 2 |
func TestGetOrganizationDetail(t *testing.T) {
t.Log("Test catalogrepository organization detail")
catalogRepo := NewCatalogRepository(db)
organization, err := catalogRepo.GetOrganizationDetail(context.TODO(), "6043d76e94df8de741c2c0d6")
assert.Nil(t, err)
assert.Equal(t, organization.Name, "restaurant")
} | explode_data.jsonl/58784 | {
"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,
1949,
41574,
10649,
1155,
353,
8840,
836,
8,
341,
3244,
5247,
445,
2271,
16403,
23319,
7321,
7716,
5130,
1444,
7750,
25243,
1669,
1532,
41606,
4624,
9791,
692,
197,
23899,
11,
1848,
1669,
16403,
25243,
2234,
41574,
10649,
5378... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestX5C_Getters(t *testing.T) {
p, err := generateX5C(nil)
assert.FatalError(t, err)
id := "x5c/" + p.Name
if got := p.GetID(); got != id {
t.Errorf("X5C.GetID() = %v, want %v:%v", got, p.Name, id)
}
if got := p.GetName(); got != p.Name {
t.Errorf("X5C.GetName() = %v, want %v", got, p.Name)
}
if got :=... | explode_data.jsonl/44601 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 291
} | [
2830,
3393,
55,
20,
34,
13614,
5045,
1155,
353,
8840,
836,
8,
341,
3223,
11,
1848,
1669,
6923,
55,
20,
34,
27907,
340,
6948,
26133,
1454,
1155,
11,
1848,
340,
15710,
1669,
330,
87,
20,
66,
11225,
488,
281,
2967,
198,
743,
2684,
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... | 7 |
func Test_parseAndValidatePort(t *testing.T) {
type args struct {
port string
}
tests := []struct {
name string
args args
want uint16
wantErr bool
}{
{
name: "0 should fail",
args: args{
port: "0",
},
want: 0,
wantErr: true,
},
{
name: "over 65535 should fail",
a... | explode_data.jsonl/66904 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 569
} | [
2830,
3393,
21039,
3036,
17926,
7084,
1155,
353,
8840,
836,
8,
341,
13158,
2827,
2036,
341,
197,
52257,
914,
198,
197,
532,
78216,
1669,
3056,
1235,
341,
197,
11609,
262,
914,
198,
197,
31215,
262,
2827,
198,
197,
50780,
262,
2622,
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 TestAppConfig_FindContextByName(t *testing.T) {
config := getAppConfig()
tests := []struct {
name string
}{
{"first-context"},
{"non-existing"},
}
for _, test := range tests {
t.Run(test.name, func(t *testing.T) {
_, err := config.FindContextByName(test.name)
switch test.name {
case "first-c... | explode_data.jsonl/6631 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 232
} | [
2830,
3393,
2164,
2648,
95245,
1972,
16898,
1155,
353,
8840,
836,
8,
341,
25873,
1669,
76382,
2648,
741,
78216,
1669,
3056,
1235,
341,
197,
11609,
914,
198,
197,
59403,
197,
197,
4913,
3896,
63633,
7115,
197,
197,
4913,
6280,
49357,
711... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestMarshalSchema(t *testing.T) {
for _, u := range []ent.Interface{User{}, &User{}} {
buf, err := MarshalSchema(u)
require.NoError(t, err)
schema, err := UnmarshalSchema(buf)
require.NoError(t, err)
require.Equal(t, "User", schema.Name)
require.Len(t, schema.Fields, 8)
require.Equal(t, "age", sche... | explode_data.jsonl/468 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1401
} | [
2830,
3393,
55438,
8632,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
575,
1669,
2088,
3056,
306,
41065,
90,
1474,
22655,
609,
1474,
90,
3417,
341,
197,
26398,
11,
1848,
1669,
35667,
8632,
8154,
340,
197,
17957,
35699,
1155,
11,
1848,
69... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestCreateCheckpoint(t *testing.T) {
defer leaktest.AfterTest(t)()
dir, cleanup := testutils.TempDir(t)
defer cleanup()
rocksDB, err := NewRocksDB(
RocksDBConfig{
Settings: cluster.MakeTestingClusterSettings(),
Dir: dir,
},
RocksDBCache{},
)
db := Engine(rocksDB) // be impl neutral from n... | explode_data.jsonl/38118 | {
"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,
4021,
92688,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
36892,
2271,
1155,
8,
2822,
48532,
11,
21290,
1669,
1273,
6031,
65009,
6184,
1155,
340,
16867,
21290,
2822,
197,
299,
14553,
3506,
11,
1848,
1669,
1532,
49,
2518... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestECDSAKeyGenEphemeral(t *testing.T) {
t.Parallel()
provider, _, cleanup := currentTestConfig.Provider(t)
defer cleanup()
k, err := provider.KeyGen(&bccsp.ECDSAKeyGenOpts{Temporary: true})
if err != nil {
t.Fatalf("Failed generating ECDSA key [%s]", err)
}
if k == nil {
t.Fatal("Failed generating ECD... | explode_data.jsonl/29254 | {
"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,
7498,
72638,
1592,
9967,
36,
59941,
3253,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
741,
197,
19979,
11,
8358,
21290,
1669,
1482,
2271,
2648,
36208,
1155,
340,
16867,
21290,
2822,
16463,
11,
1848,
1669,
9109,
9610,
99... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestGetAndSet(t *testing.T) {
cache := NewCache(interval)
for i := 0; i < 1000; i++ {
cache.Set(key(i), value(i), interval)
}
for i := 0; i < 1000; i++ {
v, ok := cache.Get(key(i))
if assert.True(t, ok) {
val := v.(string)
assert.Equal(t, value(i), val)
}
}
} | explode_data.jsonl/8060 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 136
} | [
2830,
3393,
1949,
3036,
1649,
1155,
353,
8840,
836,
8,
220,
341,
52680,
1669,
1532,
8233,
55098,
692,
2023,
600,
1669,
220,
15,
26,
600,
366,
220,
16,
15,
15,
15,
26,
600,
1027,
341,
197,
52680,
4202,
4857,
1956,
701,
897,
1956,
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... | 4 |
func TestNoData(t *testing.T) {
m := NewStringMatcher([]string{"foo", "baz", "bar"})
hits := m.Match([]byte(""))
assert(t, len(hits) == 0)
hits = m.MatchThreadSafe([]byte(""))
assert(t, len(hits) == 0)
} | explode_data.jsonl/22642 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 92
} | [
2830,
3393,
2753,
1043,
1155,
353,
8840,
836,
8,
341,
2109,
1669,
1532,
703,
37554,
10556,
917,
4913,
7975,
497,
330,
42573,
497,
330,
2257,
23625,
9598,
1199,
1669,
296,
36062,
10556,
3782,
73303,
6948,
1155,
11,
2422,
3203,
1199,
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 TestStringifyFundraiserPathParams(t *testing.T) {
path := NewFundraiserParams(4, types.CoinType, 22)
require.Equal(t, "44'/118'/4'/0/22", path.String())
path = NewFundraiserParams(4, types.CoinType, 57)
require.Equal(t, "44'/118'/4'/0/57", path.String())
path = NewFundraiserParams(4, 12345, 57)
require.Equ... | explode_data.jsonl/68948 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 151
} | [
2830,
3393,
703,
1437,
58340,
956,
12059,
1820,
4870,
1155,
353,
8840,
836,
8,
341,
26781,
1669,
1532,
58340,
956,
12059,
4870,
7,
19,
11,
4494,
727,
1961,
929,
11,
220,
17,
17,
340,
17957,
12808,
1155,
11,
330,
19,
19,
20177,
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 TestRuleUseKeyWord(t *testing.T) {
common.Log.Debug("Entering function: %s", common.GetFunctionName())
sqls := [][]string{
{
"CREATE TABLE tbl (`select` int)",
"CREATE TABLE `select` (a int)",
"ALTER TABLE tbl ADD COLUMN `select` varchar(10)",
},
{
"CREATE TABLE tbl (a int)",
"ALTER TABLE tb... | explode_data.jsonl/76774 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 428
} | [
2830,
3393,
11337,
10253,
1592,
10879,
1155,
353,
8840,
836,
8,
341,
83825,
5247,
20345,
445,
82867,
729,
25,
1018,
82,
497,
4185,
2234,
5152,
675,
2398,
30633,
82,
1669,
52931,
917,
515,
197,
197,
515,
298,
197,
1,
22599,
14363,
2117... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 Test_skip_object(t *testing.T) {
iter := ParseString(ConfigDefault, `}`)
iter.skipObject()
if iter.head != 1 {
t.Fatal(iter.head)
}
iter = ParseString(ConfigDefault, `a}`)
iter.skipObject()
if iter.head != 2 {
t.Fatal(iter.head)
}
iter = ParseString(ConfigDefault, `{}}a`)
iter.skipObject()
if iter.h... | explode_data.jsonl/7300 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 281
} | [
2830,
3393,
44830,
5314,
1155,
353,
8840,
836,
8,
341,
79924,
1669,
14775,
703,
33687,
3675,
11,
1565,
27085,
79924,
36596,
1190,
741,
743,
5367,
16042,
961,
220,
16,
341,
197,
3244,
26133,
27070,
16042,
340,
197,
532,
79924,
284,
14775... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestLQ(t *testing.T) {
for _, test := range []struct {
m, n int
}{
{5, 5},
{5, 10},
} {
m := test.m
n := test.n
a := NewDense(m, n, nil)
for i := 0; i < m; i++ {
for j := 0; j < n; j++ {
a.Set(i, j, rand.NormFloat64())
}
}
var want Dense
want.CloneFrom(a)
var lq LQ
lq.Factoriz... | explode_data.jsonl/15094 | {
"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,
43,
48,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
1273,
1669,
2088,
3056,
1235,
341,
197,
2109,
11,
308,
526,
198,
197,
59403,
197,
197,
90,
20,
11,
220,
20,
1583,
197,
197,
90,
20,
11,
220,
16,
15,
1583,
197,
92,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestFileStoreGetEnivironmentOverrides(t *testing.T) {
t.Run("get override for a string variable", func(t *testing.T) {
path, tearDown := setupConfigFile(t, testConfig)
defer tearDown()
fsInner, err := config.NewFileStore(path, false)
require.NoError(t, err)
fs, err := config.NewStoreFromBacking(fsInner... | explode_data.jsonl/32380 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 2830
} | [
2830,
3393,
1703,
6093,
1949,
1702,
344,
2475,
478,
80010,
1155,
353,
8840,
836,
8,
341,
3244,
16708,
445,
455,
2812,
369,
264,
914,
3890,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
26781,
11,
32825,
1669,
6505,
2648,
1703,
1155,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestToken(t *testing.T) {
d := NewDecoder(strings.NewReader(testInput))
d.Entity = testEntity
for i, want := range cookedTokens {
have, err := d.Token()
if err != nil {
t.Fatalf("token %d: unexpected error: %s", i, err)
}
if !reflect.DeepEqual(have, want) {
t.Errorf("token %d = %#v want %#v", i, ... | explode_data.jsonl/48612 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 144
} | [
2830,
3393,
3323,
1155,
353,
8840,
836,
8,
341,
2698,
1669,
1532,
20732,
51442,
68587,
8623,
2505,
1171,
2698,
9899,
284,
1273,
3030,
271,
2023,
600,
11,
1366,
1669,
2088,
29105,
29300,
341,
197,
9598,
523,
11,
1848,
1669,
294,
32277,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestEmptyValuesDoNotCauseDrift(t *testing.T) {
tests := map[string]struct {
platformFixture string
templateFixture string
expectedAction string
}{
"Field not defined in template": {
platformFixture: "bc-platform-defaulted.yml",
templateFixture: "bc-template-defaulted.yml",
expectedAction: "No... | explode_data.jsonl/33773 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 447
} | [
2830,
3393,
3522,
6227,
5404,
2623,
60912,
8847,
2085,
1155,
353,
8840,
836,
8,
1476,
78216,
1669,
2415,
14032,
60,
1235,
341,
197,
197,
15734,
18930,
914,
198,
197,
22832,
18930,
914,
198,
197,
42400,
2512,
220,
914,
198,
197,
59403,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 4 |
func Test_newClusterChecksRunnerDeploymentFromInstance_UserVolumes(t *testing.T) {
userVolumes := []corev1.Volume{
{
Name: "tmp",
VolumeSource: corev1.VolumeSource{
HostPath: &corev1.HostPathVolumeSource{
Path: "/tmp",
},
},
},
}
userVolumeMounts := []corev1.VolumeMount{
{
Name: "... | explode_data.jsonl/60640 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1315
} | [
2830,
3393,
5921,
28678,
49820,
19486,
75286,
3830,
2523,
31339,
96325,
1155,
353,
8840,
836,
8,
341,
19060,
96325,
1669,
3056,
98645,
16,
79106,
515,
197,
197,
515,
298,
21297,
25,
330,
5173,
756,
298,
17446,
4661,
3608,
25,
6200,
85,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestMultiRangeScanReverseScanDeleteResolve(t *testing.T) {
defer leaktest.AfterTest(t)()
s, _ := startNoSplitMergeServer(t)
ctx := context.TODO()
defer s.Stopper().Stop(ctx)
db := s.DB()
if err := setupMultipleRanges(ctx, db, "b"); err != nil {
t.Fatal(err)
}
// Write keys before, at, and after the spli... | explode_data.jsonl/36459 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 712
} | [
2830,
3393,
20358,
6046,
26570,
45695,
26570,
6435,
56808,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
36892,
2271,
1155,
8,
741,
1903,
11,
716,
1669,
1191,
2753,
20193,
52096,
5475,
1155,
340,
20985,
1669,
2266,
90988,
741,
16867,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPasswd(t *testing.T) {
test.DropPrivilege(t)
defer test.ResetPrivilege(t)
uid := os.Getuid()
_, err := Passwd("/fake", "/fake", uid)
if err == nil {
t.Errorf("should have failed with bad passwd file")
}
_, err = Passwd("/etc/passwd", "/home", uid)
if err != nil {
t.Errorf("should have passed with... | explode_data.jsonl/74251 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 252
} | [
2830,
3393,
12187,
6377,
1155,
353,
8840,
836,
8,
341,
18185,
21688,
32124,
42769,
1155,
340,
16867,
1273,
36660,
32124,
42769,
1155,
692,
197,
2423,
1669,
2643,
2234,
2423,
2822,
197,
6878,
1848,
1669,
9970,
6377,
4283,
30570,
497,
3521,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 5 |
func TestPlayer_Armor(t *testing.T) {
pl := playerWithProperty("m_ArmorValue", st.PropertyValue{IntVal: 95})
assert.Equal(t, 95, pl.Armor())
} | explode_data.jsonl/12191 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 53
} | [
2830,
3393,
4476,
1566,
8719,
269,
1155,
353,
8840,
836,
8,
341,
72213,
1669,
2781,
2354,
3052,
445,
76,
1566,
8719,
269,
1130,
497,
357,
15727,
1130,
90,
1072,
2208,
25,
220,
24,
20,
8824,
6948,
12808,
1155,
11,
220,
24,
20,
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 |
func TestSpaceService_Content(t *testing.T) {
testCases := []struct {
name string
spaceKey, depth string
expand []string
startAt, maxResults int
mockFile string
wantHTTPMethod string
endpoint string
context context.Context
wantHT... | explode_data.jsonl/39248 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 2400
} | [
2830,
3393,
9914,
1860,
78383,
1155,
353,
8840,
836,
8,
1476,
18185,
37302,
1669,
3056,
1235,
341,
197,
11609,
394,
914,
198,
197,
1903,
1306,
1592,
11,
7990,
257,
914,
198,
197,
197,
32317,
1060,
3056,
917,
198,
197,
21375,
1655,
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... | 7 |
func TestGetSpec(t *testing.T) {
ctx := context.Background()
ts := newServer("")
defer ts.Close()
c, err := NewClient(ts.Client(), "", ts.URL, "default", "myapp", nil)
if err != nil {
t.Errorf("should not raise error: %v", err)
}
_, err = c.GetSpec(ctx)
if err != nil {
t.Errorf("GetSpec() should not raise e... | explode_data.jsonl/69797 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 138
} | [
2830,
3393,
1949,
8327,
1155,
353,
8840,
836,
8,
341,
20985,
1669,
2266,
19047,
741,
57441,
1669,
501,
5475,
31764,
16867,
10591,
10421,
741,
1444,
11,
1848,
1669,
1532,
2959,
35864,
11716,
1507,
7342,
10591,
20893,
11,
330,
2258,
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... | 3 |
func TestTypeSystem_ObjectsMustHaveFields_RejectsAnObjectTypeWithIncorrectlyNamedFields(t *testing.T) {
badObject := graphql.NewObject(graphql.ObjectConfig{
Name: "SomeObject",
Fields: graphql.Fields{
"bad-name-with-dashes": &graphql.Field{
Type: graphql.String,
},
},
})
_, err := schemaWithFieldType... | explode_data.jsonl/79145 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 222
} | [
2830,
3393,
929,
2320,
62,
11543,
31776,
12116,
8941,
50693,
583,
82,
2082,
49530,
2354,
40468,
398,
15810,
8941,
1155,
353,
8840,
836,
8,
341,
2233,
329,
1190,
1669,
48865,
7121,
1190,
24312,
1470,
8348,
2648,
515,
197,
21297,
25,
330,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 3 |
func TestRandPop50k(t *testing.T) {
for _, bitarray := range testBitArrayTypes {
t.Run(fmt.Sprintf(bitarray.name), func(t *testing.T) {
k2 := testPopulateRand(t, bitarray.create, 50000, true)
t.Logf("%f bpl", k2.Stats().BitsPerLink)
})
}
} | explode_data.jsonl/65335 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 112
} | [
2830,
3393,
56124,
11598,
20,
15,
74,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
2699,
1653,
1669,
2088,
1273,
8344,
1857,
4173,
341,
197,
3244,
16708,
28197,
17305,
54672,
1653,
2644,
701,
2915,
1155,
353,
8840,
836,
8,
341,
298,
1646... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestOptions(t *testing.T) {
resp := getTestResponse("OPTIONS", "/options", "", nil, nil)
if resp.headers["Access-Control-Allow-Methods"][0] != "POST, GET, OPTIONS" {
t.Fatalf("TestOptions - Access-Control-Allow-Methods failed")
}
if resp.headers["Access-Control-Max-Age"][0] != "1000" {
... | explode_data.jsonl/40628 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 151
} | [
2830,
3393,
3798,
1155,
353,
8840,
836,
8,
341,
262,
9039,
1669,
633,
2271,
2582,
445,
56929,
497,
3521,
2875,
497,
7342,
2092,
11,
2092,
340,
262,
421,
9039,
18022,
1183,
6054,
25056,
33348,
95490,
18121,
15,
60,
961,
330,
2946,
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... | 3 |
func TestTxReceipt_FulfilledRunlog(t *testing.T) {
tests := []struct {
name string
path string
want bool
}{
{"basic", "testdata/getTransactionReceipt.json", false},
{"runlog request", "testdata/runlogReceipt.json", false},
{"runlog response", "testdata/responseReceipt.json", true},
}
for _, test := ran... | explode_data.jsonl/63843 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 204
} | [
2830,
3393,
31584,
67461,
1400,
84993,
6727,
839,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
1235,
341,
197,
11609,
914,
198,
197,
26781,
914,
198,
197,
50780,
1807,
198,
197,
59403,
197,
197,
4913,
22342,
497,
330,
92425,
23302,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_Properties_ValidateNetworkPlugin(t *testing.T) {
p := &Properties{}
p.OrchestratorProfile = &OrchestratorProfile{}
p.OrchestratorProfile.OrchestratorType = Kubernetes
for _, policy := range NetworkPluginValues {
p.OrchestratorProfile.KubernetesConfig = &KubernetesConfig{}
p.OrchestratorProfile.Kubern... | explode_data.jsonl/17865 | {
"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,
1088,
9249,
62,
17926,
12320,
11546,
1155,
353,
8840,
836,
8,
341,
3223,
1669,
609,
7903,
16094,
3223,
90449,
331,
15111,
850,
8526,
284,
609,
2195,
331,
15111,
850,
8526,
16094,
3223,
90449,
331,
15111,
850,
8526,
90449,
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... | 4 |
func Test_createWorkflowPod_emissary(t *testing.T) {
t.Run("NoCommand", func(t *testing.T) {
woc := newWoc()
_, err := woc.createWorkflowPod(context.Background(), "", []apiv1.Container{{Image: "docker/whalesay:nope"}}, &wfv1.Template{Name: "my-tmpl"}, &createWorkflowPodOpts{})
assert.EqualError(t, err, "failed t... | explode_data.jsonl/75382 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1007
} | [
2830,
3393,
8657,
62768,
23527,
22504,
1038,
658,
1155,
353,
8840,
836,
8,
341,
3244,
16708,
445,
2753,
4062,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
6692,
509,
1669,
501,
54,
509,
741,
197,
197,
6878,
1848,
1669,
289,
509,
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 TestTryingToOpenTwoTransactions(t *testing.T) {
payload := "my-payload"
trType := TransactionType("my-type")
ctx := context.Background()
man := NewTxManager(&fakeBroadcaster{})
tx1, err := man.BeginTransaction(ctx, trType, payload)
require.Nil(t, err)
tx2, err := man.BeginTransaction(ctx, trType, payload... | explode_data.jsonl/5850 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 188
} | [
2830,
3393,
55862,
1249,
5002,
11613,
48761,
1155,
353,
8840,
836,
8,
341,
76272,
1669,
330,
2408,
2268,
6989,
698,
25583,
929,
1669,
17869,
929,
445,
2408,
10604,
1138,
20985,
1669,
2266,
19047,
2822,
197,
1515,
1669,
1532,
31584,
2043,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestInvitedState_Execute(t *testing.T) {
t.Run("rejects msgs other than invitations", func(t *testing.T) {
others := []service.DIDCommMsg{
service.NewDIDCommMsgMap(Request{Type: RequestMsgType}),
service.NewDIDCommMsgMap(Response{Type: ResponseMsgType}),
service.NewDIDCommMsgMap(model.Ack{Type: AckMsgT... | explode_data.jsonl/2095 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 801
} | [
2830,
3393,
15174,
1608,
1397,
83453,
1155,
353,
8840,
836,
8,
341,
3244,
16708,
445,
46996,
82,
41270,
1008,
1091,
58669,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
22229,
2985,
1669,
3056,
7936,
909,
915,
17977,
6611,
515,
298,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestRenterUploadInode(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
rt, err := newRenterTester(t.Name())
if err != nil {
t.Fatal(err)
}
defer rt.Close()
testUploadPath, err := ioutil.TempDir("", t.Name())
if err != nil {
t.Fatal(err)
}
defer os.RemoveAll(testUploadPath)
ec, err := NewRSCode... | explode_data.jsonl/39899 | {
"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,
49,
1950,
13844,
641,
534,
1155,
353,
8840,
836,
8,
341,
743,
7497,
55958,
368,
341,
197,
3244,
57776,
7039,
741,
197,
532,
55060,
11,
1848,
1669,
501,
49,
1950,
58699,
1155,
2967,
2398,
743,
1848,
961,
2092,
341,
197,
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... | 7 |
func TestManifestGenerateFlagAliases(t *testing.T) {
inPath := filepath.Join(testDataDir, "input/all_on.yaml")
gotSet, err := runManifestGenerate([]string{inPath}, "--set revision=foo", snapshotCharts)
if err != nil {
t.Fatal(err)
}
gotAlias, err := runManifestGenerate([]string{inPath}, "--revision=foo --manifes... | explode_data.jsonl/47914 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 248
} | [
2830,
3393,
38495,
31115,
12135,
95209,
1155,
353,
8840,
836,
8,
341,
17430,
1820,
1669,
26054,
22363,
8623,
1043,
6184,
11,
330,
1355,
31406,
4470,
33406,
1138,
3174,
354,
1649,
11,
1848,
1669,
1598,
38495,
31115,
10556,
917,
90,
258,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestFromXDRBuildSignEncode(t *testing.T) {
expectedUnsigned := "AAAAAgAAAADg3G3hclysZlFitS+s5zWyiiJD5B0STWy5LXCj6i5yxQAAAGQAIiCNAAAAGwAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAVuZXd0eAAAAAAAAAEAAAAAAAAAAAAAAACE4N7avBtJL576CIWTzGCbGPvSlVfMQAOjcYbSsSF2VAAAAAAF9eEAAAAAAAAAAAHqLnLFAAAAQAz221zc6QuNPFsmBkLMzd1QPXuNbDabMmdh3E... | explode_data.jsonl/20697 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1164
} | [
2830,
3393,
3830,
55,
7687,
11066,
7264,
32535,
1155,
353,
8840,
836,
8,
341,
42400,
56421,
1669,
330,
25699,
9042,
50107,
1808,
70,
18,
38,
18,
38052,
60392,
57,
75,
23346,
50,
67797,
20,
89,
54,
37164,
49915,
20,
33,
15,
784,
6690... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAccService(t *testing.T) {
var serviceID int
resource.Test(t, resource.TestCase{
PreCheck: func() { preCheck(t) },
ProviderFactories: providerFactories,
Steps: []resource.TestStep{
{
Config: testAccServiceConfig,
Check: resource.ComposeTestCheckFunc(
testCheckResourceAttrs("mo... | explode_data.jsonl/82117 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1319
} | [
2830,
3393,
14603,
1860,
1155,
353,
8840,
836,
8,
341,
2405,
2473,
915,
526,
271,
50346,
8787,
1155,
11,
5101,
31363,
515,
197,
197,
4703,
3973,
25,
688,
2915,
368,
314,
855,
3973,
1155,
8,
1153,
197,
197,
5179,
17417,
2433,
25,
910... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestRandomizedGenState(t *testing.T) {
interfaceRegistry := codectypes.NewInterfaceRegistry()
cdc := codec.NewProtoCodec(interfaceRegistry)
s := rand.NewSource(1)
r := rand.New(s)
simState := module.SimulationState{
AppParams: make(simtypes.AppParams),
Cdc: cdc,
Rand: r,
NumBonde... | explode_data.jsonl/67875 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 440
} | [
2830,
3393,
13999,
1506,
9967,
1397,
1155,
353,
8840,
836,
8,
341,
58915,
1564,
15603,
1669,
20329,
439,
1804,
7121,
5051,
15603,
741,
1444,
7628,
1669,
34647,
7121,
31549,
36913,
75487,
15603,
692,
1903,
1669,
10382,
7121,
3608,
7,
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 TestReverse(t *testing.T) {
if Reverse("abcdefg") != "gfedcba" {
t.Errorf("Reverse:\n Except => %s\n Got =>%s\n", "gfedcba", Reverse("abcdefg"))
}
if Reverse("上善若水厚德载物") != "物载德厚水若善上" {
t.Errorf("Reverse:\n Except => %s\n Got =>%s\n", "物载德厚水若善上", Reverse("上善若水厚德载物"))
}
} | explode_data.jsonl/68416 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 189
} | [
2830,
3393,
45695,
1155,
353,
8840,
836,
8,
341,
743,
24277,
445,
41202,
70,
899,
961,
330,
45124,
291,
93829,
1,
341,
197,
3244,
13080,
445,
45695,
7190,
77,
37167,
589,
1018,
82,
1699,
24528,
589,
4,
82,
1699,
497,
330,
45124,
291... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAutomationConfig_CustomMongodConfig(t *testing.T) {
mdb := newTestReplicaSet()
mongodConfig := objx.New(map[string]interface{}{})
mongodConfig.Set("net.port", 1000)
mongodConfig.Set("storage.other", "value")
mongodConfig.Set("arbitrary.config.path", "value")
mdb.Spec.AdditionalMongodConfig.Object = mong... | explode_data.jsonl/80681 | {
"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,
98856,
2648,
57402,
44,
644,
347,
2648,
1155,
353,
8840,
836,
8,
341,
2109,
1999,
1669,
501,
2271,
18327,
15317,
1649,
2822,
2109,
644,
347,
2648,
1669,
2839,
87,
7121,
9147,
14032,
31344,
6257,
37790,
2109,
644,
347,
2648,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestCheckIsValidUtf8(t *testing.T) {
to, path := createCheckerTestObjects(t)
defer func() {
to.stor.close(t)
err := common.CleanTemporaryDirs(path)
assert.NoError(t, err, "failed to clean test data dirs")
}()
err := to.tc.isValidUtf8("just a normal string")
assert.NoError(t, err)
err = to.tc.isVali... | explode_data.jsonl/63077 | {
"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,
3973,
55470,
38980,
23,
1155,
353,
8840,
836,
8,
341,
31709,
11,
1815,
1669,
1855,
35188,
2271,
11543,
1155,
692,
16867,
2915,
368,
341,
197,
31709,
1236,
269,
4653,
1155,
692,
197,
9859,
1669,
4185,
727,
2675,
59362,
97384,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestWordSplit(t *testing.T) {
for _, tc := range wordSplitTests {
roles := fuzzy.RuneRoles([]byte(tc.input), nil)
var got []string
consumer := func(i, j int) {
got = append(got, tc.input[i:j])
}
fuzzy.Words(roles, consumer)
if eq := diffStringLists(tc.want, got); !eq {
t.Errorf("input %v: (wan... | explode_data.jsonl/58125 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 164
} | [
2830,
3393,
10879,
20193,
1155,
353,
8840,
836,
8,
341,
2023,
8358,
17130,
1669,
2088,
3409,
20193,
18200,
341,
197,
197,
14643,
1669,
52733,
2013,
2886,
25116,
10556,
3782,
44415,
10046,
701,
2092,
692,
197,
2405,
2684,
3056,
917,
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 TestSpecC5(t *testing.T) {
var f, g *[]string
var x *bool
init := func(c *Cmd) {
f = c.StringsArg("SRC", nil, "")
g = c.StringsArg("DST", nil, "")
x = c.BoolOpt("x", false, "")
}
spec := "(SRC... -x DST) | (SRC... DST)"
okCmd(t, spec, init, []string{"A", "B"})
require.Equal(t, []string{"A"}, *f)
req... | explode_data.jsonl/23935 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 329
} | [
2830,
3393,
8327,
34,
20,
1155,
353,
8840,
836,
8,
341,
2405,
282,
11,
342,
353,
1294,
917,
198,
2405,
856,
353,
2641,
198,
28248,
1669,
2915,
1337,
353,
15613,
8,
341,
197,
1166,
284,
272,
89154,
2735,
445,
56017,
497,
2092,
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 TestConditionalFormatError(t *testing.T) {
f := NewFile()
sheet1 := f.GetSheetName(1)
fillCells(f, sheet1, 10, 15)
// Set conditional format with illegal JSON string should return error
_, err := f.NewConditionalStyle("")
if !assert.EqualError(t, err, "unexpected end of JSON input") {
t.FailNow()
}
} | explode_data.jsonl/36989 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 113
} | [
2830,
3393,
79233,
4061,
1454,
1155,
353,
8840,
836,
8,
341,
1166,
1669,
1532,
1703,
741,
1903,
3674,
16,
1669,
282,
2234,
10541,
675,
7,
16,
692,
65848,
20857,
955,
11,
10834,
16,
11,
220,
16,
15,
11,
220,
16,
20,
692,
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... | 2 |
func TestParseAndLoad(t *testing.T) {
actual, err := loadYAML(sampleYAML)
if !assert.NoError(t, err) {
return
}
assert.Equal(t, serviceSort(sampleConfig.Services), serviceSort(actual.Services))
assert.Equal(t, sampleConfig.Networks, actual.Networks)
assert.Equal(t, sampleConfig.Volumes, actual.Volumes)
} | explode_data.jsonl/16379 | {
"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,
14463,
3036,
5879,
1155,
353,
8840,
836,
8,
341,
88814,
11,
1848,
1669,
2795,
56,
31102,
32968,
56,
31102,
340,
743,
753,
2207,
35699,
1155,
11,
1848,
8,
341,
197,
853,
198,
197,
532,
6948,
12808,
1155,
11,
2473,
10231,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestResolveIdentifyImplicitTeamWithSocial(t *testing.T) {
tt := newTeamTester(t)
defer tt.cleanup()
tt.addUser("abc")
g := tt.users[0].tc.G
tt.addUser("wong")
wong := tt.users[1]
wong.proveRooter()
getTeamName := func(teamID keybase1.TeamID) keybase1.TeamName {
team, err := teams.Load(context.Backgrou... | explode_data.jsonl/42659 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 712
} | [
2830,
3393,
56808,
28301,
1437,
59558,
14597,
2354,
26317,
1155,
353,
8840,
836,
8,
341,
3244,
83,
1669,
501,
14597,
58699,
1155,
340,
16867,
17853,
87689,
2822,
3244,
83,
1364,
1474,
445,
13683,
1138,
3174,
1669,
17853,
20653,
58,
15,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestSharedCertificateExists(t *testing.T) {
caCert, caKey := certstestutil.CreateCACert(t)
_, key, _ := certstestutil.CreateTestCert(t, caCert, caKey, certutil.AltNames{})
publicKey := &key.PublicKey
var tests = []struct {
name string
files certstestutil.PKIFiles
expectedError bool
}{
... | explode_data.jsonl/60266 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1537
} | [
2830,
3393,
16997,
33202,
15575,
1155,
353,
8840,
836,
8,
341,
197,
924,
36934,
11,
2162,
1592,
1669,
2777,
267,
477,
1314,
7251,
92832,
529,
1155,
340,
197,
6878,
1376,
11,
716,
1669,
2777,
267,
477,
1314,
7251,
2271,
36934,
1155,
11... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 6 |
func TestBatchProcessorSpansDelivered(t *testing.T) {
sink := new(consumertest.TracesSink)
cfg := createDefaultConfig().(*Config)
cfg.SendBatchSize = 128
creationSet := componenttest.NewNopProcessorCreateSettings()
batcher, err := newBatchTracesProcessor(creationSet, sink, cfg, configtelemetry.LevelDetailed)
requ... | explode_data.jsonl/25020 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 598
} | [
2830,
3393,
21074,
22946,
6406,
596,
16532,
43056,
1155,
353,
8840,
836,
8,
341,
1903,
766,
1669,
501,
17868,
1242,
83386,
8240,
2434,
45094,
340,
50286,
1669,
1855,
3675,
2648,
1005,
4071,
2648,
340,
50286,
20176,
21074,
1695,
284,
220,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 5 |
func TestVersion2(t *testing.T) {
assert.NoError(t, PrepareEngine())
err := testEngine.DropTables(new(VersionS))
assert.NoError(t, err)
err = testEngine.CreateTables(new(VersionS))
assert.NoError(t, err)
var vers = []VersionS{
{Name: "sfsfdsfds"},
{Name: "xxxxx"},
}
_, err = testEngine.Insert(vers)
asse... | explode_data.jsonl/19221 | {
"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,
5637,
17,
1155,
353,
8840,
836,
8,
341,
6948,
35699,
1155,
11,
31166,
4571,
12367,
9859,
1669,
1273,
4571,
21688,
21670,
1755,
7,
5637,
50,
1171,
6948,
35699,
1155,
11,
1848,
692,
9859,
284,
1273,
4571,
7251,
21670,
1755,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestValidateErrorPageRedirectFails(t *testing.T) {
tests := []v1.ErrorPageRedirect{
{
ActionRedirect: v1.ActionRedirect{
URL: "",
Code: 301,
},
},
{
ActionRedirect: v1.ActionRedirect{
URL: `"http://nginx.com"`,
Code: 301,
},
},
{
ActionRedirect: v1.ActionRedirect{
UR... | explode_data.jsonl/65920 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 382
} | [
2830,
3393,
17926,
1454,
2665,
17725,
37,
6209,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
85,
16,
6141,
2665,
17725,
515,
197,
197,
515,
298,
67607,
17725,
25,
348,
16,
11360,
17725,
515,
571,
79055,
25,
220,
8324,
571,
90774,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestDaoRelation(t *testing.T) {
var (
c = context.TODO()
oid = int64(0)
tid = int64(0)
tp = int32(0)
state = int32(0)
)
convey.Convey("Relation", t, func(ctx convey.C) {
res, err := d.Relation(c, oid, tid, tp, state)
ctx.Convey("Then err should be nil.res should not be nil.", func(ctx c... | explode_data.jsonl/46398 | {
"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,
12197,
33790,
1155,
353,
8840,
836,
8,
341,
2405,
2399,
197,
1444,
257,
284,
2266,
90988,
741,
197,
197,
588,
256,
284,
526,
21,
19,
7,
15,
340,
197,
3244,
307,
256,
284,
526,
21,
19,
7,
15,
340,
197,
73423,
262,
284... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestInputService7ProtocolTestBase64EncodedBlobsCase1(t *testing.T) {
svc := NewInputService7ProtocolTest(nil)
svc.Endpoint = "https://test"
input := &InputService7TestShapeInputShape{
BlobArg: []byte("foo"),
}
req, _ := svc.InputService7TestCaseOperation1Request(input)
r := req.HTTPRequest
// build requ... | explode_data.jsonl/53207 | {
"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,
2505,
1860,
22,
20689,
2271,
3978,
21,
19,
46795,
33,
68164,
4207,
16,
1155,
353,
8840,
836,
8,
341,
1903,
7362,
1669,
1532,
2505,
1860,
22,
20689,
2271,
27907,
340,
1903,
7362,
90409,
284,
330,
2428,
1110,
1944,
1837,
224... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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_IngressConfiguration(t *testing.T) {
labels := map[string]string{
"foo": "bar",
}
now := testutil.Time()
ingress := testutil.CreateIngress("ingress")
ingress.CreationTimestamp = metav1.Time{Time: now}
ingress.Labels = labels
ingressNoBackend := testutil.CreateIngress("ingress")
ingressNoBackend.C... | explode_data.jsonl/26416 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 685
} | [
2830,
3393,
25972,
2483,
7688,
1155,
353,
8840,
836,
8,
341,
95143,
1669,
2415,
14032,
30953,
515,
197,
197,
1,
7975,
788,
330,
2257,
756,
197,
630,
80922,
1669,
1273,
1314,
16299,
2822,
197,
287,
673,
1669,
1273,
1314,
7251,
641,
248... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestApixu_ForecastWithQueryError(t *testing.T) {
a := &apixu{
config: Config{},
}
res, err := a.Forecast(strings.Repeat("q", maxQueryLength+1), 1, nil)
assert.Nil(t, res)
assert.Error(t, err)
} | explode_data.jsonl/14942 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 89
} | [
2830,
3393,
10611,
941,
84,
1400,
460,
3829,
2354,
2859,
1454,
1155,
353,
8840,
836,
8,
341,
11323,
1669,
609,
391,
941,
84,
515,
197,
25873,
25,
5532,
38837,
197,
630,
10202,
11,
1848,
1669,
264,
10527,
3829,
51442,
2817,
10979,
445,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestMakeExtendedHostExpirationFailsBeyondOneWeek(t *testing.T) {
assert := assert.New(t)
h := host.Host{
CreationTime: time.Now(),
ExpirationTime: time.Now().Add(12 * time.Hour),
}
expTime, err := MakeExtendedSpawnHostExpiration(&h, 24*14*time.Hour)
assert.Zero(expTime)
assert.Error(err, expTime.Form... | explode_data.jsonl/8683 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 129
} | [
2830,
3393,
8078,
53190,
9296,
66301,
37,
6209,
55341,
3966,
17053,
1155,
353,
8840,
836,
8,
341,
6948,
1669,
2060,
7121,
1155,
692,
9598,
1669,
3468,
29840,
515,
197,
6258,
26453,
1462,
25,
256,
882,
13244,
3148,
197,
197,
66301,
1462,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestUnknownEvent(t *testing.T) {
e, err := unmarshal([]string{})
if err != nil {
t.Errorf("Unexpected failure while unmarshaling valid EventsResponse")
}
if e.Type != eventUnknown {
t.Errorf("Parsed event type is supposed to be unknown")
}
} | explode_data.jsonl/78029 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 89
} | [
2830,
3393,
13790,
1556,
1155,
353,
8840,
836,
8,
341,
7727,
11,
1848,
1669,
650,
27121,
10556,
917,
37790,
743,
1848,
961,
2092,
341,
197,
3244,
13080,
445,
29430,
7901,
1393,
650,
36239,
6132,
2697,
17627,
2582,
1138,
197,
630,
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
] | 3 |
func TestValidateDNSSearch(t *testing.T) {
valid := []string{
`.`,
`a`,
`a.`,
`1.foo`,
`17.foo`,
`foo.bar`,
`foo.bar.baz`,
`foo.bar.`,
`foo.bar.baz`,
`foo1.bar2`,
`foo1.bar2.baz`,
`1foo.2bar.`,
`1foo.2bar.baz`,
`foo-1.bar-2`,
`foo-1.bar-2.baz`,
`foo-1.bar-2.`,
`foo-1.bar-2.baz`,
`1-... | explode_data.jsonl/26382 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 653
} | [
2830,
3393,
17926,
31264,
1220,
2902,
1155,
353,
8840,
836,
8,
341,
56322,
1669,
3056,
917,
515,
197,
197,
28587,
12892,
197,
197,
63,
64,
12892,
197,
197,
63,
64,
80007,
197,
197,
63,
16,
58432,
12892,
197,
197,
63,
16,
22,
58432,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestAgent_RegisterService_ConnectNative(t *testing.T) {
t.Parallel()
assert := assert.New(t)
a := NewTestAgent(t.Name(), "")
defer a.Shutdown()
// Register a proxy. Note that the destination doesn't exist here on
// this agent or in the catalog at all. This is intended and part
// of the design.
args := ... | explode_data.jsonl/33633 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 304
} | [
2830,
3393,
16810,
73124,
1860,
15100,
2321,
20800,
1155,
353,
8840,
836,
8,
341,
3244,
41288,
7957,
2822,
6948,
1669,
2060,
7121,
1155,
340,
11323,
1669,
1532,
2271,
16810,
1155,
2967,
1507,
14676,
16867,
264,
10849,
18452,
2822,
197,
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... | 1 |
func TestLinkSecret(t *testing.T) {
tests := []struct {
name string
namespace string
secretName string
componentName string
applicationName string
wantErr bool
}{
{
name: "Case: Unable to locate DeploymentConfig",
namespace: "foo",
secretName: ... | explode_data.jsonl/65158 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 983
} | [
2830,
3393,
3939,
19773,
1155,
353,
8840,
836,
8,
341,
78216,
1669,
3056,
1235,
341,
197,
11609,
310,
914,
198,
197,
56623,
981,
914,
198,
197,
197,
20474,
675,
414,
914,
198,
197,
52228,
675,
256,
914,
198,
197,
197,
5132,
675,
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... | 2 |
func TestPID(t *testing.T) {
if testing.Short() {
t.Skip()
}
fctesting.RequiresRoot(t)
m := &Machine{}
if _, err := m.PID(); err == nil {
t.Errorf("expected an error, but received none")
}
var nCpus int64 = 2
cpuTemplate := models.CPUTemplate(models.CPUTemplateT2)
var memSz int64 = 256
socketPath := fil... | explode_data.jsonl/70443 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 807
} | [
2830,
3393,
33751,
1155,
353,
8840,
836,
8,
341,
743,
7497,
55958,
368,
341,
197,
3244,
57776,
741,
197,
532,
1166,
302,
59855,
85012,
8439,
1155,
692,
2109,
1669,
609,
21605,
16094,
743,
8358,
1848,
1669,
296,
1069,
915,
2129,
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... | 9 |
func TestControllerDeleteNodeForMachine(t *testing.T) {
machineUID := types.UID("test-1")
tests := []struct {
name string
machine *clusterv1alpha1.Machine
nodes []runtime.Object
err error
shouldDeleteNode string
}{
{
name: "delete node by nodeRef",
mach... | explode_data.jsonl/59422 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1869
} | [
2830,
3393,
2051,
6435,
1955,
2461,
21605,
1155,
353,
8840,
836,
8,
341,
2109,
3814,
6463,
1669,
4494,
5255,
915,
445,
1944,
12,
16,
5130,
78216,
1669,
3056,
1235,
341,
197,
11609,
1797,
914,
198,
197,
2109,
3814,
688,
353,
564,
590,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestFilterByReplicationLagThreeTabletMin(t *testing.T) {
// Use at least 3 tablets if possible
testSetMinNumTablets(3)
// lags of (1s, 1s, 10m, 11m) - returns at least32 items where the slightly delayed ones that are returned are the 10m and 11m ones.
ts1 := &TabletStats{
Tablet: topo.NewTablet(1, "cell", "... | explode_data.jsonl/262 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 938
} | [
2830,
3393,
5632,
1359,
18327,
1693,
43,
351,
19641,
2556,
83,
6217,
1155,
353,
8840,
836,
8,
341,
197,
322,
5443,
518,
3245,
220,
18,
28579,
421,
3204,
198,
18185,
1649,
6217,
4651,
2556,
2576,
7,
18,
340,
197,
322,
326,
2032,
315,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPingReconnect(t *testing.T) {
RECONNECTS := 4
s1 := RunServerOnPort(1222)
defer s1.Shutdown()
opts := nats.DefaultOptions
opts.Servers = testServers
opts.NoRandomize = true
opts.ReconnectWait = 200 * time.Millisecond
opts.PingInterval = 50 * time.Millisecond
opts.MaxPingsOut = -1
var wg sync.WaitGr... | explode_data.jsonl/1558 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 487
} | [
2830,
3393,
69883,
693,
6459,
1155,
353,
8840,
836,
8,
341,
34269,
39521,
50,
1669,
220,
19,
198,
1903,
16,
1669,
6452,
5475,
1925,
7084,
7,
16,
17,
17,
17,
340,
16867,
274,
16,
10849,
18452,
2822,
64734,
1669,
308,
1862,
13275,
379... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestActionsGobable(t *testing.T) {
for i, a := range actions {
a1 := exampleStruct{Action: a}
a2 := exampleStruct{}
t.Run(fmt.Sprintf("%d: %s", i, a), func(t *testing.T) {
shtest.EnsureGobable(t, &a1, &a2)
})
}
} | explode_data.jsonl/13240 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 112
} | [
2830,
3393,
12948,
38,
674,
480,
1155,
353,
8840,
836,
8,
341,
2023,
600,
11,
264,
1669,
2088,
6168,
341,
197,
11323,
16,
1669,
3110,
9422,
90,
2512,
25,
264,
532,
197,
11323,
17,
1669,
3110,
9422,
16094,
197,
3244,
16708,
28197,
17... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestJensenShannon(t *testing.T) {
for i, test := range []struct {
p []float64
q []float64
}{
{
p: []float64{0.5, 0.1, 0.3, 0.1},
q: []float64{0.1, 0.4, 0.25, 0.25},
},
{
p: []float64{0.4, 0.6, 0.0},
q: []float64{0.2, 0.2, 0.6},
},
{
p: []float64{0.1, 0.1, 0.0, 0.8},
q: []float64{0... | explode_data.jsonl/1768 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 614
} | [
2830,
3393,
41,
34017,
2016,
17436,
1155,
353,
8840,
836,
8,
341,
2023,
600,
11,
1273,
1669,
2088,
3056,
1235,
341,
197,
3223,
3056,
3649,
21,
19,
198,
197,
18534,
3056,
3649,
21,
19,
198,
197,
59403,
197,
197,
515,
298,
3223,
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 TestUpdateUserActive(t *testing.T) {
t.Run("basic tests", func(t *testing.T) {
th := Setup().InitBasic().InitSystemAdmin()
defer th.TearDown()
Client := th.Client
SystemAdminClient := th.SystemAdminClient
user := th.BasicUser
EnableUserDeactivation := th.App.Config().TeamSettings.EnableUserDeactivat... | explode_data.jsonl/21534 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1444
} | [
2830,
3393,
4289,
1474,
5728,
1155,
353,
8840,
836,
8,
341,
3244,
16708,
445,
22342,
7032,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
70479,
1669,
18626,
1005,
3803,
15944,
1005,
3803,
2320,
7210,
741,
197,
16867,
270,
836,
682,
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 TestAccounts_SetBalance(t *testing.T) {
mutableTree, _ := tree.NewMutableTree(0, db.NewMemDB(), 1024)
b := bus.NewBus()
b.SetChecker(checker.NewChecker(b))
accounts, err := NewAccounts(b, mutableTree)
if err != nil {
t.Fatal(err)
}
accounts.SetBalance([20]byte{4}, 0, big.NewInt(1000))
account := accounts... | explode_data.jsonl/23596 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 204
} | [
2830,
3393,
41369,
14812,
21190,
1155,
353,
8840,
836,
8,
341,
2109,
5922,
6533,
11,
716,
1669,
4916,
7121,
11217,
6533,
7,
15,
11,
2927,
7121,
18816,
3506,
1507,
220,
16,
15,
17,
19,
340,
2233,
1669,
5828,
7121,
15073,
741,
2233,
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... | 4 |
func TestBlockRetrieverHandlesSeekByIndexEntryErrors(t *testing.T) {
ctrl := gomock.NewController(t)
defer ctrl.Finish()
mockSeeker := NewMockConcurrentDataFileSetSeeker(ctrl)
mockSeeker.EXPECT().SeekIndexEntry(gomock.Any(), gomock.Any()).Return(IndexEntry{}, nil)
mockSeeker.EXPECT().SeekByIndexEntry(gomock.Any()... | explode_data.jsonl/3997 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 163
} | [
2830,
3393,
4713,
12020,
461,
2054,
65928,
39350,
1359,
1552,
5874,
13877,
1155,
353,
8840,
836,
8,
341,
84381,
1669,
342,
316,
1176,
7121,
2051,
1155,
340,
16867,
23743,
991,
18176,
2822,
77333,
39350,
261,
1669,
1532,
11571,
1109,
3231,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestJobsController_Create_ValidationFailure(t *testing.T) {
var (
contractAddress = cltest.NewEIP55Address()
)
var tt = []struct {
name string
pid models.PeerID
kb models.Sha256Hash
taExists bool
expectedErr error
}{
{
name: "invalid keybundle",
pid: ... | explode_data.jsonl/1621 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 807
} | [
2830,
3393,
40667,
2051,
34325,
62,
13799,
17507,
1155,
353,
8840,
836,
8,
341,
2405,
2399,
197,
197,
20257,
4286,
284,
1185,
1944,
7121,
36,
3298,
20,
20,
4286,
741,
197,
692,
2405,
17853,
284,
3056,
1235,
341,
197,
11609,
286,
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... | 2 |
func Test_writeIndention_should_grow_buffer(t *testing.T) {
should := require.New(t)
stream := NewStream(Config{IndentionStep: 2}.Froze(), nil, 1)
stream.WriteVal([]int{1, 2, 3})
should.Equal("[\n 1,\n 2,\n 3\n]", string(stream.Buffer()))
} | explode_data.jsonl/27138 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 104
} | [
2830,
3393,
9165,
1425,
2939,
43378,
1889,
651,
7776,
1155,
353,
8840,
836,
8,
341,
197,
5445,
1669,
1373,
7121,
1155,
340,
44440,
1669,
1532,
3027,
33687,
90,
1425,
2939,
8304,
25,
220,
17,
7810,
37,
299,
2986,
1507,
2092,
11,
220,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func TestManagementConfigurationByName(t *testing.T) {
conf, cleanupConfig := testutil.InitConfig(t)
defer cleanupConfig(t)
mgmtCfg, err := conf.GetManagementConfiguration(config.AirshipDefaultContext)
require.NoError(t, err)
assert.Equal(t, conf.ManagementConfiguration[config.AirshipDefaultContext], mgmtCfg)
} | explode_data.jsonl/57913 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 99
} | [
2830,
3393,
22237,
7688,
16898,
1155,
353,
8840,
836,
8,
341,
67850,
11,
21290,
2648,
1669,
1273,
1314,
26849,
2648,
1155,
340,
16867,
21290,
2648,
1155,
692,
2109,
46063,
42467,
11,
1848,
1669,
2335,
2234,
22237,
7688,
8754,
875,
404,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestHealthCheckMultipleStarts(t *testing.T) {
config := Config{
TCPAddr: confignet.TCPAddr{
Endpoint: testutil.GetAvailableLocalAddress(t),
},
CheckCollectorPipeline: defaultCheckCollectorPipelineSettings(),
Path: "/",
}
hcExt := newServer(config, zap.NewNop())
require.NotNil(t, h... | explode_data.jsonl/11622 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 227
} | [
2830,
3393,
14542,
3973,
32089,
3479,
82,
1155,
353,
8840,
836,
8,
341,
25873,
1669,
5532,
515,
197,
10261,
7123,
13986,
25,
2335,
84858,
836,
7123,
13986,
515,
298,
197,
27380,
25,
1273,
1314,
2234,
16485,
7319,
4286,
1155,
1326,
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 TestSample1(t *testing.T) {
n, m, k := 4, 4, 9
plants := [][]int{
{1, 4},
{2, 1},
{2, 2},
{2, 3},
{3, 1},
{3, 3},
{4, 1},
{4, 2},
{4, 3},
}
expect := 20
runSample(t, n, m, k, plants, expect)
} | explode_data.jsonl/62854 | {
"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,
17571,
16,
1155,
353,
8840,
836,
8,
341,
9038,
11,
296,
11,
595,
1669,
220,
19,
11,
220,
19,
11,
220,
24,
198,
197,
63705,
1669,
52931,
396,
515,
197,
197,
90,
16,
11,
220,
19,
1583,
197,
197,
90,
17,
11,
220,
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 TestStartWithProxy(t *testing.T) {
originalValues := config.Datadog.GetStringSlice(statsDMetricBlocklistKey)
defer config.Datadog.Set(statsDMetricBlocklistKey, originalValues)
config.Datadog.Set(statsDMetricBlocklistKey, []string{})
os.Setenv(proxyEnabledEnvVar, "true")
defer os.Unsetenv(proxyEnabledEnvVar)
... | explode_data.jsonl/50623 | {
"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,
3479,
2354,
16219,
1155,
353,
8840,
836,
8,
341,
197,
9889,
6227,
1669,
2193,
909,
266,
329,
538,
21166,
33236,
50714,
8395,
16340,
4713,
1607,
1592,
340,
16867,
2193,
909,
266,
329,
538,
4202,
50714,
8395,
16340,
4713,
1607... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestModel_NewBank(t *testing.T) {
code := "001"
name := "Banco do Brasil"
bank, err := model.NewBank(code, name)
require.Nil(t, err)
require.NotEmpty(t, uuid.FromStringOrNil(bank.ID))
require.Equal(t, bank.Code, code)
require.Equal(t, bank.Name, name)
_, err = model.NewBank("", "")
require.NotNil(t, e... | explode_data.jsonl/12056 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 138
} | [
2830,
3393,
1712,
39582,
25828,
1155,
353,
8840,
836,
8,
1476,
43343,
1669,
330,
15,
15,
16,
698,
11609,
1669,
330,
33,
18557,
653,
41925,
1837,
2233,
1180,
11,
1848,
1669,
1614,
7121,
25828,
15842,
11,
829,
692,
17957,
59678,
1155,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 1 |
func Test_serializeApplyStatus(t *testing.T) {
const (
expReg = `^{"kind":"Order","apiVersion":"acme.cert-manager.io/v1","metadata":{"name":"foo","namespace":"bar","creationTimestamp":null},"spec":{"request":null,"issuerRef":{"name":""}},"status":{.*}$`
expEmpty = `{"kind":"Order","apiVersion":"acme.cert-manager... | explode_data.jsonl/3957 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 621
} | [
2830,
3393,
88686,
28497,
2522,
1155,
353,
8840,
836,
8,
341,
4777,
2399,
197,
48558,
3477,
256,
284,
1565,
61,
4913,
15314,
3252,
4431,
2198,
2068,
5637,
3252,
580,
2660,
67016,
44896,
4245,
5457,
16,
2198,
17637,
22317,
606,
3252,
797... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestJsonLargeInteger(t *testing.T) {
testOnce.Do(testInitAll)
for _, i := range []uint8{'L', 'A', 0} {
for _, j := range []interface{}{
int64(1 << 60),
-int64(1 << 60),
0,
1 << 20,
-(1 << 20),
uint64(1 << 60),
uint(0),
uint(1 << 20),
} {
doTestJsonLargeInteger(t, j, i)
}
}
} | explode_data.jsonl/21004 | {
"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,
5014,
34253,
3486,
1155,
353,
8840,
836,
8,
341,
18185,
12522,
33596,
8623,
3803,
2403,
340,
2023,
8358,
600,
1669,
2088,
3056,
2496,
23,
13608,
43,
516,
364,
32,
516,
220,
15,
92,
341,
197,
2023,
8358,
502,
1669,
2088,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestMultipleInstances(t *testing.T) {
cache, cleanup := withCache(t)
defer cleanup()
checksum := createTestContract(t, cache)
// instance1 controlled by fred
gasMeter1 := NewMockGasMeter(TESTING_GAS_LIMIT)
igasMeter1 := GasMeter(gasMeter1)
store1 := NewLookup(gasMeter1)
api := NewMockAPI()
querier := Def... | explode_data.jsonl/62561 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 876
} | [
2830,
3393,
32089,
42725,
1155,
353,
8840,
836,
8,
341,
52680,
11,
21290,
1669,
448,
8233,
1155,
340,
16867,
21290,
741,
25157,
1242,
1669,
1855,
2271,
14067,
1155,
11,
6500,
692,
197,
322,
2867,
16,
14071,
553,
97126,
198,
3174,
300,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestProvider_Stop(t *testing.T) {
bgCtx := context.Background()
payChAddr := address.TestAddress
client, expectedCIDs, _, _, retrievalPeer, provider := requireSetupTestClientAndProvider(bgCtx, t, payChAddr)
require.NoError(t, provider.Stop())
_, err := client.Query(bgCtx, retrievalPeer, expectedCIDs[0], retri... | explode_data.jsonl/22500 | {
"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,
5179,
80308,
1155,
353,
8840,
836,
8,
341,
76131,
23684,
1669,
2266,
19047,
741,
3223,
352,
1143,
13986,
1669,
2621,
8787,
4286,
198,
25291,
11,
3601,
34,
30466,
11,
8358,
8358,
56370,
30888,
11,
9109,
1669,
1373,
21821,
227... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestNewInvalid(t *testing.T) {
testCases := []struct {
Err *fielderrors.ValidationError
Details *api.StatusDetails
}{
{
fielderrors.NewFieldDuplicate("field[0].name", "bar"),
&api.StatusDetails{
Kind: "kind",
ID: "name",
Causes: []api.StatusCause{{
Type: api.CauseTypeFieldValu... | explode_data.jsonl/8866 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 843
} | [
2830,
3393,
3564,
7928,
1155,
353,
8840,
836,
8,
341,
18185,
37302,
1669,
3056,
1235,
341,
197,
197,
7747,
257,
353,
2566,
7650,
82714,
198,
197,
197,
7799,
353,
2068,
10538,
7799,
198,
197,
59403,
197,
197,
515,
298,
39250,
7650,
712... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestReconcileProvisioner_reconcileSfClusterCrd(t *testing.T) {
g := gomega.NewGomegaWithT(t)
ctrl := gomock.NewController(t)
defer ctrl.Finish()
// Setup the Manager and Controller. Wrap the Controller Reconcile function so it writes each request to a
// channel when it is finished.
mgr, err := manager.New... | explode_data.jsonl/58272 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1025
} | [
2830,
3393,
693,
40446,
457,
1336,
13013,
261,
1288,
40446,
457,
50,
69,
28678,
34,
6498,
1155,
353,
8840,
836,
8,
341,
3174,
1669,
342,
32696,
7121,
38,
32696,
2354,
51,
1155,
340,
84381,
1669,
342,
316,
1176,
7121,
2051,
1155,
340,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | 2 |
func TestSubCertProvinceNotProhibited(t *testing.T) {
inputPath := "../testlint/testCerts/subCertProvinceNotProhibited.pem"
expected := Pass
out := Lints["e_sub_cert_province_must_appear"].Execute(ReadCertificate(inputPath))
if out.Status != expected {
t.Errorf("%s: expected %s, got %s", inputPath, expected, out.... | explode_data.jsonl/72391 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 122
} | [
2830,
3393,
3136,
36934,
51074,
2623,
1336,
92517,
1155,
353,
8840,
836,
8,
341,
22427,
1820,
1669,
7005,
1944,
14957,
12697,
34,
15546,
37885,
36934,
51074,
2623,
1336,
92517,
49373,
698,
42400,
1669,
9970,
198,
13967,
1669,
444,
21042,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestRepository_Save(t *testing.T) {
asst := assert.New(t)
err := testRepo.Save(testSMTPURL, testToAddrs, testCCAddrs, testSubject, testContent, testConfig, testMessage)
asst.Nil(err, common.CombineMessageWithError("test Save() failed", err))
} | explode_data.jsonl/47437 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 89
} | [
2830,
3393,
4624,
78746,
1155,
353,
8840,
836,
8,
341,
60451,
267,
1669,
2060,
7121,
1155,
692,
9859,
1669,
1273,
25243,
13599,
8623,
58198,
3144,
11,
1273,
52113,
5428,
11,
1273,
3706,
2212,
5428,
11,
1273,
13019,
11,
1273,
2762,
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 TestScanImage(t *testing.T) {
log.InitLogger(false, false)
testcases := map[string]struct {
imageName string
fileName string
option deckodertypes.DockerOption
wantErr error
expected []*types.Assessment
}{
"Dockerfile.base": {
// TODO : too large to use github / fileName: "base.tar",
//... | explode_data.jsonl/3365 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 1052
} | [
2830,
3393,
26570,
1906,
1155,
353,
8840,
836,
8,
341,
6725,
26849,
7395,
3576,
11,
895,
340,
18185,
23910,
1669,
2415,
14032,
60,
1235,
341,
197,
31426,
675,
914,
198,
197,
17661,
675,
220,
914,
198,
197,
80845,
262,
9530,
347,
529,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestJWKsCache_Cleanup(t *testing.T) {
t.Run("should cleanup expired cached keys", func(t *testing.T) {
// GIVEN
logger, hook := logrustest.NewNullLogger()
jwksFetch := NewJWKsFetch()
jwksCache := NewJWKsCache(jwksFetch, cachePeriod)
// WHEN
jwksCache.cache["123"] = jwkCacheEntry{
expireAt: time.No... | explode_data.jsonl/29082 | {
"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,
41,
68316,
82,
8233,
920,
60639,
1155,
353,
8840,
836,
8,
341,
3244,
16708,
445,
5445,
21290,
26391,
20579,
6894,
497,
2915,
1155,
353,
8840,
836,
8,
341,
197,
197,
322,
89836,
198,
197,
17060,
11,
9704,
1669,
1487,
35788,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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 TestPhysicalProps(t *testing.T) {
defer leaktest.AfterTest(t)()
runDataDrivenTest(
t, "testdata/physprops/",
memo.ExprFmtHideMiscProps|
memo.ExprFmtHideConstraints|
memo.ExprFmtHideFuncDeps|
memo.ExprFmtHideRuleProps|
memo.ExprFmtHideStats|
memo.ExprFmtHideCost|
memo.ExprFmtHideQualificatio... | explode_data.jsonl/55159 | {
"file_path": "/home/dung/Study/Code/Cross_test_gen/training_dataset/dedup_data/clean_data_go/data/explode_data.jsonl",
"token_count": 177
} | [
2830,
3393,
39253,
5992,
1155,
353,
8840,
836,
8,
341,
16867,
23352,
1944,
36892,
2271,
1155,
8,
741,
56742,
1043,
98484,
2271,
1006,
197,
3244,
11,
330,
92425,
14,
41205,
4761,
35075,
197,
2109,
6726,
93267,
93322,
21692,
50979,
5992,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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.