Support staged group bid funding
Verify and publish checkpoint container / container (push) Successful in 10m27s
Verify and publish checkpoint container / container (push) Successful in 10m27s
This commit is contained in:
1 parent
34aa64cdef
commit
1eeeb32566
12 files changed
+426
-37
No files matched your search
@@ -29,6 +29,12 @@ void test('each outgoing ally has a separate labelled pledge and incoming amount
|
||||
assert.match(html, /Fremen: 2 spice/);
|
||||
assert.match(html, /Use from Emperor for your next shipment/);
|
||||
assert.match(html, /Use from Fremen for your next shipment/);
|
||||
const bidding = renderToStaticMarkup(createElement(CoalitionFunding, {
|
||||
view, act() {}, onContributionsChange() {}, purpose: 'bid',
|
||||
}));
|
||||
assert.match(bidding, /Use from Emperor for your next bid/);
|
||||
assert.match(bidding, /Use from Fremen for your next bid/);
|
||||
assert.doesNotMatch(bidding, /for your next shipment/);
|
||||
});
|
||||
|
||||
void test('pledge action uses the named recipient and validates whole, safe limits', () => {
|
||||
@@ -41,6 +47,15 @@ void test('pledge action uses the named recipient and validates whole, safe limi
|
||||
assert.equal(coalitionPledgeAction(target, invalid, null), null);
|
||||
assert.equal(coalitionPledgeAction(target, '2', 'Finish the pending payment.'), null);
|
||||
assert.equal(coalitionPledgeAction(target, '2', null, true), null);
|
||||
const committed = {...target, minimum: 2};
|
||||
assert.equal(coalitionPledgeAction(committed, '1', null), null);
|
||||
assert.deepEqual(coalitionPledgeAction(committed, '2', null),
|
||||
{type: 'coalitionPledge', recipient: 'b', amount: 2});
|
||||
const html = renderToStaticMarkup(createElement(CoalitionFunding, {
|
||||
view:{...view, targets:[committed]}, act() {}, purpose:'bid',
|
||||
}));
|
||||
assert.match(html, /The current high bid commits 2 spice of this pledge/);
|
||||
assert.match(html, /min="2"/);
|
||||
});
|
||||
|
||||
void test('shipment selections retain donor identity and clamp to live pledges', () => {
|
||||
|
||||
Reference in new issue
Block a user