TST: improve the testing script