Skip to content

Commit

Permalink
Errors are present if the rows are *NOT* valid
Browse files Browse the repository at this point in the history
  • Loading branch information
stevorobs3 committed Dec 6, 2023
1 parent 9a3acfa commit 1ee3456
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/csv2rdf/csvw.clj
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
Returns a map with the key `:data-validation-errors?` set to a
boolean indicating whether any schema errors occurred."
[{:keys [tabular-source metadata-source]}]
{:data-validation-errors? (rows-are-valid? tabular-source metadata-source)})
{:data-validation-errors? (not (rows-are-valid? tabular-source metadata-source))})

(defn csv->rdf
"Runs the CSVW process for the given tabular or metadata data sources
Expand Down
2 changes: 1 addition & 1 deletion test/csv2rdf/main_test.clj
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
(t/is (= (sut/inner-main ["-t" tabular-file
"-u" metadata-file
"--validate-data"])
{:data-validation-errors? is-valid?}))
{:data-validation-errors? (not is-valid?)}))
(t/is (= @warnings failures))
(t/is (= @errors [])))))

Expand Down

0 comments on commit 1ee3456

Please sign in to comment.