Skip to content

Test the executed outputs of the original script and the script after a shasta roundtrip #6

Description

@BolunThompson

Right now, the tests work by comparing the pretty printed output of parsing the test script, and the pretty printed output of that first roundtrip parsed again. However, that may miss certain bugs. For example, using bash:

case 1 in
    1) echo "1";&  
    2) echo "2";;
esac  

should print:

1
2

since the first case should fall through to the second. However, there used to be a bug where it was instead parsed as:

case 1 in
    1) echo "1";;  
    2) echo "2";;
esac  

with no fall through. This passed the tests since the first and second round trips are the same, despite the different semantics. Adding additional tests to compare the execution would fix this. I don’t think this would cause an issue, as long as we filter out any tests that don’t terminate or are otherwise misbehaved.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions