shohu / c0ban

c0ban source tree
MIT License
0 stars 0 forks source link

c0ban functional test ver 4 for crash bug with duplicate inputs within a transaction #70

Open shohu opened 5 years ago

shohu commented 5 years ago

How to test

See. https://github.com/shohu/c0ban/tree/v0.15.1-new/test

BASE_SCRIPTS (63/64)

No test file status note
1 wallet-hd.py OK
2 walletbackup.py OK
3 p2p-fullblocktest.py OK
4 fundrawtransaction.py OK
5 p2p-compactblocks.py OK
6 segwit.py OK
7 wallet.py OK
8 wallet-accounts.py OK
9 p2p-segwit.py OK
10 wallet-dump.py OK
11 listtransactions.py OK
12 sendheaders.py OK
13 zapwallettxes.py OK
14 importmulti.py OK
15 mempool_limit.py OK
16 merkle_blocks.py OK
17 receivedby.py OK
18 abandonconflict.py OK
19 bip68-112-113-p2p.py PEN
21 rawtransactions.py OK
22 reindex.py OK
23 keypool-topup.py OK
24 zmq_test.py OK
25 bitcoin_cli.py OK
26 mempool_resurrect_test.py OK
27 getchaintips.py OK
28 rest.py OK
29 mempool_spendcoinbase.py OK
30 mempool_reorg.py OK
31 mempool_persist.py OK
32 multiwallet.py OK
33 httpbasics.py OK
34 multi_rpc.py OK
35 proxy_test.py OK
36 signrawtransactions.py OK
37 disconnect_ban.py OK
38 decodescript.py OK
39 blockchain.py OK #58
40 disablewallet.py OK
41 net.py OK
42 keypool.py OK
43 p2p-mempool.py OK
44 prioritise_transaction.py OK
45 invalidblockrequest.py OK
46 invalidtxrequest.py OK
47 p2p-versionbits-warning.py OK
48 preciousblock.py OK
49 importprunedfunds.py OK
50 signmessages.py OK
51 nulldummy.py OK
52 import-rescan.py OK
53 mining.py NG
54 bumpfee.py OK #61
55 rpcnamedargs.py OK
56 listsinceblock.py OK
57 p2p-leaktests.py OK
58 wallet-encryption.py OK
59 bipdersig-p2p.py OK
60 bip65-cltv-p2p.py OK
61 uptime.py OK
62 resendwallettransactions.py OK
63 minchainwork.py OK
64 p2p-acceptblock.py OK

EXTENDED_SCRIPTS (18/18)

No test file status note
1 pruning.py PEN #30
2 smartfees.py OK
3 maxuploadtarget.py OK
4 mempool_packages.py OK
5 dbcrash.py OK
6 bip68-sequence.py OK
7 getblocktemplate_longpoll.py OK
8 p2p-timeouts.py OK
9 bip9-softforks.py OK
10 p2p-feefilter.py OK
11 rpcbind_test.py PEN
12 assumevalid.py OK
13 example_test.py OK
14 txn_doublespend.py OK
15 txn_clone.py OK
16 forknotify.py OK
17 invalidateblock.py OK
18 replace-by-fee.py OK
shohu commented 5 years ago
# python3 test/functional/test_runner.py --quiet
:
:
TEST                           | STATUS    | DURATION

