diff --git a/CHANGELOG b/CHANGELOG index 64cc945..69dbad7 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,7 @@ +* Instanciate Test.Unit.Logger on window load. [Tobie Langel] + +* Unit tests clean-up. [Tobie Langel] + * Refactor String#escapeHTML to avoid using the `with` statement. [Tobie Langel] * Remove usage of the `with` statement from unit tests. [Tobie Langel] diff --git a/test/lib/unittest.js b/test/lib/unittest.js index 0e0fb36..e32617b 100644 --- a/test/lib/unittest.js +++ b/test/lib/unittest.js @@ -155,12 +155,12 @@ Test.Unit.Runner = Class.create({ }, arguments[1] || {}); options.resultsURL = this.queryParams.resultsURL; - options.testLog = $(options.testLog); this.tests = this.getTests(testcases); this.currentTest = 0; - this.logger = new Test.Unit.Logger(options.testLog); + Event.observe(window, "load", function() { + this.logger = new Test.Unit.Logger($(options.testLog)); this.runTests.bind(this).delay(0.1); }.bind(this)); },