increase coverage
fix sytax err with tests
simplify conditional logic