Repository navigation
test: add a manual driver for the space picker - #240
Merged
Merged
Conversation
NickJosevski
force-pushed
the
nj/space-id-dropdown
branch
from
September 17, 2026 08:06
4793293 to
57880b0
Compare
Walks the space picker through the real stack in a browser and screenshots each state. It is a driver rather than a test - it asserts almost nothing - and earns its place by regenerating the screenshots after a change to the picker's markup, and by making the id-survives-a-rename behaviour something you can watch rather than infer. Two modes. OCTOPUS_PICKER_DEMO=auto runs headless straight through, so it needs no display and works as a screenshot generator. OCTOPUS_PICKER_DEMO=1 runs headed and holds the stack open at each checkpoint, resumed by creating the file it names. Skipped via assumeTrue unless that variable is set, matching LocalOctopusReleaseLinkManualTest; without the gate it would block forever on the first checkpoint. Everything it writes stays under build/reports/space-picker, overridable with SPACE_PICKER_OUTPUT_DIR, and it never prints the API key. The free tier permits only one space, so the walkthrough renames that space out from under an already-saved step rather than creating several. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
NickJosevski
force-pushed
the
nj/space-picker-manual-test
branch
from
September 17, 2026 08:11
0383141 to
5d02ae5
Compare
Contributor
Author
|
gonna merge this just so there's some "prior art" for this in the repo, instead of getting Claude to re-invent it again. It's just test code in the end, and not part of the pipeline, so cost is low to just delete it if we change our mind. |
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.
Draft, and stacked on #239 — it drives selectors that only exist on that branch, so the base is
nj/space-id-dropdownrather thanmain. Retarget tomainonce #239 merges.What this is
SpacePickerManualTestwalks the space picker through the real containerised stack in a browser and screenshots each state. It is a driver, not a test — it asserts almost nothing. It earns its keep two ways:The walkthrough ends by renaming the Octopus space out from under an already-saved build step. The stored id keeps resolving while the stored name goes stale — which is the entire reason #239 stores an id:
The free tier permits exactly one space (
POST /api/spaces→ "You cannot create another space. This would exceed the limits of your current license."), so it renames the one space rather than creating several.Two modes
Interactive mode prints the TeamCity URL and admin login, holds the stack open, and names the file to create to continue.
Safe to have in the repo
assumeTrue, matchingLocalOctopusReleaseLinkManualTest. Verified: 1 test, 1 skipped, 0 failures, in 1s, no containers started. This matters — without the gate it would block forever on the first checkpoint file.build/reports/space-picker(socleanremoves it), overridable withSPACE_PICKER_OUTPUT_DIR. Nothing outside the build directory, nothing tied to one developer's machine.docs/e2e-tests.md, including the checkpoint mechanism, which nobody would guess.Why in this repo rather than its own
It depends on the
e2eDSL —OctopusTeamCityStack,SharedStack,TeamCityRest,OctopusProvisioning,PlaywrightUi— which is test-scope and partly package-private. Publishing or duplicating that elsewhere would be disproportionate.More importantly it hardcodes the plugin's own selectors (
button.octopusLoadSpaces,input[name='prop:octopus_space_id'],#octopusConnectionId). Those must change in the same commit as the JSP; out of the repo they would rot silently and the tool would be broken exactly when someone next needed it.Verification
OCTOPUS_PICKER_DEMO=autorun: BUILD SUCCESSFUL in 3m57s, all 10 screenshots produced, no checkpoint files, containers reaped.spotlessCheckclean.Two traps documented for anyone extending it
<select>popups are positioned by the window — they open detached from the control, bottom-right of the screen. Size the window with--window-sizeinstead. Headless tests never open a native popup, so this cannot surface there.prop:<property>, because that is how TeamCity's props taglib renders a property'snameattribute (theidis the bare property name).🤖 Generated with Claude Code