1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
|
Received: from sog-mx-3.v43.ch3.sourceforge.com ([172.29.43.193]
helo=mx.sourceforge.net)
by sfs-ml-1.v29.ch3.sourceforge.com with esmtp (Exim 4.76)
(envelope-from <bitcoin-list@bluematt.me>) id 1SwDc7-0007TF-GR
for bitcoin-development@lists.sourceforge.net;
Tue, 31 Jul 2012 14:39:59 +0000
Received-SPF: pass (sog-mx-3.v43.ch3.sourceforge.com: domain of bluematt.me
designates 173.246.101.161 as permitted sender)
client-ip=173.246.101.161;
envelope-from=bitcoin-list@bluematt.me; helo=mail.bluematt.me;
Received: from vps.bluematt.me ([173.246.101.161] helo=mail.bluematt.me)
by sog-mx-3.v43.ch3.sourceforge.com with esmtp (Exim 4.76)
id 1SwDc1-00075a-Tz for bitcoin-development@lists.sourceforge.net;
Tue, 31 Jul 2012 14:39:59 +0000
Received: from [IPv6:2001:470:9ff2:1:221:ccff:fe5d:b72] (unknown
[IPv6:2001:470:9ff2:1:221:ccff:fe5d:b72])
by mail.bluematt.me (Postfix) with ESMTPSA id 9B9152FC7
for <bitcoin-development@lists.sourceforge.net>;
Tue, 31 Jul 2012 14:39:47 +0000 (UTC)
Message-ID: <1343745585.3416.3.camel@bmthinkpad.lan.bluematt.me>
From: Matt Corallo <bitcoin-list@bluematt.me>
To: bitcoin-development@lists.sourceforge.net
Date: Tue, 31 Jul 2012 16:39:45 +0200
In-Reply-To: <CABsx9T016OmU2qU1a67=YmpA4VDbzrddOamc8=Mt6x7BhVO1Uw@mail.gmail.com>
References: <1343579466.30862.YahooMailNeo@web121004.mail.ne1.yahoo.com>
<501565D5.4060608@justmoon.de>
<1343580154.34128.YahooMailNeo@web121004.mail.ne1.yahoo.com>
<50157450.8070806@justmoon.de>
<CABsx9T016OmU2qU1a67=YmpA4VDbzrddOamc8=Mt6x7BhVO1Uw@mail.gmail.com>
Content-Type: text/plain; charset="UTF-8"
X-Mailer: Evolution 3.2.2-1
Content-Transfer-Encoding: 7bit
Mime-Version: 1.0
X-Spam-Score: -1.5 (-)
X-Spam-Report: Spam Filtering performed by mx.sourceforge.net.
See http://spamassassin.org/tag/ for more details.
-1.5 SPF_CHECK_PASS SPF reports sender host as permitted sender for
sender-domain
-0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay
domain
-0.0 SPF_PASS SPF: sender matches SPF record
X-Headers-End: 1SwDc1-00075a-Tz
Subject: Re: [Bitcoin-development] script tests - invalid script in
script_valid.json?
X-BeenThere: bitcoin-development@lists.sourceforge.net
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: <bitcoin-development.lists.sourceforge.net>
List-Unsubscribe: <https://lists.sourceforge.net/lists/listinfo/bitcoin-development>,
<mailto:bitcoin-development-request@lists.sourceforge.net?subject=unsubscribe>
List-Archive: <http://sourceforge.net/mailarchive/forum.php?forum_name=bitcoin-development>
List-Post: <mailto:bitcoin-development@lists.sourceforge.net>
List-Help: <mailto:bitcoin-development-request@lists.sourceforge.net?subject=help>
List-Subscribe: <https://lists.sourceforge.net/lists/listinfo/bitcoin-development>,
<mailto:bitcoin-development-request@lists.sourceforge.net?subject=subscribe>
X-List-Received-Date: Tue, 31 Jul 2012 14:39:59 -0000
On Sun, 2012-07-29 at 20:52 -0400, Gavin Andresen wrote:
> > Is there interest to port more tests (P2SH, checksig, checkmultisig,
> > block verification, maybe even DoS rules) into data-driven format? It
> > might be something that I'd like to help with if pull requests in that
> > direction are welcome.
>
> Yes, more tests are definitely welcome.
>
> check*sig tests are tricky, because they have to refer to previous
> unspent transactions and private keys (so require a particular block
> chain to test against). Brilliant ideas on a simple data-driven format
> welcome.
>
> block verification tests would be great; a collection of good/bad
> block chains, starting from a common chain (maybe the testnet3
> tesnet-in-a-box chain) would be very useful for regression testing.
>
I wrote a simple block chain tester (that is capable of forking,
checking invalid blocks, etc) as a part of the bitcoinj test suite. Its
more targeted at testing bitcoinj directly and keeping the bitcoinj test
suite light weight, so if it were to be more generic some tweaks could
be done (not requiring tweaking the minimum difficulty/genesis block
hash/etc would be first). It doesn't have that many test cases yet, but
it is capable of sanity-testing reorgs/etc. Its mostly the first two
commits listed at
http://code.google.com/r/bluemattme-bitcoinj/source/list?name=fullverif
Matt
|