test(ruleparser): add a bunch of tests and begin of logic