Skip to content

Commit 79cf113

Browse files
authored
Merge pull request #62 from layer5io/kumarabd/bug/smi-port-2
changed timeout and parameter values
2 parents efdd47d + 8b4d755 commit 79cf113

File tree

4 files changed

+54
-36
lines changed

4 files changed

+54
-36
lines changed

smi-conformance/conformance/conformance.pb.go

+41-31
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

smi-conformance/conformance/conformance.proto

+3-1
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,12 @@ message Detail {
1616
string assertions = 3;
1717
string result = 4;
1818
string reason = 5;
19+
string capability = 6;
20+
string status = 7;
1921
}
2022

2123
message Response {
22-
string capability = 1;
24+
string passpercent = 1;
2325
string casespassed = 2;
2426
repeated Detail details = 3;
2527
}

smi-conformance/grpc/handlers.go

+8-1
Original file line numberDiff line numberDiff line change
@@ -60,18 +60,25 @@ func (s *Service) RunTest(ctx context.Context, req *conformance.Request) (*confo
6060
Smispec: res.Name,
6161
Time: res.Time,
6262
Assertions: strconv.Itoa(res.Assertions),
63+
Capability: "Full",
64+
Status: "Passing",
6365
}
6466
if len(res.Failure.Text) > 2 {
6567
d.Reason = res.Failure.Text
6668
d.Result = res.Failure.Message
69+
d.Status = "Failing"
70+
d.Capability = "None"
6771
failures += 1
72+
if (res.Assertions - failures) > (res.Assertions / 2) {
73+
d.Capability = "Half"
74+
}
6875
}
6976
details = append(details, d)
7077
}
7178

7279
return &conformance.Response{
7380
Casespassed: strconv.Itoa(totalcases - failures),
74-
Capability: strconv.Itoa(((totalcases - failures) / totalcases) * 100),
81+
Passpercent: strconv.Itoa(((totalcases - failures) / totalcases) * 100),
7582
Details: details,
7683
}, nil
7784
}

smi-conformance/test-gen/test_gen.go

+2-3
Original file line numberDiff line numberDiff line change
@@ -50,16 +50,15 @@ func RunTest(meshConfig ServiceMesh, annotations, labels map[string]string) Resu
5050
// Run only traffic-split
5151
// testToRun := "traffic-split"
5252

53-
startKIND := false
5453
options := harness.TestSuite{}
5554

5655
args := []string{"./test-yamls/"}
5756

5857
options.TestDirs = args
59-
options.Timeout = 300
58+
options.Timeout = 120
6059
options.Parallel = 1
6160
options.TestDirs = manifestDirs
62-
options.StartKIND = startKIND
61+
options.StartKIND = false
6362
options.SkipDelete = false
6463

6564
if options.KINDContext == "" {

0 commit comments

Comments
 (0)