Skip to content
Snippets Groups Projects
Verified Commit c21df0e3 authored by Karel van Klink's avatar Karel van Klink :smiley_cat:
Browse files

add input step for radius insertion in create_router workflow

parent 23976c78
No related branches found
No related tags found
1 merge request!170add input step that prompts for Sharepoint checklist creation
This commit is part of merge request !170. Comments created here will be created in the context of that merge request.
...@@ -203,6 +203,25 @@ def prompt_insert_in_ims() -> FormGenerator: ...@@ -203,6 +203,25 @@ def prompt_insert_in_ims() -> FormGenerator:
return {} return {}
@inputstep("Prompt RADIUS insertion", assignee=Assignee.SYSTEM)
def prompt_insert_in_radius(subscription: RouterInactive) -> FormGenerator:
"""Wait for confirmation from an operator that the router has been inserted in RADIUS."""
class RadiusPrompt(FormPage):
class Config:
title = "Update RADIUS clients"
info_label_1: Label = (
f"Please go to https://kratos.geant.org/add_radius_client and add the {subscription.router.router_fqdn}" # type: ignore[assignment]
f" - {subscription.router.router_lo_ipv4_address} to radius authentication"
)
info_label_2: Label = "This will be functionally checked later during verification work." # type: ignore[assignment]
yield RadiusPrompt
return {}
@workflow( @workflow(
"Create router", "Create router",
initial_input_form=wrap_create_initial_input_form(initial_input_form_generator), initial_input_form=wrap_create_initial_input_form(initial_input_form_generator),
...@@ -231,6 +250,7 @@ def create_router() -> StepList: ...@@ -231,6 +250,7 @@ def create_router() -> StepList:
>> prompt_reboot_router >> prompt_reboot_router
>> prompt_console_login >> prompt_console_login
>> prompt_insert_in_ims >> prompt_insert_in_ims
>> prompt_insert_in_radius
>> router_is_nokia(create_netbox_device) >> router_is_nokia(create_netbox_device)
>> pp_interaction(run_checks_after_base_config) >> pp_interaction(run_checks_after_base_config)
>> set_status(SubscriptionLifecycle.PROVISIONING) >> set_status(SubscriptionLifecycle.PROVISIONING)
......
...@@ -87,8 +87,8 @@ def test_create_nokia_router_success( ...@@ -87,8 +87,8 @@ def test_create_nokia_router_success(
for _ in range(2): for _ in range(2):
result, step_log = assert_pp_interaction_success(result, process_stat, step_log) result, step_log = assert_pp_interaction_success(result, process_stat, step_log)
# Handle three consecutive user input steps # Handle four consecutive user input steps
for _ in range(3): for _ in range(4):
assert_suspended(result) assert_suspended(result)
result, step_log = resume_workflow(process_stat, step_log, input_data=USER_CONFIRM_EMPTY_FORM) result, step_log = resume_workflow(process_stat, step_log, input_data=USER_CONFIRM_EMPTY_FORM)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment