added unittests for swait.py