test: more test cases & some cleanup