diff --git a/tests/test_hex.sh b/tests/test_hex.sh index 0ad1be0..3340d10 100644 --- a/tests/test_hex.sh +++ b/tests/test_hex.sh @@ -3,7 +3,7 @@ test_btohex() { # FIXME: Remove grep when this bug is fixed: # https://github.com/sysprog21/rv32emu/issues/561 - result=$("${RV32EMU}" -d - -q tests/btohex.elf | grep -v '^\d' | "${JQ}" .x11) + result=$("${RV32EMU}" -d - -q tests/btohex.elf | grep -v '^[0-9]' | "${JQ}" .x11) # 16693 is 5A in ASCII (reversed from input due to little endian) test $? -eq 0 && test "${result}" -eq 13633 @@ -12,7 +12,7 @@ test_btohex() { test_tohex() { # FIXME: Remove grep when this bug is fixed: # https://github.com/sysprog21/rv32emu/issues/561 - result=$("${RV32EMU}" -q tests/tohex.elf | grep -v '^\d') + result=$("${RV32EMU}" -q tests/tohex.elf | grep -v '^[0-9]') test $? -eq 0 && test "${result}" = "CAFEFEED" }