[#1697] Simplify _is_test() a bit