mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
fixses and a skip added to test_mac_shadow.py test_mac_softwareupdate.py
This commit is contained in:
parent
23721593c8
commit
4afaa5c920
2 changed files with 5 additions and 4 deletions
|
@ -49,7 +49,7 @@ def test_get_account_created(shadow, accounts):
|
|||
"""
|
||||
# Correct Functionality
|
||||
text_date = shadow.get_account_created(accounts.created)
|
||||
assert text_date.data != "Invalid Timestamp"
|
||||
assert text_date != "Invalid Timestamp"
|
||||
obj_date = datetime.datetime.strptime(text_date, "%Y-%m-%d %H:%M:%S")
|
||||
assert isinstance(obj_date, datetime.date)
|
||||
|
||||
|
|
|
@ -22,7 +22,7 @@ def softwareupdate(modules):
|
|||
def _setup_teardown_vars(softwareupdate):
|
||||
IGNORED_LIST = softwareupdate.list_ignored()
|
||||
|
||||
SCHEDULE = softwareupdate.schedule()
|
||||
SCHEDULE = softwareupdate.schedule_enabled()
|
||||
|
||||
CATALOG = softwareupdate.get_catalog()
|
||||
|
||||
|
@ -35,7 +35,7 @@ def _setup_teardown_vars(softwareupdate):
|
|||
else:
|
||||
softwareupdate.reset_ignored()
|
||||
|
||||
softwareupdate.schedule(SCHEDULE)
|
||||
softwareupdate.schedule_enable(SCHEDULE)
|
||||
|
||||
if CATALOG == "Default":
|
||||
softwareupdate.reset_catalog()
|
||||
|
@ -53,6 +53,7 @@ def test_list_available(softwareupdate):
|
|||
assert isinstance(ret, dict)
|
||||
|
||||
|
||||
@pytest.mark.skip(reason="Ignore removed from latest OS X.")
|
||||
def test_ignore(softwareupdate):
|
||||
"""
|
||||
Test softwareupdate.ignore
|
||||
|
@ -95,7 +96,7 @@ def test_schedule(softwareupdate):
|
|||
|
||||
# Test disable in case it was already enabled
|
||||
ret = softwareupdate.schedule_enable(False)
|
||||
assert ret
|
||||
assert not ret
|
||||
|
||||
ret = softwareupdate.schedule_enabled()
|
||||
assert not ret
|
||||
|
|
Loading…
Add table
Reference in a new issue