Repository navigation
fix(e2e-testing): what a team meets in the workshop, end to end - #819
Merged
Merged
Conversation
Walked step 2 as team 09 (PURIS) with its printed handout: Bruno against the mock, the team's own draft in the Test Suite IDE, and a TCK run with TestLab on a laptop. Fixes what got in the way. - Mocks: "Reset every scenario" resets only the product's own scenarios. All products share one WireMock in the workshop, and the global /__admin/scenarios/reset also reset the other teams' runs. build_mappings.py fails on a scenario name two products share, or a reset list that differs from the mappings; CI runs it and checks the cluster set. - PURIS mock: reported stocks answer [] before PURIS has fetched (was 404), and a second refresh answers 200. Bruno environments use mock.json's keys. - Template: the validate/field hint used items[0].id, which silently yields None. TestLab indexes lists as a segment, items.0.id. syntax.md explains it, and that a quantity like 20.0 is compared with a number. - Specs: a test can say needsRealProduct. Its page and "Done when" then say it compiles against the mock and turns green in step 3. PURIS uses it for the four tests a mock cannot make green; its negative registry test first finds the known material, so an empty registry no longer passes it. - Handouts: box D prints the data plane's public API (dataplanePublicUrl), which engine_dataplane_public_url asks for. - Chapters 3 and 6: the two-factor offer and welcome window, engine_* values from box D (engine_bpnl via "Another BPNL"), the SUT Setup that asks for nothing, the step that waits for the product and times out, and "got None". Assisted-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Mathias Moser <mathias.moser@catena-x.net>
Website previewThe preview was removed: this pull request was closed, no longer changes the website, or has the |
Running test 4 in the IDE with a real consumer on box C showed why it can never pass: the spec's setup names only connector/provider/create_mock_asset, which creates the asset on TestLab's connector but no contract definition, so the offer is in no catalog and the product cannot find it. CX-0135's TCK pairs it with two create_policy and a create_contract_definition; the PURIS spec now does the same, and withdraws them in teardown. The authoring guide in build_specs.py says so for every consumer-side test. Assisted-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Mathias Moser <mathias.moser@catena-x.net>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
I walked step 2 of the tutorial as a participant would: team 09 (PURIS) with its printed
handout, Bruno against the PURIS mock, the team's own draft in the Test Suite IDE, and the
same TCK with TestLab on a laptop. In the IDE the draft ran with 2 of 5 tests green, and
each red test traced back to the workshop set-up, not to the team's test. This PR fixes what
got in the way.
What changes
POST /__admin/scenarios/resetresets them all.Started(post-response script).build_mappings.pyfails on a scenario name two products share, or on a reset list that differs from the mappings; CI now runs it and checksmocks/deploy.404before the refresh; a second refresh answered404.[]until PURIS has fetched; a repeated refresh answers200and keeps the state. Bruno environments now carry the same key asmock.json.path: "items[0].id"silently yieldsNone.items.0.idin the template (and its agent-kit copy).syntax.mdexplains list paths, whatgot Nonemeans, and that a quantity like20.0must be compared with a number.needsRealProduct: the page says such a test compiles against the mock and turns green in step 3, and "Done when" says so. PURIS uses it on four tests.needsRealProduct, with the reason. Chapter 6's "Stuck?" names the timeout.unknown_material_has_no_stockwas green against an empty registry.engine_dataplane_public_urlwas asked for but was not on the handout;engine_bpnloffered only box C's BPN.dataplanePublicUrl). Chapter 6 says which values come from box D, and thatengine_bpnlis typed under "Another BPNL".create_mock_assetcreates only the asset, so the offer was in no catalog: a rerun with box C as a real consumer found nine offers on box D, none of them the run's.create_policy(Membership; Membership + FrameworkAgreement + UsagePurposecx.puris.base:1) and onecreate_contract_definitionper asset; teardown removes them. Rerun in the IDE: the offer is now in box D's catalog.engine_bpnlandengine_dataplane_public_urlas pre-filled values from box D; the agent kit says to write such a value in. With every value pre-filled, the Run dialog asks nothing.Checked
mkdocs build --strict.stockback toStarted, portal's onlyappandsa, and traceability'sreceivedkept its state.[]before and after the refresh, 20 pieces once fetched,401without the key.Not in this PR
cx-playground-infra.ENGINE_FAULT. That belongs to the engine; it reads as "the Test Suite broke" when the product never called.🤖 Generated with Claude Code