abandonconflict.py             | P Passed  | 14 s
bip65-cltv-p2p.py              | P Passed  | 6 s
bipdersig-p2p.py               | P Passed  | 5 s
bitcoin_cli.py                 | P Passed  | 2 s
blockchain.py                  | P Passed  | 9 s
bumpfee.py                     | P Passed  | 16 s
decodescript.py                | P Passed  | 2 s
disablewallet.py               | P Passed  | 3 s
disconnect_ban.py              | P Passed  | 6 s
getchaintips.py                | P Passed  | 7 s
httpbasics.py                  | P Passed  | 3 s
import-rescan.py               | P Passed  | 6 s
importmulti.py                 | P Passed  | 6 s
importprunedfunds.py           | P Passed  | 4 s
invalidblockrequest.py         | P Passed  | 4 s
invalidtxrequest.py            | P Passed  | 4 s
keypool-topup.py               | P Passed  | 9 s
keypool.py                     | P Passed  | 7 s
listsinceblock.py              | P Passed  | 4 s
listtransactions.py            | P Passed  | 13 s
mempool_limit.py               | P Passed  | 5 s
mempool_persist.py             | P Passed  | 18 s
mempool_reorg.py               | P Passed  | 5 s
mempool_resurrect_test.py      | P Passed  | 3 s
mempool_spendcoinbase.py       | P Passed  | 3 s
merkle_blocks.py               | P Passed  | 4 s
minchainwork.py                | P Passed  | 6 s
mining.py                      | x Failed  | 3 s
multi_rpc.py                   | P Passed  | 4 s
multiwallet.py                 | P Passed  | 6 s
net.py                         | P Passed  | 3 s
nulldummy.py                   | P Passed  | 4 s
p2p-acceptblock.py             | P Passed  | 5 s
p2p-leaktests.py               | P Passed  | 8 s
p2p-mempool.py                 | P Passed  | 3 s
p2p-segwit.py                  | x Failed  | 127 s
p2p-versionbits-warning.py     | P Passed  | 9 s
preciousblock.py               | P Passed  | 3 s
prioritise_transaction.py      | P Passed  | 14 s
proxy_test.py                  | P Passed  | 4 s
rawtransactions.py             | P Passed  | 19 s
receivedby.py                  | P Passed  | 10 s
reindex.py                     | P Passed  | 12 s
resendwallettransactions.py    | P Passed  | 5 s
rest.py                        | P Passed  | 6 s
rpcnamedargs.py                | P Passed  | 2 s
sendheaders.py                 | P Passed  | 25 s
signmessages.py                | P Passed  | 3 s
signrawtransactions.py         | P Passed  | 3 s
txn_clone.py                   | P Passed  | 6 s
txn_doublespend.py --mineblock | P Passed  | 6 s
uptime.py                      | P Passed  | 3 s
wallet-accounts.py             | P Passed  | 5 s
wallet-dump.py                 | P Passed  | 7 s
wallet-encryption.py           | P Passed  | 8 s
zapwallettxes.py               | P Passed  | 10 s

follwoing tests were error.

mining.py p2p-segwit.py

shohu commented 5 years ago

p2p-segwit.py is OK šŸ‘

