File tree Expand file tree Collapse file tree
src/components/modal/test/basic Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -77,6 +77,22 @@ export class E2EPage {
7777 }
7878
7979 presentModalChildNav ( ) {
80+ this . modalCtrl . create ( ContactUs ) . present ( ) ;
81+ }
82+
83+ presentToolbarModal ( ) {
84+ this . modalCtrl . create ( ToolbarModal ) . present ( ) ;
85+ }
86+
87+ presentModalWithInputs ( ) {
88+ let modal = this . modalCtrl . create ( ModalWithInputs ) ;
89+ modal . onDidDismiss ( ( data : any ) => {
90+ console . log ( 'Modal with inputs data:' , data ) ;
91+ } ) ;
92+ modal . present ( ) ;
93+ }
94+
95+ presentNavModalWithToast ( ) {
8096 this . toastCtrl . create ( {
8197 message : 'Will present a modal with child nav...' ,
8298 duration : 1000 ,
@@ -87,7 +103,7 @@ export class E2EPage {
87103 } , 500 ) ;
88104 }
89105
90- presentToolbarModal ( ) {
106+ presentToolbarModalWithToast ( ) {
91107 this . toastCtrl . create ( {
92108 message : 'Will present a modal with toolbars...' ,
93109 duration : 1000 ,
@@ -98,14 +114,6 @@ export class E2EPage {
98114 } , 500 ) ;
99115 }
100116
101- presentModalWithInputs ( ) {
102- let modal = this . modalCtrl . create ( ModalWithInputs ) ;
103- modal . onDidDismiss ( ( data : any ) => {
104- console . log ( 'Modal with inputs data:' , data ) ;
105- } ) ;
106- modal . present ( ) ;
107- }
108-
109117 ionViewDidLoad ( ) {
110118 console . log ( 'E2EPage ionViewDidLoad fired' ) ;
111119 }
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ it('should open modal', function() {
44} ) ;
55
66it ( 'should close alert with button click' , function ( ) {
7- element ( by . css ( '.alert-button:last-child ' ) ) . click ( ) ;
7+ element ( by . css ( '.alert-button' ) ) . click ( ) ;
88} ) ;
99
1010it ( 'should close with close button click' , function ( ) {
@@ -16,7 +16,7 @@ it('should open toolbar modal', function() {
1616} ) ;
1717
1818it ( 'should close alert with button click' , function ( ) {
19- element ( by . css ( '.alert-button:last-child ' ) ) . click ( ) ;
19+ element ( by . css ( '.alert-button' ) ) . click ( ) ;
2020} ) ;
2121
2222it ( 'should close toolbar modal' , function ( ) {
Original file line number Diff line number Diff line change 2121 < p >
2222 < button ion-button (click) ="presentModalWithInputs() "> Present modal w/ inputs</ button >
2323 </ p >
24+ < p >
25+ < button ion-button (click) ="presentNavModalWithToast() "> Present toast then child ion-nav modal</ button >
26+ </ p >
27+ < p >
28+ < button ion-button (click) ="presentToolbarModalWithToast() "> Present toast then toolbar modal</ button >
29+ </ p >
2430 < p >
2531 {{platforms | json}}
2632 </ p >
You can’t perform that action at this time.
0 commit comments