Skip to content

Commit

Permalink
Used [symbolAttrName] instead of set() per David H
Browse files Browse the repository at this point in the history
  • Loading branch information
Larry Yu committed Jun 14, 2022
1 parent 4a1a066 commit 9ca404f
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/unit/model/symbol-intercept-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ module('unit/model/symbol-intercept', function (hooks) {
schemaInterface.setAttr('title', value);
}
}
// useNativeProperties() {
// return true;
// }
}
this.owner.register('service:m3-schema', TestSchema);

Expand All @@ -35,8 +38,8 @@ module('unit/model/symbol-intercept', function (hooks) {
let book = this.store.peekRecord('com.example.bookstore.Book', 'urn:li:book:1');

const mySymbol = Symbol('mySymbol');
book.set(mySymbol, book.id);
book[mySymbol] = book.id;

assert.equal(book.get(mySymbol), 'urn:li:book:1', 'Reading a symbol attribute should work');
assert.equal(book[mySymbol], 'urn:li:book:1', 'Reading a symbol attribute should work');
});
});

0 comments on commit 9ca404f

Please sign in to comment.