Skip to content
This repository has been archived by the owner on Mar 13, 2022. It is now read-only.

Commit

Permalink
add assertion
Browse files Browse the repository at this point in the history
  • Loading branch information
onecer committed Apr 14, 2021
1 parent 6d36aa2 commit 834c67d
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions config/kube_config_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -1291,6 +1291,14 @@ def test_load_kube_config_from_dict(self):
self.assertEqual(expected, actual)

def test_load_kube_config_from_dict_with_temp_file_path(self):
expected = FakeConfig(
host=TEST_SSL_HOST,
token=BEARER_TOKEN_FORMAT % TEST_DATA_BASE64,
cert_file=self._create_temp_file(TEST_CLIENT_CERT),
key_file=self._create_temp_file(TEST_CLIENT_KEY),
ssl_ca_cert=self._create_temp_file(TEST_CERTIFICATE_AUTH),
verify_ssl=True
)
actual = FakeConfig()
tmp_path = os.path.join(
os.path.dirname(
Expand All @@ -1302,6 +1310,7 @@ def test_load_kube_config_from_dict_with_temp_file_path(self):
client_configuration=actual,
temp_file_path=tmp_path)
self.assertFalse(True if not os.listdir(tmp_path) else False)
self.assertEqual(expected, actual)
_cleanup_temp_files

def test_load_kube_config_from_empty_file_like_object(self):
Expand Down

0 comments on commit 834c67d

Please sign in to comment.