Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Travis Reconfiguration to fix tests #413

Merged
merged 5 commits into from
Nov 6, 2018
Merged

Conversation

lumip
Copy link
Contributor

@lumip lumip commented Nov 5, 2018

Recently tests where failing for python 3.4 environment on travis.
We where using miniconda on travis to install gmpy2 more easily. conda install gmpy2 caused conda to update python to version 3.7 on this environment which in turn caused some test expecting a SyntaxError to fail because that SyntaxError wasn't raised anymore (my guess is that until recently either conda did only update the python version to 3.6).
Trying to fix this surfaced two more issues:

  • dependencies in requirements.txt where not available in python 3.4
  • a lot of SyntaxErrors in regular parts of code with python 3.4

I made the following changes:

  • Dropped official support for 3.4 in setup.py as our code is not compatible
  • Fixed problems tests had with python 3.7 and added travis test configuration
  • Completely removed usage of conda during tests on travis. For tests we need to be able to configure exactly what environment the tests are executed in. If miniconda changes this in the background, it's not useful.
  • No longer installing requirements.txt in travis tests. The travis.yml is configured so that different configurations of extras (as defined in setup.py) are tested (e.g., native types vs gmpy2 for faster/more precise arithmetics). Installing all requirements from requirements.txt beforehand defeats the purpose of this. (this does, however, open us up to the issue of dependencies becoming incompatible in future updates, for which I don't have a nice solution yet)

miniconda displayed annyoung behavior by updating the python version when
installing gmpy2. This doesn't make sense when explicitely testing a
specific python version. As this might happen again, it is safer not to
rely on miniconda but use the native python env.

installing from requirements.txt makes it difficult to sensibly test
different configuration of extra features as defined in setup.py (i.e.
using requirements would always install gmpy2 and matplotlib regardless of
whether these extra dependencies are specified when installing qupulse).
Codebase is syntactically incompatible with python 3.4 -> remove official
support.
@coveralls
Copy link

coveralls commented Nov 5, 2018

Pull Request Test Coverage Report for Build 1587

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 3 unchanged lines in 1 file lost coverage.
  • Overall coverage remained the same at 93.549%

Files with Coverage Reduction New Missed Lines %
qupulse/utils/types.py 3 100.0%
Totals Coverage Status
Change from base Build 1561: 0.0%
Covered Lines: 4616
Relevant Lines: 4869

💛 - Coveralls

Copy link
Member

@terrorfisch terrorfisch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

@terrorfisch terrorfisch merged commit 0fabda2 into master Nov 6, 2018
@lumip lumip deleted the fix/fixing_tests_rebase branch November 13, 2018 07:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants