Added unittests and removed pagination