lockedata / starters

R Package 📦 for initializing projects for various R activities :nut_and_bolt:
https://itsalocke.com/starters/
GNU General Public License v3.0
124 stars 16 forks source link

Add retries for repo deletion in tests #108

Closed stephlocke closed 5 years ago

stephlocke commented 5 years ago

In the latest master build https://travis-ci.org/lockedata/starters/builds/477852270#L1133

── 1. Error: createBasicProject() can create a GitHub repo (@test-AAA-createBasi GitHub API error (404): 404 Not Found Not Found 1: gh::gh("DELETE /repos/:owner/:repo", owner = "chibimaelle", repo = "test") at testthat/test-AAA-createBasicProject.R:109

maelle commented 5 years ago

I think it was a random API failure because it now passes.

stephlocke commented 5 years ago

hmm @maelle, should we be implementing retry logic to cope or would it be better to get retries into gh?

maelle commented 5 years ago

you mean in the tests or in the function?

stephlocke commented 5 years ago

in the function

maelle commented 5 years ago

Ok, will open an issue for that, but we might need retry for the deletion that happens in the tests.

maelle commented 5 years ago

In tests/test-AAA-createBasicProject.R

gh::gh("DELETE /repos/:owner/:repo",
    owner = "chibimaelle", repo = "test"
  )