}
}
-function stop() {
+function stop(allowFailure) {
_config.blocking = true;
- _config.timeout = setTimeout(start, _config.asyncTimeout * 1000);
+ var handler = allowFailure ? start : function() {
+ ok( false, "Test timed out" );
+ start();
+ };
+ _config.timeout = setTimeout(handler, _config.asyncTimeout * 1000);
}
function start() {
if(_config.timeout)
for ( var i = 0; i < f.length; i++ )
s += (s && ",") + '"' + f[i].id + '"';
isSet(f, q.apply(q,c), a + " (" + b + ")");
+}
+
+/**
+ * Add random number to url to stop IE from caching
+ *
+ * @example url("data/test.html")
+ * @result "data/test.html?10538358428943"
+ *
+ * @example url("data/test.php?foo=bar")
+ * @result "data/test.php?foo=bar&10538358345554"
+ */
+function url(value) {
+ return value + (/\?/.test(value) ? "&" : "?") + new Date().getTime() + "" + parseInt(Math.random()*100000);
}
\ No newline at end of file