mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-25 06:10:22 -07:00
Deprecate tests used as filters (#32361)
* Warn on tests used as filters * Update docs, add aliases for tests that fit more gramatically with test syntax * Fix rst formatting * Add successful filter, alias of success * Remove renamed_deprecation, it was overkill * Make directory alias for is_dir * Update tests to use proper jinja test syntax * Update additional documentation, living outside of YAML files, to reflect proper jinja test syntax * Add conversion script, porting guide updates, and changelog updates * Update newly added uses of tests as filters * No underscore variable * Convert recent tests as filter changes to win_stat * Fix some changes related to rebasing a few integration tests * Make tests_as_filters_warning explicitly accept the name of the test, instead of inferring the name * Add test for tests_as_filters_warning * Update tests as filters in newly added/modified tests * Address recent changes to several integration tests * Address recent changes in cs_vpc
This commit is contained in:
parent
fd4a6cf7ad
commit
4fe08441be
349 changed files with 4086 additions and 3844 deletions
|
@ -19,7 +19,7 @@
|
|||
- name: assert results of create task (check mode)
|
||||
assert:
|
||||
that:
|
||||
- create_task_check|changed
|
||||
- create_task_check is changed
|
||||
- create_task_result_check.task_exists == False
|
||||
|
||||
- name: create task
|
||||
|
@ -41,7 +41,7 @@
|
|||
- name: assert results of create task
|
||||
assert:
|
||||
that:
|
||||
- create_task|changed
|
||||
- create_task is changed
|
||||
- create_task_result.task_exists == True
|
||||
- create_task_result.actions|count == 1
|
||||
- create_task_result.actions[0].path == "cmd.exe"
|
||||
|
@ -63,7 +63,7 @@
|
|||
- name: assert results of create task (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not create_task_again|changed
|
||||
- create_task_again is not changed
|
||||
|
||||
- name: change task (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -86,7 +86,7 @@
|
|||
- name: assert results of change task (check mode)
|
||||
assert:
|
||||
that:
|
||||
- change_task_check|changed
|
||||
- change_task_check is changed
|
||||
- change_task_result_check.actions|count == 1
|
||||
- change_task_result_check.registration_info.author == None
|
||||
- change_task_result_check.registration_info.description == "Original Description"
|
||||
|
@ -114,7 +114,7 @@
|
|||
- name: assert results of change task
|
||||
assert:
|
||||
that:
|
||||
- change_task|changed
|
||||
- change_task is changed
|
||||
- change_task_result.actions|count == 1
|
||||
- change_task_result.registration_info.author == "Cow Inc."
|
||||
- change_task_result.registration_info.description == "Test for Ansible"
|
||||
|
@ -136,7 +136,7 @@
|
|||
- name: assert results of change task (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not change_task_again|changed
|
||||
- change_task_again is not changed
|
||||
|
||||
- name: add task action (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -160,7 +160,7 @@
|
|||
- name: assert results of add task action (check mode)
|
||||
assert:
|
||||
that:
|
||||
- add_task_action_check|changed
|
||||
- add_task_action_check is changed
|
||||
- add_task_action_result_check.actions|count == 1
|
||||
- add_task_action_result_check.actions[0].path == "cmd.exe"
|
||||
- add_task_action_result_check.actions[0].arguments == "/c echo hi"
|
||||
|
@ -187,7 +187,7 @@
|
|||
- name: assert results of add task action
|
||||
assert:
|
||||
that:
|
||||
- add_task_action|changed
|
||||
- add_task_action is changed
|
||||
- add_task_action_result.actions|count == 2
|
||||
- add_task_action_result.actions[0].path == "cmd.exe"
|
||||
- add_task_action_result.actions[0].arguments == "/c echo hi"
|
||||
|
@ -211,7 +211,7 @@
|
|||
- name: assert results of add task action (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not add_task_action_again|changed
|
||||
- add_task_action_again is not changed
|
||||
|
||||
- name: remove task action (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -233,7 +233,7 @@
|
|||
- name: assert results of remove task action (check mode)
|
||||
assert:
|
||||
that:
|
||||
- remove_task_action_check|changed
|
||||
- remove_task_action_check is changed
|
||||
- remove_task_action_result_check.actions|count == 2
|
||||
- remove_task_action_result_check.actions[0].path == "cmd.exe"
|
||||
- remove_task_action_result_check.actions[0].arguments == "/c echo hi"
|
||||
|
@ -261,7 +261,7 @@
|
|||
- name: assert results of remove task action
|
||||
assert:
|
||||
that:
|
||||
- remove_task_action|changed
|
||||
- remove_task_action is changed
|
||||
- remove_task_action_result.actions|count == 1
|
||||
- remove_task_action_result.actions[0].path == "powershell.exe"
|
||||
- remove_task_action_result.actions[0].arguments == "-File C:\\ansible\\script.ps1"
|
||||
|
@ -280,7 +280,7 @@
|
|||
- name: assert results of remove task action (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not remove_task_action_again|changed
|
||||
- remove_task_action_again is not changed
|
||||
|
||||
- name: remove task (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -298,7 +298,7 @@
|
|||
- name: assert results of remove task (check mode)
|
||||
assert:
|
||||
that:
|
||||
- remove_task_check|changed
|
||||
- remove_task_check is changed
|
||||
- remove_task_result_check.task_exists == True
|
||||
|
||||
- name: remove task
|
||||
|
@ -316,7 +316,7 @@
|
|||
- name: assert results of remove task
|
||||
assert:
|
||||
that:
|
||||
- remove_task|changed
|
||||
- remove_task is changed
|
||||
- remove_task_result.task_exists == False
|
||||
|
||||
- name: remove task (idempotent)
|
||||
|
@ -328,7 +328,7 @@
|
|||
- name: assert results of remove task (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not remove_task_again|changed
|
||||
- remove_task_again is not changed
|
||||
|
||||
- name: create sole task in folder (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -348,7 +348,7 @@
|
|||
- name: assert results of create sole task in folder (check mode)
|
||||
assert:
|
||||
that:
|
||||
- create_sole_task_check|changed
|
||||
- create_sole_task_check is changed
|
||||
- create_sole_task_result_check.folder_exists == False
|
||||
- create_sole_task_result_check.task_exists == False
|
||||
|
||||
|
@ -369,7 +369,7 @@
|
|||
- name: assert results of create sole task in folder
|
||||
assert:
|
||||
that:
|
||||
- create_sole_task|changed
|
||||
- create_sole_task is changed
|
||||
- create_sole_task_result.folder_exists == True
|
||||
- create_sole_task_result.task_exists == True
|
||||
|
||||
|
@ -384,7 +384,7 @@
|
|||
- name: assert results of create sole task in folder (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not create_sole_task_again|changed
|
||||
- create_sole_task_again is not changed
|
||||
|
||||
- name: remove sole task in folder (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -403,7 +403,7 @@
|
|||
- name: assert results of remove sole task in folder (check mode)
|
||||
assert:
|
||||
that:
|
||||
- remove_sole_task_check|changed
|
||||
- remove_sole_task_check is changed
|
||||
- remove_sole_task_result_check.folder_exists == True
|
||||
- remove_sole_task_result_check.task_exists == True
|
||||
|
||||
|
@ -423,7 +423,7 @@
|
|||
- name: assert results of remove sole task in folder
|
||||
assert:
|
||||
that:
|
||||
- remove_sole_task|changed
|
||||
- remove_sole_task is changed
|
||||
- remove_sole_task_result.folder_exists == False
|
||||
- remove_sole_task_result.task_exists == False
|
||||
|
||||
|
@ -437,4 +437,4 @@
|
|||
- name: assert results of remove sole task in folder (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not remove_sole_task_again|changed
|
||||
- remove_sole_task_again is not changed
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
- name: assert results of task with password principal (check mode)
|
||||
assert:
|
||||
that:
|
||||
- task_with_password_check|changed
|
||||
- task_with_password_check is changed
|
||||
- task_with_password_result_check.task_exists == False
|
||||
|
||||
- name: task with password principal
|
||||
|
@ -53,7 +53,7 @@
|
|||
- name: assert results of task with password principal
|
||||
assert:
|
||||
that:
|
||||
- task_with_password|changed
|
||||
- task_with_password is changed
|
||||
- task_with_password_result.task_exists == True
|
||||
- task_with_password_result.principal.group_id == None
|
||||
- task_with_password_result.principal.logon_type == "TASK_LOGON_PASSWORD"
|
||||
|
@ -75,7 +75,7 @@
|
|||
- name: assert results of task with password principal (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not task_with_password_again|changed
|
||||
- task_with_password_again is not changed
|
||||
|
||||
- name: task with password principal force pass change
|
||||
win_scheduled_task:
|
||||
|
@ -92,7 +92,7 @@
|
|||
- name: assert results of task with password principal force pass change
|
||||
assert:
|
||||
that:
|
||||
- task_with_password_force_update|changed
|
||||
- task_with_password_force_update is changed
|
||||
|
||||
- name: task with s4u principal (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -116,7 +116,7 @@
|
|||
- name: assert results of task with s4u principal (check mode)
|
||||
assert:
|
||||
that:
|
||||
- task_with_s4u_check|changed
|
||||
- task_with_s4u_check is changed
|
||||
- task_with_s4u_result_check.task_exists == True
|
||||
- task_with_s4u_result_check.principal.group_id == None
|
||||
- task_with_s4u_result_check.principal.logon_type == "TASK_LOGON_PASSWORD"
|
||||
|
@ -144,7 +144,7 @@
|
|||
- name: assert results of task with s4u principal
|
||||
assert:
|
||||
that:
|
||||
- task_with_s4u|changed
|
||||
- task_with_s4u is changed
|
||||
- task_with_s4u_result.task_exists == True
|
||||
- task_with_s4u_result.principal.group_id == None
|
||||
- task_with_s4u_result.principal.logon_type == "TASK_LOGON_S4U"
|
||||
|
@ -166,7 +166,7 @@
|
|||
- name: assert results of task with s4u principal (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not task_with_s4u_again|changed
|
||||
- task_with_s4u_again is not changed
|
||||
|
||||
- name: task with interactive principal (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -188,7 +188,7 @@
|
|||
- name: assert results of task with interactive principal (check mode)
|
||||
assert:
|
||||
that:
|
||||
- task_with_interactive_check|changed
|
||||
- task_with_interactive_check is changed
|
||||
- task_with_interactive_result_check.task_exists == True
|
||||
- task_with_interactive_result_check.principal.group_id == None
|
||||
- task_with_interactive_result_check.principal.logon_type == "TASK_LOGON_S4U"
|
||||
|
@ -214,7 +214,7 @@
|
|||
- name: assert results of task with interactive principal
|
||||
assert:
|
||||
that:
|
||||
- task_with_interactive|changed
|
||||
- task_with_interactive is changed
|
||||
- task_with_interactive_result.task_exists == True
|
||||
- task_with_interactive_result.principal.group_id == None
|
||||
- task_with_interactive_result.principal.logon_type == "TASK_LOGON_INTERACTIVE_TOKEN"
|
||||
|
@ -234,7 +234,7 @@
|
|||
- name: assert results of task with interactive principal (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not task_with_interactive_again|changed
|
||||
- task_with_interactive_again is not changed
|
||||
|
||||
- name: task with group principal (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -256,7 +256,7 @@
|
|||
- name: assert results of task with group principal (check mode)
|
||||
assert:
|
||||
that:
|
||||
- task_with_group_check|changed
|
||||
- task_with_group_check is changed
|
||||
- task_with_group_result_check.task_exists == True
|
||||
- task_with_group_result_check.principal.group_id == None
|
||||
- task_with_group_result_check.principal.logon_type == "TASK_LOGON_INTERACTIVE_TOKEN"
|
||||
|
@ -282,7 +282,7 @@
|
|||
- name: assert results of task with group principal
|
||||
assert:
|
||||
that:
|
||||
- task_with_group|changed
|
||||
- task_with_group is changed
|
||||
- task_with_group_result.task_exists == True
|
||||
- task_with_group_result.principal.group_id == "BUILTIN\\Administrators"
|
||||
- task_with_group_result.principal.logon_type == "TASK_LOGON_GROUP"
|
||||
|
@ -302,7 +302,7 @@
|
|||
- name: assert results of task with group principal (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not task_with_group_again|changed
|
||||
- task_with_group_again is not changed
|
||||
|
||||
- name: task with service account principal (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -324,7 +324,7 @@
|
|||
- name: assert results of task with service account principal (check mode)
|
||||
assert:
|
||||
that:
|
||||
- task_with_service_check|changed
|
||||
- task_with_service_check is changed
|
||||
- task_with_service_result_check.task_exists == True
|
||||
- task_with_service_result_check.principal.group_id == "BUILTIN\\Administrators"
|
||||
- task_with_service_result_check.principal.logon_type == "TASK_LOGON_GROUP"
|
||||
|
@ -350,7 +350,7 @@
|
|||
- name: assert results of task with service account principal
|
||||
assert:
|
||||
that:
|
||||
- task_with_service|changed
|
||||
- task_with_service is changed
|
||||
- task_with_service_result.task_exists == True
|
||||
- task_with_service_result.principal.group_id == None
|
||||
- task_with_service_result.principal.logon_type == "TASK_LOGON_SERVICE_ACCOUNT"
|
||||
|
@ -370,7 +370,7 @@
|
|||
- name: assert results of task with service account principal (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not task_with_service_again|changed
|
||||
- task_with_service_again is not changed
|
||||
|
||||
- name: task with highest privilege (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -393,7 +393,7 @@
|
|||
- name: assert results of task with highest privilege (check mode)
|
||||
assert:
|
||||
that:
|
||||
- task_with_highest_privilege_check|changed
|
||||
- task_with_highest_privilege_check is changed
|
||||
- task_with_highest_privilege_result_check.principal.run_level == "TASK_RUNLEVEL_LUA"
|
||||
|
||||
- name: task with highest privilege
|
||||
|
@ -416,7 +416,7 @@
|
|||
- name: assert results of task with highest privilege
|
||||
assert:
|
||||
that:
|
||||
- task_with_highest_privilege|changed
|
||||
- task_with_highest_privilege is changed
|
||||
- task_with_highest_privilege_result.principal.run_level == "TASK_RUNLEVEL_HIGHEST"
|
||||
|
||||
- name: task with highest privilege (idempotent)
|
||||
|
@ -433,4 +433,4 @@
|
|||
- name: assert results of task with highest privilege (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not task_with_highest_privilege_again|changed
|
||||
- task_with_highest_privilege_again is not changed
|
||||
|
|
|
@ -150,7 +150,7 @@
|
|||
- name: Test add_scheduled_task_new_path_1
|
||||
assert:
|
||||
that:
|
||||
- add_scheduled_task_new_path_1|changed
|
||||
- add_scheduled_task_new_path_1 is changed
|
||||
|
||||
|
||||
- name: Add scheduled task new path 2
|
||||
|
@ -162,13 +162,13 @@
|
|||
- name: Test add_scheduled_task_new_path_2 (normal mode)
|
||||
assert:
|
||||
that:
|
||||
- add_scheduled_task_new_path_2|changed
|
||||
- add_scheduled_task_new_path_2 is changed
|
||||
when: not in_check_mode
|
||||
|
||||
- name: Test add_scheduled_task_new_path_2 (check-mode)
|
||||
assert:
|
||||
that:
|
||||
- add_scheduled_task_new_path_2|changed
|
||||
- add_scheduled_task_new_path_2 is changed
|
||||
when: in_check_mode
|
||||
|
||||
|
||||
|
@ -179,13 +179,13 @@
|
|||
- name: Test remove_scheduled_task_new_path_2 (normal mode)
|
||||
assert:
|
||||
that:
|
||||
- remove_scheduled_task_new_path_2|changed
|
||||
- remove_scheduled_task_new_path_2 is changed
|
||||
when: not in_check_mode
|
||||
|
||||
- name: Test remove_scheduled_task_new_path_2 (check-mode)
|
||||
assert:
|
||||
that:
|
||||
- not remove_scheduled_task_new_path_2|changed
|
||||
- remove_scheduled_task_new_path_2 is not changed
|
||||
when: in_check_mode
|
||||
|
||||
|
||||
|
@ -196,13 +196,13 @@
|
|||
- name: Test remove_scheduled_task_new_path_1 (normal mode)
|
||||
assert:
|
||||
that:
|
||||
- remove_scheduled_task_new_path_1|changed
|
||||
- remove_scheduled_task_new_path_1 is changed
|
||||
when: not in_check_mode
|
||||
|
||||
- name: Test remove_scheduled_task_new_path_1 (check-mode)
|
||||
assert:
|
||||
that:
|
||||
- not remove_scheduled_task_new_path_1|changed
|
||||
- remove_scheduled_task_new_path_1 is not changed
|
||||
when: in_check_mode
|
||||
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
- name: assert results of create boot trigger (check mode)
|
||||
assert:
|
||||
that:
|
||||
- trigger_boot_check|changed
|
||||
- trigger_boot_check is changed
|
||||
- trigger_boot_result_check.task_exists == False
|
||||
|
||||
- name: create boot trigger
|
||||
|
@ -41,7 +41,7 @@
|
|||
- name: assert results of create boot trigger
|
||||
assert:
|
||||
that:
|
||||
- trigger_boot|changed
|
||||
- trigger_boot is changed
|
||||
- trigger_boot_result.task_exists == True
|
||||
- trigger_boot_result.triggers|count == 1
|
||||
- trigger_boot_result.triggers[0].type == "TASK_TRIGGER_BOOT"
|
||||
|
@ -62,7 +62,7 @@
|
|||
- name: assert results of create boot trigger (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not trigger_boot_again|changed
|
||||
- trigger_boot_again is not changed
|
||||
|
||||
- name: create daily trigger (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -85,7 +85,7 @@
|
|||
- name: assert results of create daily trigger (check mode)
|
||||
assert:
|
||||
that:
|
||||
- trigger_daily_check|changed
|
||||
- trigger_daily_check is changed
|
||||
- trigger_daily_result_check.task_exists == True
|
||||
- trigger_daily_result_check.triggers|count == 1
|
||||
- trigger_daily_result_check.triggers[0].type == "TASK_TRIGGER_BOOT"
|
||||
|
@ -113,7 +113,7 @@
|
|||
- name: assert results of create daily trigger
|
||||
assert:
|
||||
that:
|
||||
- trigger_daily|changed
|
||||
- trigger_daily is changed
|
||||
- trigger_daily_result.task_exists == True
|
||||
- trigger_daily_result.triggers|count == 1
|
||||
- trigger_daily_result.triggers[0].type == "TASK_TRIGGER_DAILY"
|
||||
|
@ -135,7 +135,7 @@
|
|||
- name: assert results of create daily trigger (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not trigger_daily_again|changed
|
||||
- trigger_daily_again is not changed
|
||||
|
||||
- name: create logon trigger (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -157,7 +157,7 @@
|
|||
- name: assert results of create logon trigger
|
||||
assert:
|
||||
that:
|
||||
- trigger_logon_check|changed
|
||||
- trigger_logon_check is changed
|
||||
- trigger_logon_result_check.task_exists == True
|
||||
- trigger_logon_result_check.triggers|count == 1
|
||||
- trigger_logon_result_check.triggers[0].type == "TASK_TRIGGER_DAILY"
|
||||
|
@ -184,7 +184,7 @@
|
|||
- name: assert results of create logon trigger
|
||||
assert:
|
||||
that:
|
||||
- trigger_logon|changed
|
||||
- trigger_logon is changed
|
||||
- trigger_logon_result.task_exists == True
|
||||
- trigger_logon_result.triggers|count == 1
|
||||
- trigger_logon_result.triggers[0].type == "TASK_TRIGGER_LOGON"
|
||||
|
@ -205,7 +205,7 @@
|
|||
- name: assert results of create logon trigger (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not trigger_logon_again|changed
|
||||
- trigger_logon_again is not changed
|
||||
|
||||
- name: create monthly dow trigger (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -230,7 +230,7 @@
|
|||
- name: assert results of create monthly dow trigger (check mode)
|
||||
assert:
|
||||
that:
|
||||
- trigger_monthlydow_check|changed
|
||||
- trigger_monthlydow_check is changed
|
||||
- trigger_monthlydow_result_check.task_exists == True
|
||||
- trigger_monthlydow_result_check.triggers|count == 1
|
||||
- trigger_monthlydow_result_check.triggers[0].type == "TASK_TRIGGER_LOGON"
|
||||
|
@ -260,7 +260,7 @@
|
|||
- name: assert results of create monthly dow trigger
|
||||
assert:
|
||||
that:
|
||||
- trigger_monthlydow|changed
|
||||
- trigger_monthlydow is changed
|
||||
- trigger_monthlydow_result.task_exists == True
|
||||
- trigger_monthlydow_result.triggers|count == 1
|
||||
- trigger_monthlydow_result.triggers[0].type == "TASK_TRIGGER_MONTHLYDOW"
|
||||
|
@ -286,7 +286,7 @@
|
|||
- name: assert results of create monthly dow trigger (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not trigger_monthlydow_again|changed
|
||||
- trigger_monthlydow_again is not changed
|
||||
|
||||
- name: create task with multiple triggers (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -318,7 +318,7 @@
|
|||
- name: assert results of create task with multiple triggers (check mode)
|
||||
assert:
|
||||
that:
|
||||
- create_multiple_triggers_check|changed
|
||||
- create_multiple_triggers_check is changed
|
||||
- create_multiple_triggers_result_check.task_exists == True
|
||||
- create_multiple_triggers_result_check.triggers|count == 1
|
||||
- create_multiple_triggers_result_check.triggers[0].type == "TASK_TRIGGER_MONTHLYDOW"
|
||||
|
@ -357,7 +357,7 @@
|
|||
- name: assert results of create task with multiple triggers
|
||||
assert:
|
||||
that:
|
||||
- create_multiple_triggers|changed
|
||||
- create_multiple_triggers is changed
|
||||
- create_multiple_triggers_result.task_exists == True
|
||||
- create_multiple_triggers_result.triggers|count == 2
|
||||
- create_multiple_triggers_result.triggers[0].type == "TASK_TRIGGER_MONTHLY"
|
||||
|
@ -396,7 +396,7 @@
|
|||
- name: assert results of create task with multiple triggers (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not create_multiple_triggers_again|changed
|
||||
- create_multiple_triggers_again is not changed
|
||||
|
||||
- name: change task with multiple triggers (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -422,7 +422,7 @@
|
|||
- name: assert results of change task with multiple triggers (check mode)
|
||||
assert:
|
||||
that:
|
||||
- change_multiple_triggers_check|changed
|
||||
- change_multiple_triggers_check is changed
|
||||
- change_multiple_triggers_result_check.task_exists == True
|
||||
- change_multiple_triggers_result_check.triggers|count == 2
|
||||
- change_multiple_triggers_result_check.triggers[0].type == "TASK_TRIGGER_MONTHLY"
|
||||
|
@ -461,7 +461,7 @@
|
|||
- name: assert results of change task with multiple triggers
|
||||
assert:
|
||||
that:
|
||||
- change_multiple_triggers|changed
|
||||
- change_multiple_triggers is changed
|
||||
- change_multiple_triggers_result.task_exists == True
|
||||
- change_multiple_triggers_result.triggers|count == 2
|
||||
- change_multiple_triggers_result.triggers[0].type == "TASK_TRIGGER_WEEKLY"
|
||||
|
@ -491,7 +491,7 @@
|
|||
- name: assert results of change task with multiple triggers (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not change_multiple_triggers_again|changed
|
||||
- change_multiple_triggers_again is not changed
|
||||
|
||||
- name: remove trigger from multiple triggers (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -514,7 +514,7 @@
|
|||
- name: assert results of remove trigger from multiple triggers (check mode)
|
||||
assert:
|
||||
that:
|
||||
- remove_single_trigger_check|changed
|
||||
- remove_single_trigger_check is changed
|
||||
- remove_single_trigger_result_check.task_exists == True
|
||||
- remove_single_trigger_result_check.triggers|count == 2
|
||||
- remove_single_trigger_result_check.triggers[0].type == "TASK_TRIGGER_WEEKLY"
|
||||
|
@ -547,7 +547,7 @@
|
|||
- name: assert results of remove trigger from multiple triggers
|
||||
assert:
|
||||
that:
|
||||
- remove_single_trigger|changed
|
||||
- remove_single_trigger is changed
|
||||
- remove_single_trigger_result.task_exists == True
|
||||
- remove_single_trigger_result.triggers|count == 1
|
||||
- remove_single_trigger_result.triggers[0].type == "TASK_TRIGGER_REGISTRATION"
|
||||
|
@ -569,7 +569,7 @@
|
|||
- name: assert results of remove trigger from multiple triggers (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not remove_single_trigger_again|changed
|
||||
- remove_single_trigger_again is not changed
|
||||
|
||||
- name: remove all triggers (check mode)
|
||||
win_scheduled_task:
|
||||
|
@ -590,7 +590,7 @@
|
|||
- name: assert results of remove all triggers (check mode)
|
||||
assert:
|
||||
that:
|
||||
- remove_triggers_check|changed
|
||||
- remove_triggers_check is changed
|
||||
- remove_triggers_result_check.task_exists == True
|
||||
- remove_triggers_result_check.triggers|count == 1
|
||||
- remove_triggers_result_check.triggers[0].type == "TASK_TRIGGER_REGISTRATION"
|
||||
|
@ -616,7 +616,7 @@
|
|||
- name: assert results of remove all triggers
|
||||
assert:
|
||||
that:
|
||||
- remove_triggers|changed
|
||||
- remove_triggers is changed
|
||||
- remove_triggers_result.task_exists == True
|
||||
- remove_triggers_result.triggers|count == 0
|
||||
|
||||
|
@ -632,4 +632,4 @@
|
|||
- name: assert results of remove all triggers (idempotent)
|
||||
assert:
|
||||
that:
|
||||
- not remove_triggers_again|changed
|
||||
- remove_triggers_again is not changed
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue