Skip to content

Commit

Permalink
fixed terminate return values test
Browse files Browse the repository at this point in the history
  • Loading branch information
XaverStiensmeier committed Nov 30, 2024
1 parent 8549202 commit 16892d4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/unit_tests/test_terminate_cluster.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,16 @@ def test_terminate(self, mock_output, mock_local):
provider.delete_server.return_value = True
provider.delete_keypair.return_value = True
provider.delete_volume.return_value = True
provider.list_volumes.return_value = [
{"name": f"{create.MASTER_IDENTIFIER(cluster_id=str(cluster_id))}-tmp-0", "id": 42}]
provider.list_volumes([{"name": "bibigrid-master-i950vaoqzfbwpnq-tmp-0"}])
provider.delete_security_group.return_value = True
provider.delete_application_credentials.return_value = True
terminate.terminate(str(cluster_id), [provider], startup.LOG, False, True)
provider.delete_server.assert_called_with(21)
provider.delete_keypair.assert_called_with(create.KEY_NAME.format(cluster_id=cluster_id))
mock_output.assert_called_with([provider.delete_server.return_value], [provider.delete_keypair.return_value],
[provider.delete_security_group.return_value],
[provider.delete_security_group.return_value], [[True]],
provider.delete_application_credentials.return_value, str(cluster_id),
startup.LOG)

Expand Down

0 comments on commit 16892d4

Please sign in to comment.