vendredi 23 janvier 2015

Running 2 asychronous ember tests in the same test method

how do I run this in the same test? Right now I need to run them separately.



test('Props tests', function () {

var controller = this.subject({
model: createMock()
});

controller.set('foo', false);
controller.set('foo2', false);
equal(controller.get('baa'), true);

});


test('Props tests', function () {

var controller = this.subject({
model: createMock()
});

controller.set('foo', true);
controller.set('foo2', true);
equal(controller.get('baa2'), true);

});


I think I need to wrap some code in an Ember.run function statement.





Aucun commentaire:

Enregistrer un commentaire