mirror of
https://github.com/pre-commit/pre-commit-hooks.git
synced 2026-03-31 18:46:53 +00:00
Fix test cases for unified_diff
This commit is contained in:
parent
31e740ed05
commit
7d878b55ff
1 changed files with 2 additions and 4 deletions
|
|
@ -111,9 +111,7 @@ def test_diffing_output(capsys):
|
|||
resource_path = get_resource_path('not_pretty_formatted_json.json')
|
||||
expected_retval = 1
|
||||
expected_out = '''\
|
||||
---
|
||||
+++
|
||||
@@ -1,6 +1,9 @@
|
||||
--- \n+++ \n@@ -1,6 +1,9 @@
|
||||
{
|
||||
- "foo":
|
||||
- "bar",
|
||||
|
|
@ -128,7 +126,7 @@ def test_diffing_output(capsys):
|
|||
+ "foo": "bar"
|
||||
}
|
||||
|
||||
''' # noqa: W291
|
||||
'''
|
||||
expected_err = 'File {} is not pretty-formatted\n'.format(resource_path)
|
||||
|
||||
actual_retval = main([resource_path])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue