From 00a57fd94780da1e6492ca5db82ab89bcfb06f9e Mon Sep 17 00:00:00 2001 From: Dan Helfman Date: Wed, 9 Feb 2022 21:20:28 -0800 Subject: [PATCH] Code formatting. --- borgmatic/borg/feature.py | 2 +- tests/unit/borg/test_create.py | 23 +++++++++++++---------- 2 files changed, 14 insertions(+), 11 deletions(-) diff --git a/borgmatic/borg/feature.py b/borgmatic/borg/feature.py index 6849e15..e8706e7 100644 --- a/borgmatic/borg/feature.py +++ b/borgmatic/borg/feature.py @@ -11,7 +11,7 @@ class Feature(Enum): FEATURE_TO_MINIMUM_BORG_VERSION = { Feature.COMPACT: parse_version('1.2.0a2'), # borg compact - Feature.ATIME: parse_version('1.2.0a7'), # borg create --atime + Feature.ATIME: parse_version('1.2.0a7'), # borg create --atime Feature.NOFLAGS: parse_version('1.2.0a8'), # borg create --noflags } diff --git a/tests/unit/borg/test_create.py b/tests/unit/borg/test_create.py index e389537..1150e73 100644 --- a/tests/unit/borg/test_create.py +++ b/tests/unit/borg/test_create.py @@ -763,12 +763,7 @@ def test_create_archive_with_read_special_calls_borg_with_read_special_parameter @pytest.mark.parametrize( 'option_name,option_value', - ( - ('ctime', True), - ('ctime', False), - ('birthtime', True), - ('birthtime', False), - ), + (('ctime', True), ('ctime', False), ('birthtime', True), ('birthtime', False),), ) def test_create_archive_with_basic_option_calls_borg_with_corresponding_parameter( option_name, option_value @@ -822,8 +817,12 @@ def test_create_archive_with_atime_option_calls_borg_with_corresponding_paramete flexmock(module).should_receive('_expand_directories').and_return(()) flexmock(module).should_receive('_expand_home_directories').and_return(()) flexmock(module).should_receive('_write_pattern_file').and_return(None) - flexmock(module.feature).should_receive('available').with_args(module.feature.Feature.ATIME, '1.2.3').and_return(feature_available) - flexmock(module.feature).should_receive('available').with_args(module.feature.Feature.NOFLAGS, '1.2.3').and_return(True) + flexmock(module.feature).should_receive('available').with_args( + module.feature.Feature.ATIME, '1.2.3' + ).and_return(feature_available) + flexmock(module.feature).should_receive('available').with_args( + module.feature.Feature.NOFLAGS, '1.2.3' + ).and_return(True) flexmock(module).should_receive('_make_pattern_flags').and_return(()) flexmock(module).should_receive('_make_exclude_flags').and_return(()) flexmock(module).should_receive('execute_command').with_args( @@ -865,8 +864,12 @@ def test_create_archive_with_bsd_flags_option_calls_borg_with_corresponding_para flexmock(module).should_receive('_expand_directories').and_return(()) flexmock(module).should_receive('_expand_home_directories').and_return(()) flexmock(module).should_receive('_write_pattern_file').and_return(None) - flexmock(module.feature).should_receive('available').with_args(module.feature.Feature.ATIME, '1.2.3').and_return(True) - flexmock(module.feature).should_receive('available').with_args(module.feature.Feature.NOFLAGS, '1.2.3').and_return(feature_available) + flexmock(module.feature).should_receive('available').with_args( + module.feature.Feature.ATIME, '1.2.3' + ).and_return(True) + flexmock(module.feature).should_receive('available').with_args( + module.feature.Feature.NOFLAGS, '1.2.3' + ).and_return(feature_available) flexmock(module).should_receive('_make_pattern_flags').and_return(()) flexmock(module).should_receive('_make_exclude_flags').and_return(()) flexmock(module).should_receive('execute_command').with_args(