aboutsummaryrefslogtreecommitdiff
path: root/src/test/script_P2SH_tests.cpp
diff options
context:
space:
mode:
authorGavin Andresen <gavinandresen@gmail.com>2013-04-24 18:27:00 -0400
committerGavin Andresen <gavinandresen@gmail.com>2013-05-03 10:52:09 -0400
commit8de9bb53af32f7f6b09c06f831f2c0a7b4e95303 (patch)
treeafb7c68d3fd15203308f38a47a3cc3875d476a2f /src/test/script_P2SH_tests.cpp
parentb8e1dc2e53b9d19df26a87686dfd435b3b346f9c (diff)
downloadbitcoin-8de9bb53af32f7f6b09c06f831f2c0a7b4e95303.tar.xz
Define dust transaction outputs, and make them non-standard
Diffstat (limited to 'src/test/script_P2SH_tests.cpp')
-rw-r--r--src/test/script_P2SH_tests.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/test/script_P2SH_tests.cpp b/src/test/script_P2SH_tests.cpp
index 3444726ca0..ee0d25a2f5 100644
--- a/src/test/script_P2SH_tests.cpp
+++ b/src/test/script_P2SH_tests.cpp
@@ -78,7 +78,9 @@ BOOST_AUTO_TEST_CASE(sign)
for (int i = 0; i < 4; i++)
{
txFrom.vout[i].scriptPubKey = evalScripts[i];
+ txFrom.vout[i].nValue = COIN;
txFrom.vout[i+4].scriptPubKey = standardScripts[i];
+ txFrom.vout[i+4].nValue = COIN;
}
BOOST_CHECK(txFrom.IsStandard());
@@ -169,6 +171,7 @@ BOOST_AUTO_TEST_CASE(set)
for (int i = 0; i < 4; i++)
{
txFrom.vout[i].scriptPubKey = outer[i];
+ txFrom.vout[i].nValue = CENT;
}
BOOST_CHECK(txFrom.IsStandard());
@@ -179,7 +182,7 @@ BOOST_AUTO_TEST_CASE(set)
txTo[i].vout.resize(1);
txTo[i].vin[0].prevout.n = i;
txTo[i].vin[0].prevout.hash = txFrom.GetHash();
- txTo[i].vout[0].nValue = 1;
+ txTo[i].vout[0].nValue = 1*CENT;
txTo[i].vout[0].scriptPubKey = inner[i];
BOOST_CHECK_MESSAGE(IsMine(keystore, txFrom.vout[i].scriptPubKey), strprintf("IsMine %d", i));
}