CircleCI-Public / orb-tools-orb

Various tools for authoring and publishing CircleCI orbs
https://circleci.com/orbs/registry/orb/circleci/orb-tools
MIT License
51 stars 74 forks source link

Automatically disable irrelevant tests for private orbs #203

Open KyleTryon opened 1 year ago

KyleTryon commented 1 year ago

Describe Request:

This is a continuation of #179. While private orbs are supported by Orb Tools, out of the box a user will experience a failure at first due to RC006 and RC008 which are looking for an accessible home_url and source_url. home_url may not be required for private orbs, and the source_url will return a 404 unless authenticated due to being a private repo.

In order to provide a better experience for private orb developers out of the box, we may want to consider a method of automatically disabling these tests, exclusively for private orbs.

Solution proposal

While not the most scalable, I recommend automatically including these tests in the exclusion list as a part of the orb creation via the orb init command. Most other solutions would both require that we somehow pass along metadata to the orb that it is private, as well as silently skipping the referenced checks.

If we add the exclusions to the config automatically, the orb does not actually require any updates and the user has the test explicitly skipped in their config so that nothing is hidden.

joshbranham commented 1 year ago

Just ran into this today as well.