Enable stdout passthrough for subunit-trace
One of the biggest issues with subunit-trace is when non-subunit data is passed into it gets dropped by subunit trace. This patch is an attempt (based on a similar patch to subunit-2to1) to allow non subunit data existing before the subunit stream to be printed on stdout. After the stream is detected however any other stdin unrelated content will still be lost. Closes-Bug: #1420067 Change-Id: I94c428120892b987c372473ac2128d73e9ba8f2d
This commit is contained in:
@@ -251,6 +251,9 @@ def main():
|
|||||||
failonly=args.failonly))
|
failonly=args.failonly))
|
||||||
summary = testtools.StreamSummary()
|
summary = testtools.StreamSummary()
|
||||||
result = testtools.CopyStreamResult([outcomes, summary])
|
result = testtools.CopyStreamResult([outcomes, summary])
|
||||||
|
result = testtools.StreamResultRouter(result)
|
||||||
|
cat = subunit.test_results.CatFiles(sys.stdout)
|
||||||
|
result.add_rule(cat, 'test_id', test_id=None)
|
||||||
start_time = datetime.datetime.utcnow()
|
start_time = datetime.datetime.utcnow()
|
||||||
result.startTestRun()
|
result.startTestRun()
|
||||||
try:
|
try:
|
||||||
|
|||||||
Reference in New Issue
Block a user