test(serve): point the shared-server --global case at the test server (#7167)
TestSharedServerModeServeGlobalReportsTheServedDatabase was parked outside the proxied discovery pattern because `bd serve --global` exited 1 on the #5920 shared-store migration guard (v65 -> v69). The guard was right; the test setup was wrong. The workspace was a plain `bd init --server --server-port <test server>` that only flipped BEADS_DOLT_SHARED_SERVER=1 afterwards. Shared-server mode deliberately ignores the workspace's own dolt_server_port and resolves the machine-wide shared server (BEADS_DOLT_SERVER_PORT, the shared port file, ..., then the 3308 default), so every --global command dialled 127.0.0.1:3308 rather than the hermetic test server. On CI nothing listens there; on a developer machine running a real shared server, the test read that server's own beads_global (created by an older bd at v65) and serve asked to migrate it. beads_global was also never provisioned on the test server, because only `bd init --shared-server` does that. Set the workspace up the way an operator joins an externally-managed shared server: `bd init --shared-server --external` (provisions beads_global on the test server at the current schema) plus BEADS_DOLT_SERVER_PORT naming that server. No product change: the guard correctly refuses an un-consented migration of a shared database, and a freshly created one (version 0) passes it. Rename the test into the TestServerMode* discovery pattern and add it to the Bazel 30-shard block via the generator's incremental --write. The frozen legacy 15-shard block is untouched; the name hash-distributes there (shard 12/15). Co-authored-by: Gas City Adopt-PR <adopt-pr@gascity.local> Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
f1b5944760
commit
60598ec146
2 changed files with 25 additions and 20 deletions
1
.github/scripts/proxied-cmd-test-shards.txt
vendored
1
.github/scripts/proxied-cmd-test-shards.txt
vendored
|
|
@ -277,6 +277,7 @@
|
|||
30 8 TestProxiedServerShow2
|
||||
30 8 TestProxiedServerTypes
|
||||
30 8 TestProxiedServerUpdateClosePolicy
|
||||
30 8 TestServerModeSharedServeGlobalReportsTheServedDatabase
|
||||
|
||||
30 9 TestProxiedServerCloseConcurrent
|
||||
30 9 TestProxiedServerDep2
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue