From b03b85eca3eaf0286ff189c5d73693098cda7d8b Mon Sep 17 00:00:00 2001 From: Andrew Johnson Date: Thu, 16 Jul 2020 07:10:08 +0200 Subject: [PATCH] #27: Fix tests --- ...test_standardlib_jinja_render_directory.py | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/test/test_standardlib_jinja_render_directory.py b/test/test_standardlib_jinja_render_directory.py index 50ce2840..53c6c2f0 100644 --- a/test/test_standardlib_jinja_render_directory.py +++ b/test/test_standardlib_jinja_render_directory.py @@ -44,11 +44,14 @@ def test_iterates_over_subdirectories_including_depth_and_pattern(self): 'source': '../', 'target': '/tmp', 'delete_source_files': False, - 'pattern': '(.*)(src|test)/(.*).py$' + 'pattern': '(.*)(src|test)/(.*).py$', + '--exclude-pattern': '', + '--copy-not-matching-files': False }) # example files (please correct if changed in filesystem) - self.assertIn('"../test/test_standardlib_jinja_render_directory.py" -> "/tmp/test/test_standardlib_jinja_render_directory.py"', renderings) + self.assertIn('"../test/test_standardlib_jinja_render_directory.py" ' + + '-> "/tmp/test/test_standardlib_jinja_render_directory.py"', renderings) self.assertIn('"../src/__init__.py" -> "/tmp/src/__init__.py"', renderings) # directories should not be included @@ -89,7 +92,9 @@ def test_without_pattern(self): 'source': '../', 'target': '/tmp', 'delete_source_files': False, - 'pattern': '' + 'pattern': '', + '--exclude-pattern': '', + '--copy-not-matching-files': False }) # example files (please correct if changed in filesystem) @@ -102,7 +107,9 @@ def test_no_files_deleted_when_option_disabled(self): 'source': '../', 'target': '/tmp', 'delete_source_files': False, - 'pattern': '' + 'pattern': '', + '--exclude-pattern': '', + '--copy-not-matching-files': False }) self.assertEqual([], deletions) @@ -112,7 +119,9 @@ def test_files_are_called_to_be_deleted(self): 'source': '../', 'target': '/tmp', 'delete_source_files': True, - 'pattern': '(.*)test_standardlib_jinja_render_directory.py$' + 'pattern': '(.*)test_standardlib_jinja_render_directory.py$', + '--exclude-pattern': '', + '--copy-not-matching-files': False }) self.assertEqual(['../test/test_standardlib_jinja_render_directory.py'], deletions)