Skip to content

Commit

Permalink
fixed small test case issues
Browse files Browse the repository at this point in the history
  • Loading branch information
david-mclain committed Nov 27, 2024
1 parent 6cd3f9c commit afa87d7
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions landscape/client/tests/test_deployment.py
Original file line number Diff line number Diff line change
Expand Up @@ -609,22 +609,19 @@ class ArgConversionTest(LandscapeTest):

def test_true_values(self):
TRUTHY_VALUES = {"true", "yes", "y", "1", "on", "TRUE", "Yes"}
val = True
for t in TRUTHY_VALUES:
val = convert_arg_to_bool(t)
self.assertTrue(val)

def test_false_values(self):
FALSY_VALUES = {"false", "no", "n", "0", "off", "FALSE", "No"}
val = False
for f in FALSY_VALUES:
val = convert_arg_to_bool(f)
self.assertFalse(val)

@mock.patch("landscape.client.deployment.info")
def test_invalid_values(self, logging):
INVALID_VALUES = {"invalid", "truthy", "2", "exit"}
val = False
for i in INVALID_VALUES:
val = convert_arg_to_bool(i)
logging.assert_called_with(
Expand Down

0 comments on commit afa87d7

Please sign in to comment.