Skip to main content

Bug Tracker

Side navigation

#4959 closed bug (invalid)

Opened July 23, 2009 04:04PM UTC

Closed August 14, 2009 03:38PM UTC

[QUnit] Module Bug

Reported by: dotnetCarpenter Owned by: joern
Priority: major Milestone: 1.4
Component: qunit Version: 1.3.2
Keywords: module Cc: joern.zaefferer@googlemail.com
Blocked by: Blocking:
Description

When assigning variables and functions to this in setup or teardown, it is impossible to access them in tests as they are always 'undefined'.

In the test case I have made a simple object that contains a private array. When using module(name, {options}) all tests fails but if you uncomment the 'this works!' section all tests pass and comment the module section. Interesting stuff happens when you uncomment both, but I haven't had time to explore what actually happens.

For simplicity this refers to document when not using module.

Attachments (1)
  • moduleBug.htm (2.4 KB) - added by dotnetCarpenter July 23, 2009 04:05PM UTC.

    test case that shows the module setup/teardown bug

Change History (2)

Changed July 23, 2009 08:02PM UTC by dotnetCarpenter comment:1

Last line should have been:

For simplicity this refers to ~~document~~

window
when not using module.

Changed August 14, 2009 03:38PM UTC by joern comment:2

resolution: → invalid
status: newclosed

QUnit works fine. You were using an old version of QUnit which didn't support the extended modules.

Really not your fault: The project still doesn't have a proper release to which I could refer you, and the documentation referred to an out-of-date mirror. Currently the most current file is here: http://jqueryjs.googlecode.com/svn/trunk/qunit/testrunner.js