peritus / bumpversion

Version-bump your software with a single command
https://pypi.python.org/pypi/bumpversion
MIT License
1.5k stars 148 forks source link

Tests fail due to unified_diff output difference in 2.7.10, 3.2 #145

Open garyjohnson opened 8 years ago

garyjohnson commented 8 years ago

The unified_diff() header usually doesn't include the count when there is only one line. The tests assume this to be true when testing for @@ -1 +1 @@ as part of the CLI output.

For some reason in 2.7.10 and 3.2 specifically, the unified_diff output includes the count (@@ -1,1 +1,1 @@). This doesn't appear to occur in <=2.7.9 or >=3.3.

I haven't found a changelog for these python versions that describes this behavior. In regards to a fix would your preference be to attempt to force the output to match across all versions, attempt to make the tests less dependent on matching this string, or have tests specific to these versions of Python?