My favorites | Sign in
Project Home Downloads Wiki Issues Source
New issue   Search
  Advanced search   Search tips   Subscriptions
Issue 234: AsyncTestCase stalls on failure after CallbackPool.addCallback() called
1 person starred this issue and may be notified of changes. Back to list
Status:  Fixed
Closed:  Apr 2011

Sign in to add a comment
Reported by, Apr 25, 2011
What steps will reproduce the problem?
1. Take the example AsyncTestCase code and add a throw("biscuits!") after a call to callbacks.add (an instance of CallbackPool, and .add is a shortcut for addCallback)

var AsynchronousTest = AsyncTestCase('AsynchronousTest');

AsynchronousTest.prototype.testSomethingComplicated = function(queue) {
  var state = 0;'Step 1: schedule the window to increment our variable 5 seconds from now.', function(callbacks) {
    var myCallback = callbacks.add(function() {
    window.setTimeout(myCallback, 5000);
  });'Step 2: then assert our state variable changed', function() {
    assertEquals(1, state);

What is the expected output? What do you see instead?
EXPECT: instant fail
GET: takes the full 30s to timeout

What version of the product are you using? On what operating system?
jsTD 1.3.2 on Mac OS X 10.5.8, Firefox 4.0

Please provide any additional information below.
This ate a not insignificant amount of my time.

Apr 25, 2011
Notably, the "throw" call fails instantly (as expected) if done before the .add call.

Apr 25, 2011
Project Member #2
(No comment was entered for this change.)
Sign in to add a comment

Powered by Google Project Hosting