Fixed test_NavigateToNewPage_WithAndroidCache failure on Android API level 17

Unit tests re-factoring and improvements
This commit is contained in:
Rossen Hristov
2016-05-26 17:03:19 +03:00
parent 55ed1fd2f1
commit 719ce1e33e
8 changed files with 102 additions and 142 deletions

View File

@@ -494,6 +494,9 @@ class AndroidFrame extends Observable implements definition.AndroidFrame {
public set cachePagesOnNavigate(value: boolean) {
if (this._cachePagesOnNavigate !== value) {
if (this._owner.backStack.length > 0) {
this._owner._printFrameBackStack();
this._owner._printNativeBackStack();
console.log(`currentPage: ${this._owner.currentPage}`);
throw new Error("Cannot set cachePagesOnNavigate if there are items in the back stack.");
}