Added unittests.