Last active
December 12, 2015 07:18
-
-
Save ritchiea/4735460 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*global jQuery */ | |
module("Ember.meta"); | |
// test fix for https://github.com/emberjs/ember.js/issues/1884 | |
test("should not set META_KEY on destroyed objects", function() { | |
var obj = Ember.Object.create({}); | |
ok(!Ember.meta(obj).bar, "precond - bar property on meta does not exist"); | |
obj.destroy(); | |
Ember.meta(obj).bar = "baz"; | |
equal(Ember.meta(obj).bar, undefined, "bar property key cannot be set for destroyed object"); | |
}); | |
... and the error | |
~/code/libraries/ember.js/packages:master$ rake test[ember-metal] | |
(in /Users/andrewritchie/code/libraries/ember.js) | |
/Users/andrewritchie/code/libraries/ember.js/Rakefile:6: warning: already initialized constant EMBER_VERSION | |
Building Ember... | |
Done | |
Running: {"package":"ember-metal"} | |
.......................................................................................................................................................................................................................................................................................................F............................................... | |
Module Failed: Ember.meta | |
Test Failed: should not set META_KEY on destroyed objects | |
Assertion Failed: Died on test #1 at http://localhost:9999/qunit/qunit.js:411 | |
at :22 | |
at :87: 'undefined' is not an object (evaluating 'Ember.Object.create') | |
Time: 1424ms, Total: 973, Passed: 972, Failed: 1 | |
Tests Failed |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment