fix(facade): change EventEmitter to be sync by default (#8761)

This commit is contained in:
Rob Wormald
2016-05-26 09:34:04 -07:00
committed by Miško Hevery
parent cf1122cf9e
commit e5904f4089
5 changed files with 31 additions and 36 deletions

View File

@ -193,19 +193,11 @@ export function main() {
expect(multiTrim(document.body.textContent))
.toEqual(
"ignore: -; " + "literal: Text; interpolate: Hello world; " +
"oneWayA: A; oneWayB: B; twoWayA: initModelA; twoWayB: initModelB; (1) | " +
"modelA: initModelA; modelB: initModelB; eventA: ?; eventB: ?;");
setTimeout(() => {
// we need to do setTimeout, because the EventEmitter uses setTimeout to schedule
// events, and so without this we would not see the events processed.
expect(multiTrim(document.body.textContent))
.toEqual("ignore: -; " + "literal: Text; interpolate: Hello world; " +
"oneWayA: A; oneWayB: B; twoWayA: newA; twoWayB: newB; (3) | " +
"modelA: newA; modelB: newB; eventA: aFired; eventB: bFired;");
ref.dispose();
async.done();
});
});
"oneWayA: A; oneWayB: B; twoWayA: newA; twoWayB: newB; (2) | " +
"modelA: newA; modelB: newB; eventA: aFired; eventB: bFired;")
ref.dispose();
async.done();
});
}));