Fixed #29. Fixed all tests that got broken in last changeset.