Add RTM session and configurable token generator flow
This commit is contained in:
+34
-4
@@ -18,7 +18,27 @@ Common URL, login credentials, login waits, and step delay stay at the top level
|
||||
`products` contains separate `IDAS`, `RTM`, `UPC`, `RA`, and `REC` sections.
|
||||
Each product has its own `me_instance`, optional `session` timing overrides, and
|
||||
`token` settings (codes, delivery offset, expiry, and time sessions).
|
||||
Existing IDAS settings are preserved. Other product templates are disabled until
|
||||
RTM currently runs token creation only (`run_session: false`, `run_token: true`).
|
||||
If enabled again, session creation uses ME instance
|
||||
`52` (`52:RTM`). It uses today's date plus a 7-minute start offset and today's
|
||||
`20:30` end time, matching the current IDAS session end-time default. Change
|
||||
`products.RTM.session.start_offset_minutes` and `products.RTM.session.end_time`
|
||||
to configure RTM independently. The shared login, navigation, and Save steps apply
|
||||
to every product. RTM token automation opens Token Generator,
|
||||
selects `NATIONAL`, product code `RTM`, and generation mode `RTM`, then clicks
|
||||
Add New Token. Product Type is populated automatically. It fills delivery dates
|
||||
with today's `00:00` and `23:59`, session start with current time plus 5 minutes,
|
||||
and session end with `20:00`, then clicks Save Token. All four timings are
|
||||
configured under `products.RTM.token` as shown below. `delivery_offset_days: 0`
|
||||
means today. RTM activation is not part of this stage.
|
||||
|
||||
Run RTM token creation through Save Token:
|
||||
|
||||
```powershell
|
||||
pytest tests\setup -k RTM -s
|
||||
```
|
||||
|
||||
Existing IDAS settings are preserved. The remaining product templates are disabled until
|
||||
you fill in their actual ME instance/token codes and set `enabled` to `true`.
|
||||
Additional products can be added using the same structure.
|
||||
|
||||
@@ -29,11 +49,21 @@ To override the defaults for one product, add flags directly inside that product
|
||||
"enabled": true,
|
||||
"run_session": false,
|
||||
"run_token": true,
|
||||
"me_instance": "",
|
||||
"me_instance": "52",
|
||||
"session": {
|
||||
"start_offset_minutes": 7,
|
||||
"end_time": "20:30"
|
||||
},
|
||||
"token": {
|
||||
"market_code": "NATIONAL",
|
||||
"product_type": "RTM",
|
||||
"product_codes": "YOUR_ACTUAL_RTM_CODE"
|
||||
"product_codes": ["RTM"],
|
||||
"generation_mode": "RTM",
|
||||
"delivery_offset_days": 0,
|
||||
"delivery_from_time": "00:00",
|
||||
"delivery_to_time": "23:59",
|
||||
"session_start_offset_minutes": 5,
|
||||
"session_end_time": "20:00"
|
||||
}
|
||||
}
|
||||
```
|
||||
@@ -45,7 +75,7 @@ Session timing overrides inherit any fields omitted from `setup.session`.
|
||||
Token timing settings belong to each product independently.
|
||||
|
||||
Use `pytest tests\setup -s` to run all enabled products. Each product runs in its
|
||||
own browser: both flags true runs session then tokens in one login; otherwise
|
||||
own browser: both flags true runs session then the product's token flow in one login; otherwise
|
||||
only its enabled action runs. Test/report names include the product name.
|
||||
The session and token subfolder commands below select only products configured
|
||||
for session-only and token-only respectively; use the full setup command for a
|
||||
|
||||
Reference in New Issue
Block a user