Test all branches of GH URI-parsing code
When a user adds a registry (e.g., through a command like `ks registry add`, or implicitly through `ks init`) we must parse a URI pointing at registry hosted on github.com, since we currently only support the `"github"` protocol. This logic is somewhat complex, since we must 1. infer the location of a `registry.yaml` file given the URI, and 2. accept and parse a broad set of URIs a user might provide. For example, consider the following valid URIs, and what we do to infer the location of the `registry.yaml` file that specifies a registry: URIs with an explicit `registry.yaml`: github.com/exampleOrg/exampleRepo/blob/master/registry.yaml github.com/exampleOrg/exampleRepo/blob/master/incubator/registry.yaml URIs with an implicit `registry.yaml`: github.com/exampleOrg/exampleRepo/ github.com/exampleOrg/exampleRepo/tree/master URIs with different protocols (or no protocol specified) github.com/exampleOrg/exampleRepo http://github....
Please register or sign in to comment