improve test method()