simplifying test code