Additional tests added.  Two bug fixes based on test failures.