Patch assert messages without message: format

This commit is contained in:
Berkeley Martinez
2015-12-01 23:24:03 -08:00
parent 636824aba3
commit 8cad219082

View File

@ -51,11 +51,15 @@ window.$(document).ready(function() {
} catch (e) { } catch (e) {
userTest.err = e.message.split(':').shift(); userTest.err = e.message.split(':').shift();
} finally { } finally {
userTest.text = test if (!test.match(/message: /g)) {
userTest.text = 'message: ' + test
.split(',') .split(',')
.pop() .pop()
.replace(/\'/g, '') .replace(/\'/g, '')
.replace(/\)/, ''); .replace(/\)/, '');
} else {
userTest.text = test;
}
} }
return userTest; return userTest;
}) })