Patch test text for non conforming tests

This commit is contained in:
Berkeley Martinez
2015-12-02 13:04:50 -08:00
parent 4c3889d639
commit 8ec4720345

View File

@ -53,11 +53,12 @@ window.$(document).ready(function() {
userTest.err = e.message.split(':').shift(); userTest.err = e.message.split(':').shift();
} finally { } finally {
if (!test.match(/message: /g)) { if (!test.match(/message: /g)) {
userTest.text = 'message: ' + test // assumes test does not contain arrays
// This is a patch until all test fall into this pattern
userTest.text = test
.split(',') .split(',')
.pop() .pop();
.replace(/\'/g, '') userTest.text = 'message: ' + userTest.text + '\');';
.replace(/\)/, '');
} else { } else {
userTest.text = test; userTest.text = test;
} }