Support staged group bid funding
Verify and publish checkpoint container / container (push) Successful in 10m27s

This commit is contained in:
Quintine committed 2026-10-28 23:22:50 +11:00
1 parent 34aa64cdef
commit 1eeeb32566
12 files changed
+426 -37

No files matched your search

+23
View File
@@ -69,6 +69,29 @@ void test('staged group shipment funding appears on the live table for the donor
assert.match(markup(game, 'e'), /Pledge to Atreides offerer · 1 spice currently set aside/);
});
void test('staged group bid funding displays donor selection in the ordinary auction', () => {
let game = nexusOfferGame();
game.coalitionState = emptyCoalitionState();
game = applyAction(game, 'a', {type:'alliance', target:'e'});
game = applyAction(game, 'e', {type:'alliance', target:'a'});
const pair = coalitionOf(game.players, game.coalitionState, 'a'); assert.ok(pair);
game = applyAction(game, 'a', {type:'coalitionPropose', groupId:pair.id,
entrant:'h', expectedRevision:game.coalitionState!.revision});
for (const id of ['e', 'h']) {
const offer = game.coalitionState!.proposal!;
game = applyAction(game, id, {type:'coalitionAnswer', event:offer.event, nexus:offer.nexus,
turn:offer.turn, accept:true, expectedRevision:game.coalitionState!.revision});
}
const card = game.deck.shift(); assert.ok(card);
// Stage an ordinary lot with its original physical card in auction custody.
Object.assign(game, {phase:3, nexus:false, active:'a', ready:[], auction:{
cards:[card], index:0, bid:0, bidder:null, active:'a', passed:[], opener:0,
}});
game = applyAction(game, 'e', {type:'coalitionPledge', recipient:'a', amount:1});
assert.match(markup(game, 'a'), /Use from Emperor recipient for your next bid/);
assert.match(markup(game, 'a'), /Raise bid/);
});
void test('live outgoing offer is named and withdrawable only by its sender, separately from an incoming invitation', () => {
const g = applyAction(nexusOfferGame(), 'a', { type: 'alliance', target: 'e' });
const html = markup(g);