@@ -145,13 +145,15 @@ describe('LIVECHAT - rooms', () => {
145145 } ) ;
146146 ( IS_EE ? it : it . skip ) ( 'should prevent create a room for visitor if an app throws an error' , async ( ) => {
147147 // this test relies on the app installed by the insertApp fixture
148+ // TODO: this visitor should be created on before block and deleted on after block
148149 const visitor = await createVisitor ( undefined , 'visitor prevent from app' ) ;
149150 const { body } = await request . get ( api ( 'livechat/room' ) ) . query ( { token : visitor . token } ) ;
150151
151152 expect ( body ) . to . have . property ( 'success' , false ) ;
152153 await deleteVisitor ( visitor . token ) ;
153154 } ) ;
154155 it ( 'should create a room for visitor' , async ( ) => {
156+ // TODO: this visitor should be created on before block and deleted on after block
155157 const visitor = await createVisitor ( ) ;
156158 const { body } = await request . get ( api ( 'livechat/room' ) ) . query ( { token : visitor . token } ) ;
157159
@@ -164,6 +166,7 @@ describe('LIVECHAT - rooms', () => {
164166 await deleteVisitor ( visitor . token ) ;
165167 } ) ;
166168 it ( 'should return an existing open room when visitor has one available' , async ( ) => {
169+ // TODO: this visitor should be created on before block and deleted on after block
167170 const visitor = await createVisitor ( ) ;
168171 const { body } = await request . get ( api ( 'livechat/room' ) ) . query ( { token : visitor . token } ) ;
169172
@@ -182,6 +185,7 @@ describe('LIVECHAT - rooms', () => {
182185 await deleteVisitor ( visitor . token ) ;
183186 } ) ;
184187 it ( 'should return a room for the visitor when rid points to a valid open room' , async ( ) => {
188+ // TODO: this visitor should be created on before block and deleted on after block
185189 const visitor = await createVisitor ( ) ;
186190 const room = await createLivechatRoom ( visitor . token ) ;
187191 const { body } = await request . get ( api ( 'livechat/room' ) ) . query ( { token : visitor . token , rid : room . _id } ) ;
@@ -194,6 +198,7 @@ describe('LIVECHAT - rooms', () => {
194198 await deleteVisitor ( visitor . token ) ;
195199 } ) ;
196200 it ( 'should properly read widget cookies' , async ( ) => {
201+ // TODO: this visitor should be created on before block and deleted on after block
197202 const visitor = await createVisitor ( ) ;
198203 const { body } = await request
199204 . get ( api ( 'livechat/room' ) )
0 commit comments