Skip to content

Commit

Permalink
text(item): adds inputs e2e test
Browse files Browse the repository at this point in the history
  • Loading branch information
manucorporat committed Nov 26, 2016
1 parent 788a7b6 commit d7e1396
Show file tree
Hide file tree
Showing 3 changed files with 107 additions and 0 deletions.
38 changes: 38 additions & 0 deletions src/components/item/test/inputs/app-module.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
import { Component, NgModule } from '@angular/core';
import { IonicApp, IonicModule } from '../../../..';


@Component({
templateUrl: 'main.html'
})
export class E2EPage {
datetime = '2016-12-09';
toggle = true;
select = 'n64';
text = 'Text';
checkbox = true;
range = 10;
}

@Component({
template: '<ion-nav [root]="rootPage"></ion-nav>'
})
export class E2EApp {
rootPage = E2EPage;
}

@NgModule({
declarations: [
E2EApp,
E2EPage
],
imports: [
IonicModule.forRoot(E2EApp)
],
bootstrap: [IonicApp],
entryComponents: [
E2EApp,
E2EPage
]
})
export class AppModule {}
1 change: 1 addition & 0 deletions src/components/item/test/inputs/e2e.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

68 changes: 68 additions & 0 deletions src/components/item/test/inputs/main.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
<ion-header>

<ion-toolbar>
<ion-title>Item inputs</ion-title>
</ion-toolbar>

</ion-header>


<ion-content>
<ion-list>
<ion-item>
Simple item
</ion-item>

<button ion-item>
Item Button
</button>

<ion-item>
<ion-label>DateTime</ion-label>
<ion-datetime [(ngModel)]="datetime" min="1994-03-14" max="2017-12-09" displayFormat="MM/DD/YYYY" required></ion-datetime>
</ion-item>

<ion-item>
<ion-label>Select</ion-label>
<ion-select [(ngModel)]="select">
<ion-option value="nes">NES</ion-option>
<ion-option value="n64">Nintendo64</ion-option>
<ion-option value="ps">PlayStation</ion-option>
<ion-option value="genesis">Sega Genesis</ion-option>
<ion-option value="saturn">Sega Saturn</ion-option>
<ion-option value="snes">SNES</ion-option>
</ion-select>
</ion-item>

<ion-item>
<ion-label>Toggle</ion-label>
<ion-toggle name="Actually" [(ngModel)]="toggle"></ion-toggle>
</ion-item>

<ion-item>
<ion-label>Input (text)</ion-label>
<ion-input [(ngModel)]="text"></ion-input>
</ion-item>

<ion-item>
<ion-label>Input (placeholder)</ion-label>
<ion-input placeholder="Placeholder"></ion-input>
</ion-item>

<ion-item>
<ion-label>Checkbox</ion-label>
<ion-checkbox [(ngModel)]="checkbox"></ion-checkbox>
</ion-item>

<ion-item>
<ion-label>Toggle (left)</ion-label>
<ion-toggle [(ngModel)]="toggle" item-left></ion-toggle>
</ion-item>

<ion-item>
<ion-label>Range</ion-label>
<ion-range [(ngModel)]="range"></ion-range>
</ion-item>
</ion-list>

</ion-content>

0 comments on commit d7e1396

Please sign in to comment.