Sign inSign up

backplane/shunit2

By backplane

•Updated about 21 hours ago

alpine:edge-based dockerization of shUnit2, the "xUnit-based unit test framework for Bourne-based sh

Image
0

10K+

backplane/shunit2 repository overview

⁠shunit2

alpine:edge⁠-based dockerization of shUnit2⁠, the "xUnit-based unit test framework for Bourne-based shell scripts."

The source code for this image is hosted on GitHub in the backplane/conex repo⁠.

⁠Usage

The image will set the SHUNIT_PATH environment variable (to /shunit). It will provide the latest version of shunit at /shunit. At the end of your shell tests, load shunit with something like the following line:

# shellcheck source=/dev/null
. ${SHUNIT_PATH:-../shunit}

or simply

# shellcheck source=/dev/null
. "$SHUNIT_PATH"

Then with the interactive shunit2 alias below,

⁠Interactive

shunit2() {
  docker run \
    --rm \
    --interactive \
    --tty \
    --volume "$(pwd):/work" \
    "backplane/shunit2" \
    "$@"
}

Simply run shunit2 from the project root directory.

Tag summary

Content type

Image

Digest

sha256:d5888916c…

Size

8.1 MB

Last updated

about 21 hours ago

docker pull backplane/shunit2