# python3 test/functional/p2p-segwit.py
2018-09-20 04:47:31.175000 TestFramework (INFO): Initializing test directory /tmp/testcsv1jzxr
2018-09-20 04:47:31.675000 TestFramework.mininode (INFO): Connecting to Bitcoin Node: 127.0.0.1:12998
2018-09-20 04:47:31.676000 TestFramework.mininode (INFO): Connecting to Bitcoin Node: 127.0.0.1:12998
2018-09-20 04:47:31.677000 TestFramework.mininode (INFO): Connecting to Bitcoin Node: 127.0.0.1:12999
2018-09-20 04:47:31.728000 TestFramework (INFO): Starting tests before segwit lock in:
2018-09-20 04:47:31.729000 TestFramework (INFO): Verifying NODE_WITNESS service bit
2018-09-20 04:47:31.729000 TestFramework (INFO): Testing non-witness transaction
2018-09-20 04:47:32.018000 TestFramework (INFO): Testing behavior of unnecessary witnesses
2018-09-20 04:47:32.747000 TestFramework (INFO): Testing block relay
2018-09-20 04:47:35.590000 TestFramework (INFO): Testing getblocktemplate setting of segwit versionbit (before lockin)
2018-09-20 04:47:45.691000 TestFramework (INFO): Testing behavior post lockin, pre-activation
2018-09-20 04:47:45.945000 TestFramework (INFO): Testing behavior of unnecessary witnesses
2018-09-20 04:47:46.723000 TestFramework (INFO): Testing relay of witness transactions
2018-09-20 04:47:49.178000 TestFramework (INFO): Testing block relay
2018-09-20 04:47:51.984000 TestFramework (INFO): Testing P2SH witness transactions
2018-09-20 04:47:52.566000 TestFramework (INFO): Testing standardness of v0 outputs (before activation)
2018-09-20 04:47:53.020000 TestFramework (INFO): Testing behavior after segwit activation
2018-09-20 04:47:53.427000 TestFramework (INFO): Testing P2SH witness transactions
2018-09-20 04:47:54.026000 TestFramework (INFO): Testing witness commitments
2018-09-20 04:47:54.562000 TestFramework (INFO): Testing witness block malleability
2018-09-20 04:47:55.024000 TestFramework (INFO): Testing witness block size limit
2018-09-20 04:48:00.284000 TestFramework (INFO): Testing extra witness data in tx
2018-09-20 04:48:00.760000 TestFramework (INFO): Testing maximum witness push size
2018-09-20 04:48:00.970000 TestFramework (INFO): Testing maximum witness program length
2018-09-20 04:48:01.183000 TestFramework (INFO): Testing witness input length
2018-09-20 04:48:01.708000 TestFramework (INFO): Testing block relay
2018-09-20 04:48:02.802000 TestFramework (INFO): Testing relay of witness transactions
2018-09-20 04:48:03.977000 TestFramework (INFO): Testing standardness of v0 outputs (after activation)
2018-09-20 04:48:04.481000 TestFramework (INFO): Testing standardness/consensus for segwit versions (0-16)
2018-09-20 04:48:08.728000 TestFramework (INFO): Testing premature coinbase witness spend
2018-09-20 04:48:09.486000 TestFramework (INFO): Testing uncompressed pubkeys
2018-09-20 04:48:10.435000 TestFramework (INFO): Testing segwit signature hash version 1
2018-09-20 04:48:31.946000 TestFramework (INFO): Testing detection of non-standard P2WSH witness
2018-09-20 04:48:34.024000 TestFramework (INFO): Testing software upgrade after softfork activation
2018-09-20 04:48:39.525000 TestFramework (INFO): Testing sigops limit
2018-09-20 04:48:40.068000 TestFramework (INFO): Stopping nodes
2018-09-20 04:48:42.365000 TestFramework (INFO): Cleaning up
2018-09-20 04:48:42.385000 TestFramework (INFO): Tests successful
shohu commented 5 years ago

mining.py is not good šŸ˜¢ I think this error is for change difficulty logic

# python3 test/functional/mining.py
2018-09-20 04:52:36.859000 TestFramework (INFO): Initializing test directory /tmp/testbrasazvb
2018-09-20 04:52:37.591000 TestFramework (INFO): getmininginfo
2018-09-20 04:52:37.592000 TestFramework (ERROR): Assertion failed
Traceback (most recent call last):
  File "/c0ban/test/functional/test_framework/test_framework.py", line 120, in main
    self.run_test()
  File "test/functional/mining.py", line 43, in run_test
    assert_equal(mining_info['difficulty'], Decimal('1'))
  File "/c0ban/test/functional/test_framework/util.py", line 38, in assert_equal
    raise AssertionError("not(%s)" % " == ".join(str(arg) for arg in (thing1, thing2) + args))
AssertionError: not(4.656542373906925E-10 == 1)
2018-09-20 04:52:37.600000 TestFramework (INFO): Stopping nodes
2018-09-20 04:52:39.763000 TestFramework (WARNING): Not cleaning up dir /tmp/testbrasazvb
2018-09-20 04:52:39.763000 TestFramework (ERROR): Test failed. Test logging available at /tmp/testbrasazvb/test_framework.log