Bump a delay on test runs and show pattern for expect tests

This commit is contained in:
terakilobyte
2015-06-06 23:58:27 -04:00
parent 00ac753063
commit 7cfca0b5f8
2 changed files with 20 additions and 20 deletions

View File

@ -3,6 +3,7 @@
var tests = parent.tests;
var editor = parent.editorValueForIFrame;
setTimeout(function() {
for (var i = 0; i < tests.length; i++) {
var thisTest = true;
try {
@ -13,8 +14,10 @@
parent.postError(JSON.stringify(err.message.split(':').shift()));
} finally {
if (thisTest) {
parent.postSuccess(JSON.stringify(tests[i].split(',').pop().replace(/\'/g, '').replace(/\)/, '')));
parent.postSuccess(JSON.stringify(tests[i].split(',').pop().replace(
/\'/g, '').replace(/\)/, '')));
}
}
}
}, 250);
})();

View File

@ -1,8 +1,7 @@
{
"name": "jQuery, Ajax and JSON",
"order" : 0.004,
"challenges": [
{
"order": 0.004,
"challenges": [{
"_id": "bad87fee1348bd9acdd08826",
"name": "Waypoint: Learn how Script Tags and Document Ready Work",
"difficulty": 0.072,
@ -54,7 +53,7 @@
"Make all <code>img</code> elements bounce $('img').addClass('animated bounce')"
],
"tests": [
"expect($('img'), 'Make sure you add the animated bounce class').to.have.class('animated bounce')"
],
"challengeSeed": [
"fccss",
@ -483,8 +482,7 @@
],
"challengeType": 0
},
{
}, {
"_id": "bad87fee1348bd9aede08826",
"name": "Waypoint: Use Hex Codes for Precise Colors",
"difficulty": 0.071,
@ -498,8 +496,7 @@
],
"challengeType": 0
},
{
}, {
"_id": "bad87fee1348bd9aedd08826",
"name": "Waypoint: Use Shortened Hex Codes for Colors",
"difficulty": 0.071,