separated all tests into functions and added 1 more test