Skip to content

sanity check of before/after should run as a set #29

@stagrlee

Description

@stagrlee

Before should setup a test case condition.
After should clean up that condition to eliminate side effects put in by "before". Therefore, it is typical to pass state from before to after which cleans up the mess. For instance, creating a scratch directory in before with "mktemp -d" should be deleted by after... This doesn't work when roundup tests the sanity of before/after and you end up with side effects.

before() {
    OUT=$(mktemp -d "/tmp/roundup.test.XXXXX")
}

after() {
    rm -rf ${OUT}
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions