improve testing framework