simplify code for testing