test: Refactored test suite

Refactored test suite and added tests for all newly added functionality