add indexurl
run tests on cached json
little bit o' refactoring