Skip to content

Commit ecd7ce3

Browse files
committed
Feedback
1 parent 85585f2 commit ecd7ce3

File tree

3 files changed

+11
-12
lines changed

3 files changed

+11
-12
lines changed

tests/ci/run_x509_limbo.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ source tests/ci/common_posix_setup.sh
1010
# Subsequent follow-up PRs will wire this up into a new CodeBuild project and handle producing and tracking
1111
# the reports.
1212

13-
SCRATCH_DIR="${SRC_ROOT}/scratch"
13+
SCRATCH_DIR="${SYS_ROOT}/scratch"
1414
X509_CI_DIR="${SRC_ROOT}/tests/ci/x509"
1515
X509_LIMBO_SRC="${SCRATCH_DIR}/x509-limbo"
1616

tests/ci/x509/limbo-report/annotate.go

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import (
1414
"sort"
1515
)
1616

17-
var annotateHelpDoc string = `report annotate [-csv] -limbo <limboFile> <resultFile>
17+
var annotateHelpDoc string = `report annotate [-csv] <limboFile> <resultFile>
1818
1919
Annotates a standard x509-limbo results file with information from the provided <limboFile> test descriptors.
2020
By default this will write the result back to the process standard output.
@@ -24,13 +24,11 @@ Options:
2424
`
2525

2626
var annotateCommand struct {
27-
limboFilePath string
28-
formatAsCsv bool
27+
formatAsCsv bool
2928
}
3029

3130
var annotateFlagSet = func() *flag.FlagSet {
3231
fs := flag.NewFlagSet("annotate", flag.ExitOnError)
33-
fs.StringVar(&annotateCommand.limboFilePath, "limbo", "limbo.json", "location of the limbo test cases")
3432
fs.BoolVar(&annotateCommand.formatAsCsv, "csv", false, "format output as csv rather then the default")
3533
fs.Usage = func() {
3634
fmt.Fprint(fs.Output(), annotateHelpDoc)
@@ -43,16 +41,17 @@ func runAnnotateCommand(args []string) error {
4341
if err := annotateFlagSet.Parse(args); err != nil {
4442
return err
4543
}
46-
limbo, err := parseLimboFile(annotateCommand.limboFilePath)
47-
if err != nil {
48-
return err
44+
45+
if len(annotateFlagSet.Args()) != 2 {
46+
return fmt.Errorf("expect two positional arguments")
4947
}
5048

51-
if len(annotateFlagSet.Args()) != 1 {
52-
return fmt.Errorf("expect one positional argument for the result file name")
49+
limbo, err := parseLimboFile(annotateFlagSet.Arg(0))
50+
if err != nil {
51+
return err
5352
}
5453

55-
harnessFilePath := annotateFlagSet.Arg(0)
54+
harnessFilePath := annotateFlagSet.Arg(1)
5655
harnessBytes, err := os.ReadFile(harnessFilePath)
5756
if err != nil {
5857
log.Fatalf("failed to read harnessFile(%v): %v", harnessFilePath, err)

tests/ci/x509/x509-limbo.patch

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ index 0000000..2305b42
7373
+
7474
+.PHONY: verify-aws-lc-source
7575
+verify-aws-lc-source:
76-
+ @if [[ -z "${AWS_LC_SRC_DIR}" ]]; then \
76+
+ @if [ test -z "${AWS_LC_SRC_DIR}" ]; then \
7777
+ echo "AWS_LC_SRC_DIR environment variable is missing and is required to specify AWS-LC source location" && false; \
7878
+ fi
7979
+

0 commit comments

Comments
 (0)