Some fix to testing

Still need improvement for testing