summaryrefslogtreecommitdiff
path: root/git/test/test_fun.py
Commit message (Collapse)AuthorAgeFilesLines
* Unnecessary generator - rewrite as a set comprehensionHugo2018-03-181-1/+1
|
* Drop support for EOL Python 2.6Hugo2018-03-181-5/+1
|
* Repo: handle worktrees betterPeter Jones2017-07-011-5/+37
| | | | | | | | | | | | | This makes Repo("foo") work when foo/.git is a file of the form created by "git worktree add", i.e. it's a text file that says: gitdir: /home/me/project/.git/worktrees/bar and where /home/me/project/.git/ is the nominal gitdir, but /home/me/project/.git/worktrees/bar has this worktree's HEAD etc and a "gitdir" file that contains the path of foo/.git . Signed-off-by: Peter Jones <pjones@redhat.com>
* Fixes to support Python 2.6 again.Andreas Maier2016-10-241-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Details: - Added Python 2.6 again to .travis.yml (it was removed in commit 4486bcb). - Replaced the use of dictionary comprehensions in `git/cmd.py` around line 800 with the code before that change (in commit 25a2ebf). Reason: dict comprehensions were introduced only in Python 2.7. - Changed the import source for `SkipTest` and `skipIf` from `unittest.case` to first trying `unittest` and upon ImportError from `unittest2`. This was done in `git/util.py` and in several testcases. Reason: `SkipTest` and `skipIf` were introduced to unittest only in Python 2.7, and `unittest2` is a backport of `unittest` additions to Python 2.6. - In git/test/lib/helper.py, fixed the definition of `assertRaisesRegex` to work on py26. - For Python 2.6, added the `unittest2` dependency to `requirements.txt` and changed `.travis.yml` to install `unittest2`. Because git/util.py uses SkipTest from unittest/unittest2, the dependency could not be added to `test-requirements.txt`. - Fixed an assertion in `git/test/test_index.py` to also allow a Python 2.6 specific exception message. - In `is_cygwin_git()` in `git/util.py`, replaced `check_output()` with `Popen()`. It was added in Python 2.7. - Enabled Python 2.6 for Windows: - Added Python 2.6 for MINGW in .appveyor.yml. - When defining `PROC_CREATIONFLAGS` in `git/cmd.py`, made use of certain win32 and subprocess flags that were introduced in Python 2.7, dependent on whether we run on Python 2.7 or higher. - In `AutoInterrupt.__del__()` in `git/cmd.py`, allowed for `os` not having `kill()`. `os.kill()` was added for Windows in Python 2.7 (For Linux, it existed in Python 2.6 already).
* Merge with #532, fix unicode filenames with escapesurogatesKostis Anagnostopoulos2016-10-161-7/+11
|\
| * fix(surrogateescape): enable on py2, fix testsSebastian Thiel2016-10-161-2/+10
| |
* | src: reduce needless deps to `gitdb.util`Kostis Anagnostopoulos2016-10-161-17/+14
|/
* test_fun worksSebastian Thiel2015-01-051-6/+6
|
* Fixed io types to make tests work on PY2 once again.py3Sebastian Thiel2015-01-051-2/+2
| | | | Now it's about going through PY3 issues
* initial set of adjustments to make (most) imports work.Sebastian Thiel2015-01-041-1/+1
| | | | More to come, especially when it's about strings
* Removed 'from X import *' whereever possibleSebastian Thiel2015-01-041-2/+5
|
* Applied autopep8Sebastian Thiel2014-11-191-11/+11
| | | | | Commandline was autopep8 -j 8 --max-line-length 120 --in-place --recursive --exclude "*gitdb*,*async*" git/
* pep8 linting (trailing whitespace)Antoine Musso2014-11-161-3/+3
| | | | W291 trailing whitespace
* pep8 linting (whitespace before/after)Antoine Musso2014-11-161-5/+5
| | | | | | | | | | | | | E201 whitespace after '(' E202 whitespace before ')' E203 whitespace before ':' E225 missing whitespace around operator E226 missing whitespace around arithmetic operator E227 missing whitespace around bitwise or shift operator E228 missing whitespace around modulo operator E231 missing whitespace after ',' E241 multiple spaces after ',' E251 unexpected spaces around keyword / parameter equals
* pep8 linting (blank lines expectations)Antoine Musso2014-11-161-1/+3
| | | | | | E301 expected 1 blank line, found 0 E302 expected 2 blank lines, found 1 E303 too many blank lines (n)
* pep8 linting (whitespaces)Antoine Musso2014-11-161-40/+40
| | | | | | | | | | | W191 indentation contains tabs E221 multiple spaces before operator E222 multiple spaces after operator E225 missing whitespace around operator E271 multiple spaces after keyword W292 no newline at end of file W293 blank line contains whitespace W391 blank line at end of file
* Merge branch 'sf-master' of https://github.com/johnsca/GitPython into ↵Sebastian Thiel2014-11-151-1/+6
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | johnsca-sf-master Conflicts: git/cmd.py git/objects/commit.py git/objects/fun.py git/objects/util.py git/remote.py git/repo/base.py git/test/lib/helper.py git/test/test_commit.py git/test/test_fun.py git/util.py
| * Fix whacky indentationTim Van Steenburgh2013-04-171-3/+3
| | | | | | | | Signed-off-by: Tim Van Steenburgh <tvansteenburgh@gmail.com>
| * Return bytes if object name can't be utf8-decodedTim Van Steenburgh2013-04-171-0/+5
| | | | | | | | Signed-off-by: Tim Van Steenburgh <tvansteenburgh@gmail.com>
* | tabs to 4 spaces - this won't make integrating the patches easier, but it's ↵Sebastian Thiel2014-02-091-235/+235
|/ | | | probably a good idea to go a little more pep8 (and fix sins of my youth ;) )
* Moved everything into the git subdirectory - some tests still need to be ↵Sebastian Thiel2010-11-251-0/+251
adjusted