diff options
author | Kostis Anagnostopoulos <ankostis@gmail.com> | 2016-10-15 14:52:40 +0200 |
---|---|---|
committer | Kostis Anagnostopoulos <ankostis@gmail.com> | 2016-10-16 02:46:33 +0200 |
commit | 4486bcbbf49ad0eacf2d8229fb0e7e3432f440d9 (patch) | |
tree | b3eaeea98f0de34084aa30eb1e1da0b32632d5b0 | |
parent | b02662d4e870a34d2c6d97d4f702fcc1311e5177 (diff) | |
download | gitpython-4486bcbbf49ad0eacf2d8229fb0e7e3432f440d9.tar.gz |
ci, deps: no PY26, ddt>=1.1.1, CIs `pip install test-requirements`
+ Use environment-markers in requirement files (see
http://stackoverflow.com/a/33451105/548792).
-rw-r--r-- | .appveyor.yml | 6 | ||||
-rw-r--r-- | .travis.yml | 7 | ||||
-rw-r--r-- | git/test/test_repo.py | 3 | ||||
-rw-r--r-- | git/test/test_submodule.py | 2 | ||||
-rw-r--r-- | git/util.py | 2 | ||||
-rw-r--r-- | requirements.txt | 3 | ||||
-rwxr-xr-x | setup.py | 2 | ||||
-rw-r--r-- | test-requirements.txt | 2 |
8 files changed, 9 insertions, 18 deletions
diff --git a/.appveyor.yml b/.appveyor.yml index 1a38d185..0237d2e5 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -51,10 +51,8 @@ install: conda info -a & conda install --yes --quiet pip ) - - pip install nose ddt wheel codecov - - IF "%PYTHON_VERSION%" == "2.7" ( - pip install mock - ) + - pip install -r test-requirements.txt + - pip install codecov ## Copied from `init-tests-after-clone.sh`. # diff --git a/.travis.yml b/.travis.yml index 4c191db2..f7dd247b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,14 +1,10 @@ language: python python: - - "2.6" - "2.7" - "3.3" - "3.4" - "3.5" # - "pypy" - won't work as smmap doesn't work (see gitdb/.travis.yml for details) -matrix: - allow_failures: - - python: "2.6" 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 @@ -17,7 +13,8 @@ install: - python --version; git --version - git submodule update --init --recursive - git fetch --tags - - pip install codecov flake8 ddt sphinx + - 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 diff --git a/git/test/test_repo.py b/git/test/test_repo.py index 495c4337..11c720e9 100644 --- a/git/test/test_repo.py +++ b/git/test/test_repo.py @@ -900,9 +900,6 @@ class TestRepo(TestBase): for i, j in itertools.permutations([c1, 'ffffff', ''], r=2): self.assertRaises(GitCommandError, repo.is_ancestor, i, j) - # @skipIf(HIDE_WINDOWS_KNOWN_ERRORS, - # "FIXME: helper.wrapper fails with: PermissionError: [WinError 5] Access is denied: " - # "'C:\\Users\\appveyor\\AppData\\Local\\Temp\\1\\test_work_tree_unsupportedryfa60di\\master_repo\\.git\\objects\\pack\\pack-bc9e0787aef9f69e1591ef38ea0a6f566ec66fe3.idx") # noqa E501 @with_rw_directory def test_work_tree_unsupported(self, rw_dir): git = Git(rw_dir) diff --git a/git/test/test_submodule.py b/git/test/test_submodule.py index da304944..bbf242c0 100644 --- a/git/test/test_submodule.py +++ b/git/test/test_submodule.py @@ -730,7 +730,7 @@ class TestSubmodule(TestBase): assert commit_sm.binsha == sm_too.binsha assert sm_too.binsha != sm.binsha - # @skipIf(HIDE_WINDOWS_KNOWN_ERRORS, + # @skipIf(HIDE_WINDOWS_KNOWN_ERRORS, ## ACTUALLY skipped by `git.submodule.base#L869`. # "FIXME: helper.wrapper fails with: PermissionError: [WinError 5] Access is denied: " # "'C:\\Users\\appveyor\\AppData\\Local\\Temp\\1\\test_work_tree_unsupportedryfa60di\\master_repo\\.git\\objects\\pack\\pack-bc9e0787aef9f69e1591ef38ea0a6f566ec66fe3.idx") # noqa E501 @with_rw_directory diff --git a/git/util.py b/git/util.py index fdb12529..c3c8e562 100644 --- a/git/util.py +++ b/git/util.py @@ -56,7 +56,7 @@ log = logging.getLogger(__name__) #: so the errors marked with this var are considered "acknowledged" ones, awaiting remedy, #: till then, we wish to hide them. HIDE_WINDOWS_KNOWN_ERRORS = is_win and os.environ.get('HIDE_WINDOWS_KNOWN_ERRORS', True) -HIDE_WINDOWS_FREEZE_ERRORS = is_win and os.environ.get('HIDE_WINDOWS_FREEZE_ERRORS', HIDE_WINDOWS_KNOWN_ERRORS) +HIDE_WINDOWS_FREEZE_ERRORS = is_win and os.environ.get('HIDE_WINDOWS_FREEZE_ERRORS', True) #{ Utility Methods diff --git a/requirements.txt b/requirements.txt index 85d25511..39644606 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,3 +1,2 @@ gitdb>=0.6.4 -ddt -mock
\ No newline at end of file +ddt>=1.1.1 @@ -68,7 +68,7 @@ install_requires = ['gitdb >= 0.6.4'] extras_require = { ':python_version == "2.6"': ['ordereddict'], } -test_requires = ['ddt'] +test_requires = ['ddt>=1.1.1'] if sys.version_info[:2] < (2, 7): test_requires.append('mock') diff --git a/test-requirements.txt b/test-requirements.txt index 4d08a501..8f13395d 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -3,4 +3,4 @@ coverage flake8 nose -mock +mock; python_version<='2.7' |