diff --git a/.travis.yml b/.travis.yml index adb693dd2..1055b1519 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,47 +1,66 @@ -language: python -python: - - "2.7" - - "3.4" - - "3.5" - - "3.6" - # - "pypy" - won't work as smmap doesn't work (see gitdb/.travis.yml for details) -matrix: - include: - - python: 3.7 - dist: xenial - sudo: required - - python: "nightly" - dist: xenial - sudo: required - allow_failures: - - python: "nightly" -git: - # a higher depth is needed for most of the tests - must be high enough to not actually be shallow - # as we clone our own repository in the process - depth: 99999 -install: - - python --version; git --version - - git submodule update --init --recursive - - git fetch --tags - - pip install -r test-requirements.txt - - pip install codecov sphinx +# language: python +# python: +# - "2.7" +# - "3.4" +# - "3.5" +# - "3.6" +# # - "pypy" - won't work as smmap doesn't work (see gitdb/.travis.yml for details) +# git: +# # a higher depth is needed for most of the tests - must be high enough to not actually be shallow +# # as we clone our own repository in the process +# depth: 99999 +# install: +# - python --version; git --version +# - git submodule update --init --recursive +# - git fetch --tags +# - pip install -r test-requirements.txt +# - pip install codecov sphinx +# +# # generate some reflog as git-python tests need it (in master) +# - ./init-tests-after-clone.sh +# +# # as commits are performed with the default user, it needs to be set for travis too +# - git config --global user.email "travis@ci.com" +# - git config --global user.name "Travis Runner" +# # If we rewrite the user's config by accident, we will mess it up +# # and cause subsequent tests to fail +# - cat git/test/fixtures/.gitconfig >> ~/.gitconfig +# script: +# # Make sure we limit open handles to see if we are leaking them +# - ulimit -n 128 +# - ulimit -n +# - nosetests -v --with-coverage --with-xunit +# - if [ "$TRAVIS_PYTHON_VERSION" == '3.4' ]; then flake8 --ignore=W293,E265,E266,W503,W504,E731; fi +# - if [ "$TRAVIS_PYTHON_VERSION" == '3.5' ]; then cd doc && make html; fi +# - +# after_script: +# - tomato nosetests.xml +# after_success: +# - codecov - # generate some reflog as git-python tests need it (in master) - - ./init-tests-after-clone.sh - # as commits are performed with the default user, it needs to be set for travis too - - git config --global user.email "travis@ci.com" - - git config --global user.name "Travis Runner" - # If we rewrite the user's config by accident, we will mess it up - # and cause subsequent tests to fail - - cat git/test/fixtures/.gitconfig >> ~/.gitconfig +language: node_js +sudo: false +node_js: + - 10 + - 9 + - 8 + - 7 + - 6 script: - # Make sure we limit open handles to see if we are leaking them - - ulimit -n 128 - - ulimit -n - - nosetests -v --with-coverage - - if [ "$TRAVIS_PYTHON_VERSION" == '3.4' ]; then flake8 --ignore=W293,E265,E266,W503,W504,E731; fi - - if [ "$TRAVIS_PYTHON_VERSION" == '3.5' ]; then cd doc && make html; fi - - -after_success: - - codecov + - python -V + - env + +# language: python +# matrix: +# include: +# - name: "3.5 Unit Test" +# python: "3.5" +# env: TEST_SUITE=suite_3_5_unit +# - name: "3.5 Integration Tests" +# python: "3.5" +# env: TEST_SUITE=suite_3_5_integration +# - name: "pypy Unit Tests" +# python: "pypy" +# env: TEST_SUITE=suite_pypy_unit +# script: env diff --git a/git/test/test_fail.py b/git/test/test_fail.py new file mode 100644 index 000000000..11eaf057c --- /dev/null +++ b/git/test/test_fail.py @@ -0,0 +1,8 @@ +import sys + + +def test_add3(): + assert 1 + 1 == 2 + + # fail in python 2 only + assert sys.version_info.major == 3 diff --git a/test-requirements.txt b/test-requirements.txt index 1cea3aa21..12442f380 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -3,4 +3,5 @@ coverage flake8 nose -mock; python_version=='2.7' \ No newline at end of file +git+https://github.com/moshe/pytest-tomato.git@debug#subdirectory=tomato-lib +mock; python_version=='2.7'