diff --git a/functional-tests/cache-functional-tests.scm b/functional-tests/cache-functional-tests.scm index a6136f5..f69b814 100644 --- a/functional-tests/cache-functional-tests.scm +++ b/functional-tests/cache-functional-tests.scm @@ -133,6 +133,13 @@ (cache-restore "-i" xml "-o" md "--debug-override-metadata-version" "12345") (run-fail "cache_check" md)))) + (define-scenario (cache-check dont-repair-xml) + "Fails gracefully if run on XML rather than metadata" + (with-cache-xml (xml) + (with-empty-metadata (md) + (receive (_ stderr) (run-fail "cache_check " xml) + #t)))) + ;;;----------------------------------------------------------- ;;; cache_restore scenarios ;;;----------------------------------------------------------- diff --git a/functional-tests/thin-functional-tests.scm b/functional-tests/thin-functional-tests.scm index aa0e2d7..1f04045 100644 --- a/functional-tests/thin-functional-tests.scm +++ b/functional-tests/thin-functional-tests.scm @@ -260,6 +260,12 @@ (with-valid-metadata (md) (thin-rmap "--region 1..23 --region 45..78" md))) + (define-scenario (thin-rmap handles-junk-input) + "Fail gracefully if given nonsense" + (with-thin-xml (xml) + (receive (_ stderr) (run-fail "thin_rmap --region 0..-1" xml) + #t))) + ;;;----------------------------------------------------------- ;;; thin_delta scenarios ;;;-----------------------------------------------------------