diff options
| author | Wladimir J. van der Laan <[email protected]> | 2016-09-30 12:35:48 +0200 |
|---|---|---|
| committer | Wladimir J. van der Laan <[email protected]> | 2016-09-30 12:36:02 +0200 |
| commit | 90adfabd5daa2434af33f75df965d6aa23cd636c (patch) | |
| tree | 2e800b02cf722f334300846910216472f3075ca8 /src/test | |
| parent | Merge #8839: test: Avoid ConnectionResetErrors during RPC tests (diff) | |
| parent | bitcoin-util-test.py should fail if the output file is empty (diff) | |
| download | discoin-90adfabd5daa2434af33f75df965d6aa23cd636c.tar.xz discoin-90adfabd5daa2434af33f75df965d6aa23cd636c.zip | |
Merge #8836: bitcoin-util-test.py should fail if the output file is empty
da94697 bitcoin-util-test.py should fail if the output file is empty (jnewbery)
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/bctest.py | 3 | ||||
| -rw-r--r-- | src/test/data/txcreate2.json | 19 |
2 files changed, 22 insertions, 0 deletions
diff --git a/src/test/bctest.py b/src/test/bctest.py index 8105b87ff..39a27fcd0 100644 --- a/src/test/bctest.py +++ b/src/test/bctest.py @@ -24,6 +24,9 @@ def bctest(testDir, testObj, exeext): if "output_cmp" in testObj: outputFn = testObj['output_cmp'] outputData = open(testDir + "/" + outputFn).read() + if not outputData: + print("Output data missing for " + outputFn) + sys.exit(1) proc = subprocess.Popen(execrun, stdin=stdinCfg, stdout=subprocess.PIPE, stderr=subprocess.PIPE,universal_newlines=True) try: outs = proc.communicate(input=inputData) diff --git a/src/test/data/txcreate2.json b/src/test/data/txcreate2.json index e69de29bb..c56293eaf 100644 --- a/src/test/data/txcreate2.json +++ b/src/test/data/txcreate2.json @@ -0,0 +1,19 @@ +{ + "txid": "cf90229625e9eb10f6be8156bf6aa5ec2eca19a42b1e05c11f3029b560a32e13", + "version": 1, + "locktime": 0, + "vin": [ + ], + "vout": [ + { + "value": 0.00, + "n": 0, + "scriptPubKey": { + "asm": "", + "hex": "", + "type": "nonstandard" + } + } + ], + "hex": "01000000000100000000000000000000000000" +} |