diff options
author | jnewbery <john@johnnewbery.com> | 2016-09-29 10:13:16 -0400 |
---|---|---|
committer | MarcoFalke <falke.marco@gmail.com> | 2016-10-03 10:56:41 +0200 |
commit | eb18cc1272e1f29b2caccf08aedee3de6fc3c437 (patch) | |
tree | 060ce3c18d5f410414cc043d644c380650751101 /src/test/bctest.py | |
parent | d87227d6d2d6e06af1ef4ad13e2b15f1d4d43600 (diff) | |
download | bitcoin-eb18cc1272e1f29b2caccf08aedee3de6fc3c437.tar.xz |
bitcoin-util-test.py should fail if the output file is empty
Github-Pull: #8836
Rebased-From: da9469770847df56e67e629986129a087b5bd7a5
Diffstat (limited to 'src/test/bctest.py')
-rw-r--r-- | src/test/bctest.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/test/bctest.py b/src/test/bctest.py index 8105b87ffa..39a27fcd0c 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) |