Add tests
Support uri string inplace of opts obj