core-lightning/tests
Rusty Russell 1c26ebdb31 pytest: fix flake in test_wumbo_channels
We might only have seen one side of the channel, as shown below.  Wait
for both:

```
_____________________________ test_wumbo_channels ______________________________
[gw2] linux -- Python 3.7.13 /opt/hostedtoolcache/Python/3.7.13/x64/bin/python3

node_factory = <pyln.testing.utils.NodeFactory object at 0x7f5d51743b10>
bitcoind = <pyln.testing.utils.BitcoinD object at 0x7f5d51699d10>

    @pytest.mark.openchannel('v1')
    @pytest.mark.openchannel('v2')
    def test_wumbo_channels(node_factory, bitcoind):
        l1, l2, l3 = node_factory.get_nodes(3,
                                            opts=[{'large-channels': None},
                                                  {'large-channels': None},
                                                  {}])
        conn = l1.rpc.connect(l2.info['id'], 'localhost', port=l2.port)
    
        expected_features = expected_peer_features(wumbo_channels=True)
        if l1.config('experimental-dual-fund'):
            expected_features = expected_peer_features(wumbo_channels=True,
                                                       extra=[21, 29])
    
        assert conn['features'] == expected_features
        assert only_one(l1.rpc.listpeers(l2.info['id'])['peers'])['features'] == expected_features
    
        # Now, can we open a giant channel?
        l1.fundwallet(1 << 26)
        l1.rpc.fundchannel(l2.info['id'], 1 << 24)
    
        # Get that mined, and announced.
        bitcoind.generate_block(6, wait_for_mempool=1)
    
        # Connect l3, get gossip.
        l3.rpc.connect(l1.info['id'], 'localhost', port=l1.port)
        wait_for(lambda: len(l3.rpc.listnodes(l1.info['id'])['nodes']) == 1)
        wait_for(lambda: 'features' in only_one(l3.rpc.listnodes(l1.info['id'])['nodes']))
    
        # Make sure channel capacity is what we expected.
>       assert ([c['amount_msat'] for c in l3.rpc.listchannels()['channels']]
                == [Millisatoshi(str(1 << 24) + "sat")] * 2)
E       assert [16777216000msat] == [16777216000m...777216000msat]
E         Right contains one more item: 16777216000msat
E         Full diff:
E         - [16777216000msat, 16777216000msat]
E         + [16777216000msat]
```

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2022-07-27 19:31:04 +09:30
..
data inflights: save the whole psbt to the database 2021-05-24 12:17:48 +09:30
fuzz fuzz: fix fuzzing compilation. 2022-07-25 08:08:32 -07:00
plugins Makefile: use a library archive for CCAN 2022-07-17 08:51:02 +09:30
vectors pytest: Remove onion test vectors containing legacy onions. 2022-03-18 09:20:11 +10:30
benchmark.py pytest: always provide payment_secret when making payments. 2021-07-14 14:38:00 -05:00
conftest.py tests: add marker for v1/v2 channel opens 2021-05-12 11:25:41 +09:30
db.py pytest: don't copy db to query it. 2021-08-26 12:44:02 +09:30
fixtures.py pytest: set dblog-file when adding the dblog plugin (TEST_CHECK_DBSTMTS=1) 2022-07-26 09:33:40 -07:00
test_cln_rs.py pytest: Move generated grpc bindings to pyln-testing 2022-07-21 14:19:06 +09:30
test_closing.py pytest: fix flake in test_channel_lease_post_expiry 2022-07-18 20:50:04 -05:00
test_connection.py pytest: fix flake in test_wumbo_channels 2022-07-27 19:31:04 +09:30
test_db.py pytest: don't redirect stderr by default. 2022-07-21 15:37:05 -05:00
test_gossip.py pytest: don't redirect stderr by default. 2022-07-21 15:37:05 -05:00
test_invoices.py plugin: autoclean fix double free when re-enable, remove xfail mark from test_ 2022-07-16 14:19:05 +09:30
test_misc.py tests: local flake fix; l1 was waiting too long to reconnect 2022-07-26 15:11:30 -07:00
test_onion.py lightningd: remove support for legacy onion format. 2022-03-18 09:20:11 +10:30
test_opening.py flake: permit test_v2_open_sigs_restart_while_dead to succeed/fail 2022-07-27 19:31:04 +09:30
test_pay.py sendpay: allow route to contain both amount_msat and (deprecated) msatoshi. 2022-07-12 12:42:05 -05:00
test_plugin.py pytest: fix test_commando_rune flake. 2022-07-26 09:48:56 -07:00
test_wallet.py hsmtool: implement checkhsm. 2022-07-22 16:57:27 +02:00
utils.py bolt: Reflect the zeroconf featurebits in code 2022-07-04 22:14:06 +02:00
valgrind-suppressions.txt pytest: Use valgrind target suppressions instead of skipping tests 2022-03-10 10:21:41 +10:30