Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions packaging/ns8/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,9 +116,10 @@ after restoring, the app served 200, logged "keyvault: DEK unwrapped from
keystore", the encryption-key fingerprint was unchanged, and an event type
created before the backup was still there.

The `tests/` robot suite is wired up and dry-run clean (5/5, Robot 7.5), but it
has still never been executed against a live cluster. Every live check above
was done by hand. See [Testing](#testing).
The `tests/` robot suite has now been run against a live cluster: 4/4 without
the browser and 5/5 with `RUN_UI_TESTS=true`, on a single-node NS8 built from

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This 5/5 with RUN_UI_TESTS=true claim is contradicted by the PR's own Verification section, which still ends with "The [ui] test is still the only one that has never executed; it needs RUN_UI_TESTS=true and the Playwright image." One of the two is stale — worth resolving in whichever is wrong, since the line this paragraph replaces existed precisely because an unverified claim about what had actually been run was a problem.

`ns8-core@ns8-stable` on Rocky 9.8. Running it is what turned up the
route-registration race described in [Testing](#testing).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The pointer says the race is described in Testing, but that section only covers which suite file does what, how to run locally, and the CI situation — it never mentions asynchronous route registration. Either add the one-line "the route check polls because Traefik registers the route after configure-module returns" note there, or drop the link so it isn't a dead reference. While here: this paragraph also lands as the last block of Backup and restore, which is unrelated to backups.


## Uninstall

Expand Down
16 changes: 12 additions & 4 deletions packaging/ns8/tests/10__calnode.robot
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ Library SSHLibrary
${TEST_HOST} calnode.example.test
${module_id} ${EMPTY}

*** Keywords ***
The route responds
${rc} = Execute Command curl -f -H 'Host: ${TEST_HOST}' http://127.0.0.1/
... return_rc=True return_stdout=False
Should Be Equal As Integers ${rc} 0

*** Test Cases ***
Check if ns8-calnode is installed correctly
${output} ${rc} = Execute Command add-module ${IMAGE_URL} 1
Expand All @@ -19,7 +25,9 @@ Check if ns8-calnode can be configured
Should Be Equal As Integers ${rc} 0

Check if ns8-calnode works as expected
# Host-based route: pass the hostname explicitly since it does not resolve here
${rc} = Execute Command curl -f -H 'Host: ${TEST_HOST}' http://127.0.0.1/
... return_rc=True return_stdout=False
Should Be Equal As Integers ${rc} 0
# Host-based route: pass the hostname explicitly since it does not resolve here.
# configure-module returns as soon as the module is configured, but Traefik
# registers the route asynchronously a few seconds later. Polling here rather
# than sleeping a fixed amount keeps the test fast when the route is already
# up, and stops it flaking with "curl: (22) 404" on a slow node.
Wait Until Keyword Succeeds 60x 5s The route responds
Loading