From 89d65d14f1451ecb5f84276801cab3927afc0586 Mon Sep 17 00:00:00 2001 From: Trevor Gross Date: Tue, 19 Mar 2024 13:02:26 -0400 Subject: [PATCH] Add a file from a previous fuzzer crash --- .gitattributes | 4 ++-- justfile | 3 ++- ...h-4b0422bb457cd6b39d1f8549f6739830254718a0z-assertion | 9 +++++++++ 3 files changed, 13 insertions(+), 3 deletions(-) create mode 100644 test/crash-4b0422bb457cd6b39d1f8549f6739830254718a0z-assertion diff --git a/.gitattributes b/.gitattributes index 89427e5..570abe3 100644 --- a/.gitattributes +++ b/.gitattributes @@ -10,5 +10,5 @@ src/node-types.json -diff src/parser.c -diff # These test files are from the fuzzer -test/**/timeout-* binary -test/**/crash-* binary +test/**timeout-* binary +test/**crash-* binary diff --git a/justfile b/justfile index 92dce72..46ca2cf 100644 --- a/justfile +++ b/justfile @@ -35,6 +35,7 @@ make_timeout_fn := '''timeout () { perl -e 'alarm shift; exec @ARGV' "$@"; }''' # Files that should parse with errors but not crash errors_expected := ''' test/timeout-1aa6bf37e914715f4aa49e6cf693f7abf81aaf8e + test/crash-4b0422bb457cd6b39d1f8549f6739830254718a0z-assertion # FIXME: xfail files, these should parse correctly repositories/just/examples/kitchen-sink.just @@ -156,7 +157,7 @@ test-parse-highlight: _clone-repo-just just_path = Path(r"{{ just_path }}") repo_files = sp.check_output( - ["git", "ls-files", "*.just", "*justfile", "*timeout", "*crash"], + ["git", "ls-files", "*.just", "*justfile", "*timeout*", "*crash*"], encoding="utf8", shell=shell ) just_repo_files = sp.check_output( diff --git a/test/crash-4b0422bb457cd6b39d1f8549f6739830254718a0z-assertion b/test/crash-4b0422bb457cd6b39d1f8549f6739830254718a0z-assertion new file mode 100644 index 0000000..bd3a99d --- /dev/null +++ b/test/crash-4b0422bb457cd6b39d1f8549f6739830254718a0z-assertion @@ -0,0 +1,9 @@ +: +ÿÿa''' +bar:= '''b + c'ÿÿÿ}ÿÿÿÿÿa''' +bar:= '''b + c +''' +bazi: : +iº ## \ No newline at end of file