Check internet connectivity before running HTTP tests
lestrrat opened this issue · 0 comments
lestrrat commented
Sometimes I work when there's connectivity, sometimes I don't have connection. It's really annoying for a test to fail just because of this.
Would it be feasible to skip the tests that downloads specs from the internet when appropriate? I can see two possibilities:
a. Skip if there's no connectivity -- that is, if http.Get(url)
fails, don't run the subsequent test.
b. Skip if the test if -short
is specified. This at least gives you the option to skip if desired.