Skip to content

Commit 86f1935

Browse files
committed
better error message
1 parent 9f7b49b commit 86f1935

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ func ValidateLogConfig(origin string, rootsPemFile string, rejectExpired bool, r
7979

8080
// Validate the time interval.
8181
if notAfterStart != nil && notAfterLimit != nil && (notAfterLimit).Before(*notAfterStart) {
82-
return nil, fmt.Errorf("limit %q before start %q", notAfterLimit.Format(time.RFC3339), notAfterStart.Format(time.RFC3339))
82+
return nil, fmt.Errorf("not_after limit %q before start %q", notAfterLimit.Format(time.RFC3339), notAfterStart.Format(time.RFC3339))
8383
}
8484

8585
validationOpts := CertValidationOpts{

config_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ func TestValidateLogConfig(t *testing.T) {
7676
},
7777
{
7878
desc: "rejecting-all",
79-
wantErr: "rejecting all certificates",
79+
wantErr: "configuration would reject all certificates",
8080
origin: "testlog",
8181
projectID: "project",
8282
bucket: "bucket",
@@ -132,7 +132,7 @@ func TestValidateLogConfig(t *testing.T) {
132132
},
133133
{
134134
desc: "limit-before-start",
135-
wantErr: "limit before start",
135+
wantErr: "before start",
136136
origin: "testlog",
137137
projectID: "project",
138138
bucket: "bucket",

0 commit comments

Comments
 (0)