Mercurial > hgsubversion
comparison tests/test_svn_pre_commit_hooks.py @ 1555:cff81f35b31e
cleanup: reference Abort from mercurial.error instead of mercurial.util
It's been there since hg 1.7 or so, which lets us avoid any need for
compat shims.
author | Augie Fackler <raf@durin42.com> |
---|---|
date | Sat, 24 Mar 2018 16:39:30 -0400 |
parents | d741f536f23a |
children |
comparison
equal
deleted
inserted
replaced
1554:258fb67fb956 | 1555:cff81f35b31e |
---|---|
1 import os | 1 import os |
2 import sys | 2 import sys |
3 import test_util | 3 import test_util |
4 import unittest | 4 import unittest |
5 | 5 |
6 from mercurial import commands | |
7 from mercurial import error | |
6 from mercurial import hg | 8 from mercurial import hg |
7 from mercurial import commands | |
8 from mercurial import util | |
9 | 9 |
10 | 10 |
11 class TestSvnPreCommitHooks(test_util.TestBase): | 11 class TestSvnPreCommitHooks(test_util.TestBase): |
12 def setUp(self): | 12 def setUp(self): |
13 super(TestSvnPreCommitHooks, self).setUp() | 13 super(TestSvnPreCommitHooks, self).setUp() |
26 | 26 |
27 def test_push_with_pre_commit_hooks(self): | 27 def test_push_with_pre_commit_hooks(self): |
28 changes = [('narf/a', 'narf/a', 'ohai',), | 28 changes = [('narf/a', 'narf/a', 'ohai',), |
29 ] | 29 ] |
30 self.commitchanges(changes) | 30 self.commitchanges(changes) |
31 self.assertRaises(util.Abort, self.pushrevisions) | 31 self.assertRaises(error.Abort, self.pushrevisions) |