Fixed mysterious "Tests Failed" error when all tests pass

Example of a failed Jenkins job:
https://wmf.ci.cloudbees.com/view/s-t2.w/job/browsertests-test2.wikipedi
a.org-linux-chrome/326/console
Bug: 48214

Change-Id: Id8d2431e1fc40f1611e7a9207bf8ac6d95b2d159
Merge "Fixed mysterious "Tests Failed" error when all tests pass"