| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -33,6 +33,7 @@ | |||
| 33 | 33 | import sys | |
| 34 | 34 | import tempfile | |
| 35 | 35 | import shutil | |
| 36 | + from unittest import skipIf | ||
| 36 | 37 | from stat import ( | |
| 37 | 38 | S_ISLNK, | |
| 38 | 39 | ST_MODE | |
@@ -135,7 +136,7 @@ def _cmp_tree_index(self, tree, index): | |||
| 135 | 136 | raise AssertionError("CMP Failed: Missing entries in index: %s, missing in tree: %s" % | |
| 136 | 137 | (bset - iset, iset - bset)) | |
| 137 | 138 | # END assertion message | |
| 138 | - | ||
| 139 | + | ||
| 139 | 140 | @with_rw_repo('0.1.6') | |
| 140 | 141 | def test_index_lock_handling(self, rw_repo): | |
| 141 | 142 | def add_bad_blob(): | |
@@ -155,6 +156,7 @@ def add_bad_blob(): | |||
| 155 | 156 | except Exception as ex: | |
| 156 | 157 | assert "index.lock' could not be obtained" not in str(ex) | |
| 157 | 158 | ||
| 159 | + @skipIf(sys.version_info < (2, 7), reason="not `assertRaisesRegexp` in py2.6") | ||
| 158 | 160 | @with_rw_repo('0.1.6') | |
| 159 | 161 | def test_index_file_from_tree(self, rw_repo): | |
| 160 | 162 | common_ancestor_sha = "5117c9c8a4d3af19a9958677e45cda9269de1541" | |
@@ -576,7 +578,7 @@ def mixed_iterator(): | |||
| 576 | 578 | if sys.platform != "win32": | |
| 577 | 579 | for target in ('/etc/nonexisting', '/etc/passwd', '/etc'): | |
| 578 | 580 | basename = "my_real_symlink" | |
| 579 | - | ||
| 581 | + | ||
| 580 | 582 | link_file = os.path.join(rw_repo.working_tree_dir, basename) | |
| 581 | 583 | os.symlink(target, link_file) | |
| 582 | 584 | entries = index.reset(new_commit).add([link_file], fprogress=self._fprogress_add) | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -50,6 +50,7 @@ | |||
| 50 | 50 | from io import BytesIO | |
| 51 | 51 | ||
| 52 | 52 | from nose import SkipTest | |
| 53 | + from unittest import skipIf | ||
| 53 | 54 | ||
| 54 | 55 | ||
| 55 | 56 | def iter_flatten(lol): | |
@@ -106,7 +107,7 @@ def test_tree_from_revision(self): | |||
| 106 | 107 | ||
| 107 | 108 | # try from invalid revision that does not exist | |
| 108 | 109 | self.failUnlessRaises(BadName, self.rorepo.tree, 'hello world') | |
| 109 | - | ||
| 110 | + | ||
| 110 | 111 | def test_pickleable(self): | |
| 111 | 112 | pickle.loads(pickle.dumps(self.rorepo)) | |
| 112 | 113 | ||
@@ -312,6 +313,7 @@ def test_archive(self): | |||
| 312 | 313 | stream.close() | |
| 313 | 314 | os.remove(tmpfile) | |
| 314 | 315 | ||
| 316 | + @skipIf(sys.version_info < (2, 7), reason="not `assertRaisesRegexp` in py2.6") | ||
| 315 | 317 | @patch.object(Git, '_call_process') | |
| 316 | 318 | def test_should_display_blame_information(self, git): | |
| 317 | 319 | git.return_value = fixture('blame') | |
| Back | FazBrowse Home | New Git URL |
0 commit comments