-
Notifications
You must be signed in to change notification settings - Fork 212
Home
Welcome to the shUnit2 wiki. Feel free to contribute recommendations and solutions for unit testing with shUnit2.
shUnit2 was originally developed to provide a consistent testing solution for log4sh, a shell based logging framework similar to log4j. During the development of that product, I repeatedly ran into the problem of having things work just fine under one shell (/bin/bash
on Linux to be specific), and then not working under another shell (/bin/sh
on Solaris). Although I had some simple tests that I ran, I finally decided to develop a more robust unit test framework after releasing multiple brown-bag releases.
Rather than reinvent the wheel again, I chose to base the shUnit2 framework as much as possible on JUnit. I wanted something that was both incredibly easy to use, but that was as well incredibly powerful. I knew that the code would be built only for log4sh at the start, but hoped that someday I could release the code as a separate project. Now that the code is stable and mature enough, I have done just that.
You might ask why I didn't just use the already existing ShUnit product. I took a look at it, but wasn't really happy with how it worked or how little it reflected the way JUnit and other unit test frameworks function. I tried contacting the author, but after a few weeks of no response, I figured that it was probably better just to write my own.
shUnit2 has been developed under the Bourne Again Shell (/bin/bash
) on Linux, but great care has been taken to make sure it works under the other Unix shells to insure maximum compatibility. If you like what you see, or have any suggestions on improvements, please feel free to drop me an email.
Supported Operating Systems
- Cygwin (under Microsoft Windows XP)
- FreeBSD (user supported)
- Linux (Ubuntu)
- Mac OS X
- Solaris 8-10 and OpenSolaris
Tested Shells
- Bourne Shell (
sh
) -
BASH – GNU Bourne Again SHell (
bash
) -
DASH (
dash
) -
Korn Shell (
ksh
) -
pdksh – the Public Domain Korn Shell (
pdksh
) -
Zsh - (
zsh
)
There are two current release series of shUnit2 available. The 2.0 series is the stable release, and it contains only bug fixes. The 2.1 series is meant for new features and is still under active development. The 2.1 series of shUnit2 has its own set of unit tests, and should be considered stable for production use.
Release | Date | Known Issues |
---|---|---|
2.1.8pre | Active development | |
2.1.7 | Wed Jan 10 2018 | |
2.1.6 | Sun May 1 2011 | |
2.1.5 | Wed Oct 29 2008 | |
2.1.4 | Fri Jul 11 2008 | |
2.1.3 | Sun May 10 2008 | Doesn't work with zsh versions prior to 4.0. |
2.1.2 | Mon Dec 31 2007 | |
2.1.1 | Fri Jul 13 2007 | |
2.1.0 | Mon Apr 23 2007 |
Release | Date |
---|---|
2.0.3 | Thu Jul 12 2007 |
2.0.2 | Mon Apr 23 2007 |
2.0.1 | Wed Feb 21 2007 |
2.0.0 | Mon Feb 19 2007 |