refactor(ChandeDetection): Rename ChangeDetectorRef.markForCheck

BREAKING CHANGE

Closes #3403

- ChangeDetectorRef.requestCheck() => ChangeDetectorRef.markForCheck()
This commit is contained in:
Misko Hevery
2015-08-28 10:08:18 -07:00
committed by Miško Hevery
parent b8be4bfaaf
commit cebd670a8e
7 changed files with 13 additions and 14 deletions
@@ -1685,7 +1685,7 @@ class PushCmpWithRef {
return "fixed";
}
propagate() { this.ref.requestCheck(); }
propagate() { this.ref.markForCheck(); }
}
@Component({selector: 'push-cmp-with-async', changeDetection: ChangeDetectionStrategy.OnPush})
@@ -73,7 +73,7 @@ main() {
c.add(3);
flushMicrotasks();
expect(changeDetectorRef.spy("requestCheck")).toHaveBeenCalledOnce();
expect(changeDetectorRef.spy("markForCheck")).toHaveBeenCalledOnce();
}));
it("should return the wrapped value after changing a collection", () {
@@ -91,7 +91,7 @@ export function main() {
ObservableWrapper.callNext(emitter, message);
TimerWrapper.setTimeout(() => {
expect(ref.spy('requestCheck')).toHaveBeenCalled();
expect(ref.spy('markForCheck')).toHaveBeenCalled();
async.done();
}, 0)
}));
@@ -178,7 +178,7 @@ export function main() {
completer.resolve(message);
TimerWrapper.setTimeout(() => {
expect(ref.spy('requestCheck')).toHaveBeenCalled();
expect(ref.spy('markForCheck')).toHaveBeenCalled();
async.done();
}, timer)
}));