-
Notifications
You must be signed in to change notification settings - Fork 112
Use Travis-ci to run the tests for you #90
Comments
Just in case anyone is struggling with this issue - it's worth noting that for automated testing to work when you push to GitHub, if you haven't specified in .travis.yml which branches to build, then "for historical reasons .travis.yml needs to be present on all active branches of your project" https://docs.travis-ci.com/user/customizing-the-build |
@twemyss Hi, I am not sure I understand correctly. |
@cristinafni For me it's working with |
@cristinafni @ucapgum Ah glad to hear it's working - I had the issue that it wouldn't even automatically build my testing branch (I checked by choosing the branch in travis and then looked for builds) until I also added .travis.yml onto the main branch (even though I wasn't using the main branch for the tests), but if it's working anyway then that's great. I think the badge in travis will always show "unknown" because it shows the main branch only - but I could be wrong there. |
It seems that the problem occurs when you add .travis.yml file inside week05-testing folder (or any folder in the branch). For some reason Travis CI can't access it. The solution is to add the .travis.yml file to the testing branch, alongside with README.md and week05-testing, and not in a file. |
Answers UCL Issue UCL-RITS#90
Use CI to run the tests for you.
It's always possible that we forget to run the tests before pushing to GitHub. Luckily, continuous integration platforms can help us catch failing tests even when we do forget to run them.
In this exercise, you will use Travis-CI to do exactly this.
Set up Travis-ci to run our tests for every commit we push to our repository.
.travis.yml
to the repository, commit it and push it to github. Link to this issue on that commit.If you're done with this issue, try to add test coverage (first locally, then on Travis) by working on this related issue: #91
Sample solution to this issue and to #91: the
.travis.yml
file might look something like this.The text was updated successfully, but these errors were encountered: