Skip to content

Commit aa9c1bd

Browse files
committed
Fix typo
1 parent 4aadcb1 commit aa9c1bd

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

src/cloudai/_core/base_installer.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ def is_installed(self, items: Iterable[Installable]) -> InstallStatusResult:
150150
logging.debug(f"Installation check for {item!r}: {result.success}, {result.message}")
151151
install_results[item] = result
152152

153-
self._populate_sucessful_install(items, install_results)
153+
self._populate_successful_install(items, install_results)
154154

155155
nfailed = len([result for result in install_results.values() if not result.success])
156156
if nfailed:
@@ -204,7 +204,7 @@ def install(self, items: Iterable[Installable]) -> InstallStatusResult:
204204
logging.error(f"{done}/{total} Installation failed for {item!r}: {e}")
205205
install_results[item] = InstallStatusResult(False, str(e))
206206

207-
self._populate_sucessful_install(items, install_results)
207+
self._populate_successful_install(items, install_results)
208208

209209
all_success = all(result.success for result in install_results.values())
210210
if all_success:
@@ -213,7 +213,7 @@ def install(self, items: Iterable[Installable]) -> InstallStatusResult:
213213
nfailed = len([result for result in install_results.values() if not result.success])
214214
return InstallStatusResult(False, f"{nfailed} item(s) failed to install.", install_results)
215215

216-
def _populate_sucessful_install(
216+
def _populate_successful_install(
217217
self, items: Iterable[Installable], install_results: dict[Installable, InstallStatusResult]
218218
):
219219
for item in self.all_items(items, with_duplicates=True):

tests/test_base_installer.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ def test_system_installables_are_used(slurm_system: SlurmSystem):
193193
installer.uninstall_one = Mock(return_value=InstallStatusResult(True))
194194
installer.is_installed_one = Mock(return_value=InstallStatusResult(True))
195195
installer.mark_as_installed_one = Mock(return_value=InstallStatusResult(True))
196-
installer._populate_sucessful_install = Mock()
196+
installer._populate_successful_install = Mock()
197197

198198
installer.install([])
199199
assert installer.install_one.call_count == len(slurm_system.system_installables())
@@ -245,18 +245,18 @@ def test_order_of_items_does_not_matter(self, installer: SlurmInstaller):
245245
assert f1._installed_path is None, "First file is installed before testing"
246246
assert f2._installed_path is None, "Second file is installed before testing"
247247

248-
installer._populate_sucessful_install([f1, f2], {})
248+
installer._populate_successful_install([f1, f2], {})
249249
assert f1._installed_path is None, "First file was marked as installed, but should not be"
250250
assert f2._installed_path is None, "Second file was marked as installed, but should not be"
251251

252-
installer._populate_sucessful_install([f1, f2], {f1: InstallStatusResult(success=True)})
252+
installer._populate_successful_install([f1, f2], {f1: InstallStatusResult(success=True)})
253253
assert f1._installed_path is not None, (
254254
"First ('self', present in the statuses) file was not marked as installed"
255255
)
256256
assert f2._installed_path is not None, "Second file was not marked as installed"
257257

258258
f1._installed_path, f2._installed_path = None, None
259-
installer._populate_sucessful_install([f2, f1], {f1: InstallStatusResult(success=True)})
259+
installer._populate_successful_install([f2, f1], {f1: InstallStatusResult(success=True)})
260260
assert f1._installed_path is not None, (
261261
"First ('self', present in the statuses) file was not marked as installed"
262262
)

0 commit comments

Comments
 (0)