Added some more unit tests.

Change-Id: I953a76baafa9462e3c71c50cfbec849dd2d3971b