Page MenuHomePhabricator

Travis apt addon not working for matrix: include:
Closed, ResolvedPublic

Description

Travis APT addon feature has been used to install

  • djvulibre-bin
  • graphviz
  • liblua5.1-dev

Travis has not been executing the APT addon for the jobs in the matrix: include: section after 8004cdfe29 due to https://github.com/travis-ci/travis-ci/issues/5405 . See build #2754.9 for the first job log without the APT packages section at the top, compared to build #2753

i.e. the following are not the same

os: linux
os:
  - linux

The apt: addon is inherited in matrix: include: in the former, but not in the latter.

The unit tests automatically skip tests, and this went unnoticed.

At least djvu tests downgraded to skip some tests.

graphviz and liblua5.1-dev are not used by all of these jobs, as the relevant tests depend on python modules which are only installed with PYSETUP_TEST_EXTRAS=1 (or requirements.txt, but that came later)

Event Timeline

Change 289659 had a related patch set uploaded (by John Vandenberg):
Re-enable APT addon for jobs in matrix include

https://gerrit.wikimedia.org/r/289659

Possibly a comment for a new Phab task:
I think there is an underlying issue about the fact that when pytest skips tests, travis doesn't fail.
There was an issue on pytest about this a while back which I had given up on which I have reinitiated conversation about:
https://github.com/pytest-dev/pytest/issues/1364

Based on that discussion: if we're using pytest, one possible method would be to override the unittest.skipIf decorators in the tests/__init__.py where we already do try/catch for unittest2 to add a pytest fixture which is later handled in conftest.

This was we can specify which tests (or how many tests) should skip in each CI job using an env variable or in the tox.ini

Change 289659 merged by jenkins-bot:
Re-enable APT addon for jobs in matrix include

https://gerrit.wikimedia.org/r/289659

jayvdb claimed this task.