Skip to content

Commit

Permalink
data-quality: schedule: Exception dates error type update
Browse files Browse the repository at this point in the history
  • Loading branch information
Jared Parnell committed Mar 31, 2021
1 parent 0f62fe7 commit 1d8088e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/errors/validation-error-type.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ const ValidationErrorType = {
FIELD_NOT_ALLOWED: 'field_not_allowed',
BELOW_MIN_VALUE_INCLUSIVE: 'below_min_value_inclusive',
URI_TEMPLATE_MISSING_PLACEHOLDER: 'uri_template_missing_placeholder',
EXCEPTION_DATES_NOT_IN_SCHEDULE: 'exception_dates_not_in_schedule',
};

module.exports = Object.freeze(ValidationErrorType);
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ describe('ExceptDatesAreInSchedule', () => {

expect(errors.length).toBe(1);
for (const error of errors) {
expect(error.type).toBe(ValidationErrorType.MISSING_REQUIRED_FIELD);
expect(error.type).toBe(ValidationErrorType.EXCEPTION_DATES_NOT_IN_SCHEDULE);
expect(error.severity).toBe(ValidationErrorSeverity.WARNING);
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ module.exports = class ExceptDatesAreInSchedule extends Rule {
},
category: ValidationErrorCategory.CONFORMANCE,
severity: ValidationErrorSeverity.WARNING,
type: ValidationErrorType.MISSING_REQUIRED_FIELD,
type: ValidationErrorType.EXCEPTION_DATES_NOT_IN_SCHEDULE,
},
},
};
Expand Down

0 comments on commit 1d8088e

Please sign in to comment.