mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-20 12:29:55 +08:00
chore(e2e): update tests to remove component name strings
This commit is contained in:
@ -183,9 +183,7 @@ export function runAppScripts(folderInfo: any, sassConfigPath: string, appEntryP
|
|||||||
let tsConfig = distDir + 'tsconfig.json';
|
let tsConfig = distDir + 'tsconfig.json';
|
||||||
let scriptArgs = [
|
let scriptArgs = [
|
||||||
'build',
|
'build',
|
||||||
'--aot',
|
'--prod',
|
||||||
'--minifyCss',
|
|
||||||
'--optimizeJs',
|
|
||||||
'--sass', sassConfigPath,
|
'--sass', sassConfigPath,
|
||||||
'--appEntryPoint', appEntryPoint,
|
'--appEntryPoint', appEntryPoint,
|
||||||
'--srcDir', distDir,
|
'--srcDir', distDir,
|
||||||
|
@ -62,9 +62,9 @@ export class MyCmpTest {
|
|||||||
<ion-label>Text Input</ion-label>
|
<ion-label>Text Input</ion-label>
|
||||||
<ion-textarea></ion-textarea>
|
<ion-textarea></ion-textarea>
|
||||||
</ion-item>
|
</ion-item>
|
||||||
<button ion-item navPush="FullPage">Push FullPage w/ navPush="FullPage"</button>
|
<button ion-item [navPush]="pushPage">Push FullPage w/ [navPush]="pushPage"</button>
|
||||||
<button ion-item [navPush]="pushPage" [navParams]="{id:40}">Push w/ [navPush] and [navParams]</button>
|
<button ion-item [navPush]="pushPage" [navParams]="{id:40}">Push w/ [navPush] and [navParams]</button>
|
||||||
<button ion-item [navPush]="'FirstPage'">Push w/ [navPush] and string view name</button>
|
<button ion-item [navPush]="firstPage">Push w/ [navPush] and firstPage</button>
|
||||||
<button ion-item (click)="setPages()">setPages() (Go to PrimaryHeaderPage)</button>
|
<button ion-item (click)="setPages()">setPages() (Go to PrimaryHeaderPage)</button>
|
||||||
<button ion-item (click)="setRoot()">setRoot(PrimaryHeaderPage) (Go to PrimaryHeaderPage)</button>
|
<button ion-item (click)="setRoot()">setRoot(PrimaryHeaderPage) (Go to PrimaryHeaderPage)</button>
|
||||||
<button ion-item (click)="pop()">Pop</button>
|
<button ion-item (click)="pop()">Pop</button>
|
||||||
@ -84,6 +84,7 @@ export class MyCmpTest {
|
|||||||
})
|
})
|
||||||
export class FirstPage {
|
export class FirstPage {
|
||||||
pushPage = FullPage;
|
pushPage = FullPage;
|
||||||
|
firstPage = FirstPage;
|
||||||
title = 'First Page';
|
title = 'First Page';
|
||||||
pages: Array<number> = [];
|
pages: Array<number> = [];
|
||||||
@ViewChild(Content) content: Content;
|
@ViewChild(Content) content: Content;
|
||||||
|
@ -1,12 +1,14 @@
|
|||||||
import { Component, NgModule, ViewChild } from '@angular/core';
|
import { Component, NgModule, ViewChild } from '@angular/core';
|
||||||
import { /*DeepLink,*/AlertController, DeepLinkConfig, IonicApp, IonicModule, App, NavController, NavParams, ModalController, ViewController, Tabs, Tab } from '../../../../../ionic-angular';
|
import { AlertController, DeepLinkConfig, IonicApp, IonicModule, App, NavController, NavParams, ModalController, ViewController, Tabs, Tab } from '../../../../../ionic-angular';
|
||||||
|
|
||||||
|
|
||||||
// @DeepLink({ name: 'sign-in' })
|
// @DeepLink({ name: 'sign-in' })
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: './signIn.html'
|
templateUrl: './signIn.html'
|
||||||
})
|
})
|
||||||
export class SignIn {}
|
export class SignIn {
|
||||||
|
tabsPage = TabsPage;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
@ -32,6 +34,9 @@ export class ChatPage {
|
|||||||
})
|
})
|
||||||
export class TabsPage {
|
export class TabsPage {
|
||||||
showTab: boolean = false;
|
showTab: boolean = false;
|
||||||
|
rootPage1 = Tab1Page1;
|
||||||
|
rootPage2 = Tab2Page1;
|
||||||
|
rootPage3 = Tab3Page1;
|
||||||
|
|
||||||
@ViewChild(Tabs) tabs: Tabs;
|
@ViewChild(Tabs) tabs: Tabs;
|
||||||
|
|
||||||
@ -125,6 +130,7 @@ export class TabsPage {
|
|||||||
templateUrl: './tab1page1.html'
|
templateUrl: './tab1page1.html'
|
||||||
})
|
})
|
||||||
export class Tab1Page1 {
|
export class Tab1Page1 {
|
||||||
|
tab1Page2 = Tab1Page2;
|
||||||
color: boolean;
|
color: boolean;
|
||||||
userId: string;
|
userId: string;
|
||||||
|
|
||||||
@ -176,6 +182,8 @@ export class Tab1Page1 {
|
|||||||
templateUrl: './tab1page2.html'
|
templateUrl: './tab1page2.html'
|
||||||
})
|
})
|
||||||
export class Tab1Page2 {
|
export class Tab1Page2 {
|
||||||
|
tab1Page3 = Tab1Page3;
|
||||||
|
|
||||||
constructor(public tabs: Tabs) { }
|
constructor(public tabs: Tabs) { }
|
||||||
|
|
||||||
favoritesTab() {
|
favoritesTab() {
|
||||||
@ -243,6 +251,7 @@ export class Tab1Page3 {
|
|||||||
templateUrl: './tab2page1.html'
|
templateUrl: './tab2page1.html'
|
||||||
})
|
})
|
||||||
export class Tab2Page1 {
|
export class Tab2Page1 {
|
||||||
|
tab2Page2 = Tab2Page2;
|
||||||
|
|
||||||
ionViewWillEnter() {
|
ionViewWillEnter() {
|
||||||
console.log('Tab2Page1, ionViewWillEnter');
|
console.log('Tab2Page1, ionViewWillEnter');
|
||||||
@ -271,6 +280,7 @@ export class Tab2Page1 {
|
|||||||
templateUrl: './tab2page2.html'
|
templateUrl: './tab2page2.html'
|
||||||
})
|
})
|
||||||
export class Tab2Page2 {
|
export class Tab2Page2 {
|
||||||
|
tab2Page3 = Tab2Page3;
|
||||||
|
|
||||||
ionViewWillEnter() {
|
ionViewWillEnter() {
|
||||||
console.log('Tab2Page2, ionViewWillEnter');
|
console.log('Tab2Page2, ionViewWillEnter');
|
||||||
|
@ -19,12 +19,12 @@
|
|||||||
<ion-input type="password"></ion-input>
|
<ion-input type="password"></ion-input>
|
||||||
</ion-item>
|
</ion-item>
|
||||||
<ion-item>
|
<ion-item>
|
||||||
<a ion-button block navPush="TabsPage" class="e2eSignIn">Sign In</a>
|
<a ion-button block [navPush]="tabsPage" class="e2eSignIn">Sign In</a>
|
||||||
</ion-item>
|
</ion-item>
|
||||||
</ion-card>
|
</ion-card>
|
||||||
|
|
||||||
<p style="text-align: center;">
|
<p style="text-align: center;">
|
||||||
<a navPush="TabsPage">View Tabs Page</a>
|
<a [navPush]="tabsPage">View Tabs Page</a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
</ion-content>
|
</ion-content>
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
<ion-content padding>
|
<ion-content padding>
|
||||||
|
|
||||||
<p><button ion-button class="e2eGoToTab1Page2" navPush="Tab1Page2">Go to Tab 1, Page 2</button></p>
|
<p><button ion-button class="e2eGoToTab1Page2" [navPush]="tab1Page2">Go to Tab 1, Page 2</button></p>
|
||||||
<p><button ion-button (click)="logout()">Logout</button></p>
|
<p><button ion-button (click)="logout()">Logout</button></p>
|
||||||
<p><button ion-button (click)="favoritesTab()">Favorites Tab</button></p>
|
<p><button ion-button (click)="favoritesTab()">Favorites Tab</button></p>
|
||||||
<p><button ion-button (click)="goBack()">Go Back</button></p>
|
<p><button ion-button (click)="goBack()">Go Back</button></p>
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
<ion-content padding>
|
<ion-content padding>
|
||||||
|
|
||||||
<p><button ion-button navPush="Tab1Page3">Go to Tab 1, Page 3</button></p>
|
<p><button ion-button [navPush]="tab1Page3">Go to Tab 1, Page 3</button></p>
|
||||||
<p><button ion-button (click)="favoritesTab()">Favorites Tab</button></p>
|
<p><button ion-button (click)="favoritesTab()">Favorites Tab</button></p>
|
||||||
<p><button ion-button class="e2eBackToTab1Page1" navPop>Back to Tab 1, Page 1</button></p>
|
<p><button ion-button class="e2eBackToTab1Page1" navPop>Back to Tab 1, Page 1</button></p>
|
||||||
<div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div>
|
<div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div>
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
<ion-content padding>
|
<ion-content padding>
|
||||||
|
|
||||||
<p><button ion-button navPush="Tab2Page2">Go to Tab 2, Page 2</button></p>
|
<p><button ion-button [navPush]="tab2Page2">Go to Tab 2, Page 2</button></p>
|
||||||
<div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div>
|
<div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div>
|
||||||
<div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div>
|
<div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div>
|
||||||
|
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
<ion-content padding>
|
<ion-content padding>
|
||||||
|
|
||||||
<p><button ion-button navPush="Tab2Page3">Go to Tab 2, Page 3 (no navbar)</button></p>
|
<p><button ion-button [navPush]="tab2Page3">Go to Tab 2, Page 3 (no navbar)</button></p>
|
||||||
<p><button ion-button navPop>Back to Tab 2, Page 1</button></p>
|
<p><button ion-button navPop>Back to Tab 2, Page 1</button></p>
|
||||||
<div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div>
|
<div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div>
|
||||||
<div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div>
|
<div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div><div f></div>
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
|
|
||||||
<ion-tabs preloadTabs="false" (ionChange)="onTabChange($event)">
|
<ion-tabs preloadTabs="false" (ionChange)="onTabChange($event)">
|
||||||
<ion-tab tabTitle="Recents" tabIcon="call" root="Tab1Page1" swipeBackEnabled="true"></ion-tab>
|
<ion-tab tabTitle="Recents" tabIcon="call" [root]="rootPage1" swipeBackEnabled="true"></ion-tab>
|
||||||
<ion-tab tabTitle="Favorites" tabIcon="star" root="Tab2Page1" tabsHideOnSubPages="false"></ion-tab>
|
<ion-tab tabTitle="Favorites" tabIcon="star" [root]="rootPage2" tabsHideOnSubPages="false"></ion-tab>
|
||||||
<ion-tab tabTitle="Settings" tabIcon="settings" root="Tab3Page1"></ion-tab>
|
<ion-tab tabTitle="Settings" tabIcon="settings" [root]="rootPage3"></ion-tab>
|
||||||
<ion-tab tabTitle="Chat" tabIcon="chatbubbles" (ionSelect)="chat()" [show]="showTab"></ion-tab>
|
<ion-tab tabTitle="Chat" tabIcon="chatbubbles" (ionSelect)="chat()" [show]="showTab"></ion-tab>
|
||||||
<ion-tab tabTitle="Logout" tabIcon="exit" (ionSelect)="logout()"></ion-tab>
|
<ion-tab tabTitle="Logout" tabIcon="exit" (ionSelect)="logout()"></ion-tab>
|
||||||
</ion-tabs>
|
</ion-tabs>
|
||||||
|
Reference in New Issue
Block a user