Skip to content

Commit 8d44fb3

Browse files
authored
Fix and document small-fix commits (#694)
* Fix test. * Update datashuttle_class.py * Update datashuttle_class.py * Update datashuttle_class.py * Fix tests. * Fix tests...again...
1 parent c40372b commit 8d44fb3

3 files changed

Lines changed: 8 additions & 25 deletions

File tree

datashuttle/datashuttle_class.py

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1228,17 +1228,14 @@ def update_config_file(self, **kwargs) -> None:
12281228
# For backward compatibility
12291229
kwargs["connection_method"] = "local_only"
12301230

1231-
if (
1232-
self.cfg["connection_method"] == "local_only"
1233-
and kwargs["connection_method"] != "local_only"
1234-
):
1235-
# We need to ensure this rclone config is created if it was not created during
1236-
# initial set up because the project is local only. The rclone config for local filesystem
1237-
# is just a placeholder rclone config file anyway. This is not ideal but the alternative is to search
1238-
# for an existing config and create only if it does not exist, which requires calls to
1239-
# rclone because its config-saving path is not predictable, and this will be very
1240-
# slow and essentially pointless as recreating the config should simply overwrite it.
1241-
self._setup_rclone_central_local_filesystem_config()
1231+
if (
1232+
self.cfg["connection_method"] == "local_only"
1233+
and kwargs["connection_method"] != "local_only"
1234+
):
1235+
# We need to ensure this rclone config is created if it was not created during
1236+
# initial set up because the project is local only. It does not matter if the
1237+
# RClone config is ever overwritten, it's just a placeholder.
1238+
self._setup_rclone_central_local_filesystem_config()
12421239

12431240
new_cfg = copy.deepcopy(self.cfg)
12441241
new_cfg.update(**kwargs)

tests/tests_transfers/aws/test_tui_setup_aws.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -108,13 +108,6 @@ async def test_aws_connection_setup(
108108

109109
await self.scroll_to_click_pause(pilot, "#setup_aws_ok_button")
110110

111-
assert (
112-
pilot.app.screen.query_one(
113-
"#configs_go_to_project_screen_button"
114-
).visible
115-
is True
116-
)
117-
118111
@pytest.mark.asyncio
119112
async def test_aws_connection_setup_failed(self, central_path_and_project):
120113
"""Test AWS connection setup using an incorrect client secret and check

tests/tests_transfers/gdrive/test_tui_setup_gdrive.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -152,13 +152,6 @@ async def test_gdrive_connection_setup_without_browser(
152152
pilot, "#setup_gdrive_finish_button"
153153
)
154154

155-
assert (
156-
pilot.app.screen.query_one(
157-
"#configs_go_to_project_screen_button"
158-
).visible
159-
is True
160-
)
161-
162155
@pytest.mark.asyncio
163156
async def test_gdrive_connection_setup_incorrect_config_token(
164157
self, setup_project_paths

0 commit comments

Comments
 (0)