aboutsummaryrefslogtreecommitdiff
path: root/src/test/transaction_tests.cpp
diff options
context:
space:
mode:
authorJeff Garzik <jgarzik@bitpay.com>2013-06-23 02:05:25 -0400
committerJeff Garzik <jgarzik@bitpay.com>2013-06-23 02:05:25 -0400
commit980bfe6ef8bf03633d98f4d51e925c1aa4349421 (patch)
tree99249d423182ee44f4a8075aec337267498855d2 /src/test/transaction_tests.cpp
parentb4a8a326c067a350b5a5ff0e565555b57ffb3a2e (diff)
Log reason for non-standard transaction rejection
Diffstat (limited to 'src/test/transaction_tests.cpp')
-rw-r--r--src/test/transaction_tests.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/test/transaction_tests.cpp b/src/test/transaction_tests.cpp
index 53d1307b69..0c7475b4f2 100644
--- a/src/test/transaction_tests.cpp
+++ b/src/test/transaction_tests.cpp
@@ -260,16 +260,17 @@ BOOST_AUTO_TEST_CASE(test_IsStandard)
key.MakeNewKey(true);
t.vout[0].scriptPubKey.SetDestination(key.GetPubKey().GetID());
- BOOST_CHECK(IsStandardTx(t));
+ string reason;
+ BOOST_CHECK(IsStandardTx(t, reason));
t.vout[0].nValue = 5011; // dust
- BOOST_CHECK(!IsStandardTx(t));
+ BOOST_CHECK(!IsStandardTx(t, reason));
t.vout[0].nValue = 6011; // not dust
- BOOST_CHECK(IsStandardTx(t));
+ BOOST_CHECK(IsStandardTx(t, reason));
t.vout[0].scriptPubKey = CScript() << OP_1;
- BOOST_CHECK(!IsStandardTx(t));
+ BOOST_CHECK(!IsStandardTx(t, reason));
}
BOOST_AUTO_TEST_SUITE_END()