summaryrefslogtreecommitdiffstats
path: root/awx_collection/test
diff options
context:
space:
mode:
authorAlan Rominger <arominge@redhat.com>2024-11-12 18:37:38 +0100
committerGitHub <noreply@github.com>2024-11-12 18:37:38 +0100
commitc9f880414c58bbd6f6ea072c1d441ebcd91e7c91 (patch)
tree8807d341f9e2ce27c4fe4cb0fabd7a2e498e64c1 /awx_collection/test
parentFix for 'relation "social_auth_usersocialauth" does not exist' error (#15626) (diff)
downloadawx-c9f880414c58bbd6f6ea072c1d441ebcd91e7c91.tar.xz
awx-c9f880414c58bbd6f6ea072c1d441ebcd91e7c91.zip
Make lookup plugins return lists to fix failures (#15625)
* Make lookup plugins return lists to fix failures * Update unit tests * Use lookup for test failures, update docs * Grammar fix from review Co-authored-by: Sviatoslav Sydorenko (Святослав Сидоренко) <wk.cvs.github@sydorenko.org.ua> --------- Co-authored-by: Sviatoslav Sydorenko (Святослав Сидоренко) <wk.cvs.github@sydorenko.org.ua>
Diffstat (limited to 'awx_collection/test')
-rw-r--r--awx_collection/test/awx/test_schedule.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/awx_collection/test/awx/test_schedule.py b/awx_collection/test/awx/test_schedule.py
index 13f14c8145..ec01273708 100644
--- a/awx_collection/test/awx/test_schedule.py
+++ b/awx_collection/test/awx/test_schedule.py
@@ -82,7 +82,7 @@ def test_delete_same_named_schedule(run_module, project, inventory, admin_user):
)
def test_rrule_lookup_plugin(collection_import, freq, kwargs, expect):
LookupModule = collection_import('plugins.lookup.schedule_rrule').LookupModule()
- generated_rule = LookupModule.get_rrule(freq, kwargs)
+ generated_rule = LookupModule.get_rrule(freq, kwargs)[0]
assert generated_rule == expect
rrule_checker = SchedulePreviewSerializer()
# Try to run our generated rrule through the awx validator
@@ -99,7 +99,7 @@ def test_empty_schedule_rrule(collection_import, freq):
pfreq = 'DAILY;COUNT=1'
else:
pfreq = freq.upper() + 'LY'
- assert LookupModule.get_rrule(freq, {}).endswith(' RRULE:FREQ={0};INTERVAL=1'.format(pfreq))
+ assert LookupModule.get_rrule(freq, {})[0].endswith(' RRULE:FREQ={0};INTERVAL=1'.format(pfreq))
@pytest.mark.parametrize(