diff options
| author | Vu Cong Tuan <tuanvc@vn.fujitsu.com> | 2017-06-03 12:28:52 +0700 |
|---|---|---|
| committer | Vu Cong Tuan <tuanvc@vn.fujitsu.com> | 2017-06-03 13:40:12 +0700 |
| commit | db61fad6b237934f410e9ccbd1c24cf13e6c53fb (patch) | |
| tree | 317bf5e47dc66a4af35711f8e1b4de81111c8d44 /taskflow/tests/unit/patterns | |
| parent | cf0ee0b0c7a9fcbd9c3920613f679506c2fa957a (diff) | |
| download | taskflow-db61fad6b237934f410e9ccbd1c24cf13e6c53fb.tar.gz | |
Replace assertRaisesRegexp with assertRaisesRegex
assertRaisesRegexp was renamed to assertRaisesRegex in Py3.2
For more details, please check:
https://docs.python.org/3/library/
unittest.html#unittest.TestCase.assertRaisesRegex
Change-Id: I89cce19e80b04074aab9f49a76c7652acace78b3
Closes-Bug: #1436957
Diffstat (limited to 'taskflow/tests/unit/patterns')
| -rw-r--r-- | taskflow/tests/unit/patterns/test_graph_flow.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/taskflow/tests/unit/patterns/test_graph_flow.py b/taskflow/tests/unit/patterns/test_graph_flow.py index 429f68f..8aab109 100644 --- a/taskflow/tests/unit/patterns/test_graph_flow.py +++ b/taskflow/tests/unit/patterns/test_graph_flow.py @@ -200,15 +200,15 @@ class GraphFlowTest(test.TestCase): task1 = _task('task1') task2 = _task('task2') f = gf.Flow('test').add(task2) - self.assertRaisesRegexp(ValueError, 'Node .* not found to link from', - f.link, task1, task2) + self.assertRaisesRegex(ValueError, 'Node .* not found to link from', + f.link, task1, task2) def test_graph_flow_link_to_unknown_node(self): task1 = _task('task1') task2 = _task('task2') f = gf.Flow('test').add(task1) - self.assertRaisesRegexp(ValueError, 'Node .* not found to link to', - f.link, task1, task2) + self.assertRaisesRegex(ValueError, 'Node .* not found to link to', + f.link, task1, task2) def test_graph_flow_link_raises_on_cycle(self): task1 = _task('task1', provides=['a']) @@ -288,8 +288,8 @@ class TargetedGraphFlowTest(test.TestCase): task1 = _task('task1', provides=['a'], requires=[]) task2 = _task('task2', provides=['b'], requires=['a']) f.add(task1) - self.assertRaisesRegexp(ValueError, '^Node .* not found', - f.set_target, task2) + self.assertRaisesRegex(ValueError, '^Node .* not found', + f.set_target, task2) def test_targeted_flow_one_node(self): f = gf.TargetedFlow("test") |
