Bug Tracker

Opened 14 years ago

Closed 13 years ago

#3628 closed enhancement (wontfix)

Module lifecycle doesn't support asynchronous methods (+opera.postError)

Reported by: greut Owned by: joern
Priority: major Milestone: 1.3
Component: qunit Version: 1.2.6
Keywords: qunit, testrunner Cc: greut
Blocked by: Blocking:


Hi, the following test, will not work with the current version of testrunner.js, because setup, callback and test aren't synchronized(see @5847).

module("Asynchronous setup", {
   setup: function() {
        window.global_is_evil = false;
        window.setTimeout(function() {
            window.global_is_evil = true;
        }, 1000);

test("Test after an asynchronous setup", function() {
   ok(window.global_is_evil, true, "Is global evil");

Find this patch that put each one into a sync call and the output takes also benefit of opera.postError (because console isn't supported).

Kind regards,

-- Yoan Blanc

Attachments (1)

testrunner_async_lifecycle.js (2.4 KB) - added by greut 14 years ago.
setup/teardown are synced + opera.postError

Download all attachments as: .zip

Change History (4)

Changed 14 years ago by greut

setup/teardown are synced + opera.postError

comment:1 Changed 14 years ago by greut

ok(window.global_is_evil, true, "Is global evil");

should be:

equals(window.global_is_evil, true, "Is global evil");

comment:2 Changed 14 years ago by flesler

Cc: greut added
Component: unfilledqunit
Owner: changed from flesler to joern

comment:3 Changed 13 years ago by joern

Resolution: wontfix
Status: newclosed

Imporved the error handling in Opera as proposed in r6383.

Asynchronouse calls in lifecycles methods won't be supported.

Note: See TracTickets for help on using tickets.