chore: 🤖 add sessions property to target
This commit is contained in:
4 files changed
+86
-2
No files matched your search
@@ -27,6 +27,28 @@ module('Unit | Model | session', function(hooks) {
|
||||
assert.ok(model.isCancelable);
|
||||
});
|
||||
|
||||
test('it computes isActive', function (assert) {
|
||||
assert.expect(2);
|
||||
let store = this.owner.lookup('service:store');
|
||||
let model = store.createRecord('session', {
|
||||
status: 'pending'
|
||||
});
|
||||
assert.notOk(model.isActive);
|
||||
model.status = 'active';
|
||||
assert.ok(model.isActive);
|
||||
});
|
||||
|
||||
test('it computes isPending', function (assert) {
|
||||
assert.expect(2);
|
||||
let store = this.owner.lookup('service:store');
|
||||
let model = store.createRecord('session', {
|
||||
status: 'active'
|
||||
});
|
||||
assert.notOk(model.isPending);
|
||||
model.status = 'pending';
|
||||
assert.ok(model.isPending);
|
||||
});
|
||||
|
||||
test('it computes a proxy attribute', function (assert) {
|
||||
let store = this.owner.lookup('service:store');
|
||||
let model = store.createRecord('session');
|
||||
|
||||
Reference in new issue
Block a user