Added test.
Fixed some tests.