Opened 6 years ago

Closed 5 years ago

Last modified 5 years ago

#18809 closed defect (fixed)

[Regression] In 1.10 branch test of dojo/_base/lang fails in all browsers.

Reported by: Clement Mathieu Owned by:
Priority: undecided Milestone: 1.10.8
Component: Testing Version: 1.10.5
Keywords: Cc:
Blocked By: Blocking:


I ran dojo core doh tests against the 1.10 branch. The test tests._base.lang::getObject is failing on Firefox 38 ESR, Chrome 48 and IE 11.

Here is the log I got:

_AssertFailure: http://localhost/dev/dojo/dojo.js line 345 > Function line 1 > eval:47 assertEqual() failed:
		[object Window]
	but got

	(function getObject(t){
		var test = {
			foo : {}
		t.assertEqual(, lang.getObject("foo", false, test), 'lang.getObject("foo", false, test)');
		t.assertEqual("undefined", typeof lang.getObject("", false, test), // don't create
			'typeof lang.getObject("", false, test)');
		t.assertEqual({}, lang.getObject("", true, test),  // do create
			'lang.getObject("", true, test)'); = "test";
		t.assertEqual(, lang.getObject("", false, test),
			'lang.getObject("", false, test)');

		// global tests
		t.assertEqual("undefined", typeof lang.getObject("", false),	// don't create
			'typeof lang.getObject("", false)'); = {};
		t.assertEqual(, lang.getObject("_getObjectTest", false), // don't create
			'lang.getObject("_getObjectTest", false)');
		t.assertEqual({}, lang.getObject("", true), 'lang.getObject("", true)'); // do create

		// strangely, parser does this
		t.assertEqual("undefined", typeof lang.getObject("./TestWidget"), 'typeof lang.getObject("./TestWidget")');

		// empty path should return the same object
		t.assertEqual(test, lang.getObject("", false, test));
		t.assertEqual(, lang.getObject(""));

Change History (7)

comment:1 Changed 5 years ago by dylan

Status: newpending

I don't think this is failing the comparable Intern test however.... perhaps due to an API update?

comment:2 Changed 5 years ago by dylan

Milestone: tbd1.12
Status: pendingnew

comment:3 Changed 5 years ago by dylan

Version: 1.11.0-rc41.10.5

comment:4 Changed 5 years ago by dylan


comment:5 Changed 5 years ago by jroufa

Pull request submitted here:

I updated the assertions within the getObject test in the lang suite so that they match up against the latest assertions in the Intern-based unit tests from 1.12. This suite is passing again. Please let me know if you have any further questions!

comment:6 Changed 5 years ago by dylan

Component: GeneralTesting
Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.