1- import { Component , ViewChild , ElementRef } from '@angular/core' ;
1+ import { Component , ViewChild } from '@angular/core' ;
22import { async , TestBed , fakeAsync , tick , ComponentFixture } from '@angular/core/testing' ;
33import { By } from '@angular/platform-browser' ;
44import { BrowserAnimationsModule } from '@angular/platform-browser/animations' ;
@@ -84,13 +84,13 @@ describe('IgxToast', () => {
8484 toast . show ( ) ;
8585
8686 expect ( toast . isVisible ) . toBeTruthy ( ) ;
87- expect ( toast . _animationState ) . toBe ( 'visible' ) ;
87+ expect ( toast . animationState ) . toBe ( 'visible' ) ;
8888 expect ( toast . autoHide ) . toBeTruthy ( ) ;
8989
9090 tick ( 1000 ) ;
9191
9292 expect ( toast . isVisible ) . toBeFalsy ( ) ;
93- expect ( toast . _animationState ) . toBe ( 'invisible' ) ;
93+ expect ( toast . animationState ) . toBe ( 'invisible' ) ;
9494 } ) ) ;
9595
9696 it ( 'should not auto hide after it\'s open' , fakeAsync ( ( ) => {
@@ -100,13 +100,13 @@ describe('IgxToast', () => {
100100 toast . show ( ) ;
101101
102102 expect ( toast . isVisible ) . toBeTruthy ( ) ;
103- expect ( toast . _animationState ) . toBe ( 'visible' ) ;
103+ expect ( toast . animationState ) . toBe ( 'visible' ) ;
104104 expect ( toast . autoHide ) . toBeFalsy ( ) ;
105105
106106 tick ( 1000 ) ;
107107
108108 expect ( toast . isVisible ) . toBeTruthy ( ) ;
109- expect ( toast . _animationState ) . toBe ( 'visible' ) ;
109+ expect ( toast . animationState ) . toBe ( 'visible' ) ;
110110 } ) ) ;
111111
112112 it ( 'visibility is updated by the toggle() method' , ( ) => {
@@ -117,7 +117,7 @@ describe('IgxToast', () => {
117117
118118 toast . show ( ) ;
119119 expect ( toast . isVisible ) . toBe ( true ) ;
120- expect ( toast . _animationState ) . toBe ( 'visible' ) ;
120+ expect ( toast . animationState ) . toBe ( 'visible' ) ;
121121
122122 expect ( toast . onShowing . emit ) . toHaveBeenCalledTimes ( 1 ) ;
123123 expect ( toast . onShown . emit ) . toHaveBeenCalledTimes ( 1 ) ;
@@ -126,12 +126,13 @@ describe('IgxToast', () => {
126126
127127 toast . toggle ( ) ;
128128 expect ( toast . isVisible ) . toBe ( false ) ;
129- expect ( toast . _animationState ) . toBe ( 'invisible' ) ;
129+ expect ( toast . animationState ) . toBe ( 'invisible' ) ;
130130
131131 expect ( toast . onShowing . emit ) . toHaveBeenCalledTimes ( 1 ) ;
132132 expect ( toast . onShown . emit ) . toHaveBeenCalledTimes ( 1 ) ;
133133 expect ( toast . onHiding . emit ) . toHaveBeenCalledTimes ( 1 ) ;
134134 expect ( toast . onHidden . emit ) . toHaveBeenCalledTimes ( 1 ) ;
135+
135136 } ) ;
136137} ) ;
137138
0 commit comments