File tree Expand file tree Collapse file tree 4 files changed +10
-10
lines changed
Expand file tree Collapse file tree 4 files changed +10
-10
lines changed Original file line number Diff line number Diff line change 11const request = require ( './request-service' ) ;
22
33describe ( 'exit from server' , ( ) => {
4- it ( 'Should be exit' , async ( ) => {
4+ it ( 'Should be exit' , async ( ) => {
55 await request ( 'http://localhost:4000/test/exit' ) ;
66 } ) ;
77} ) ;
Original file line number Diff line number Diff line change 1- const expect = require ( 'chai' ) ;
1+ const page = '/home' ;
2+ const chai = require ( 'chai' ) ;
23const request = require ( './request-service' ) ;
34let body : string ;
4- const page = '/home' ;
55const url = `http://localhost:4000${ page } ` ;
66
77describe ( `test work ${ page } with ssr` , ( ) => {
88 it ( 'Should be exist "Главная страница"' , async ( ) => {
99 body = await request ( url ) ;
10- return expect ( body . includes ( 'Главная страница' ) ) . to . equal ( true ) ;
10+ return chai . expect ( body . includes ( 'Главная страница' ) ) . to . equal ( true ) ;
1111 } ) ;
1212
1313 it ( 'Should be exist "home.notranslatewarn"' , async ( ) => {
1414 body = await request ( url ) ;
15- expect ( body . includes ( 'home.notranslatewarn' ) ) . to . equal ( true ) ;
15+ chai . expect ( body . includes ( 'home.notranslatewarn' ) ) . to . equal ( true ) ;
1616 } ) ;
1717} ) ;
Original file line number Diff line number Diff line change 1- const expect = require ( 'chai' ) ;
1+ const page = '/mock' ;
2+ const chai = require ( 'chai' ) ;
23const request = require ( './request-service' ) ;
34let body : string ;
4- const page = '/mock' ;
55const url = `http://localhost:4000${ page } ` ;
66
77describe ( `test work ${ page } with ssr` , ( ) => {
8+
89 it ( 'Should be exist "Страница с мокапом"' , async ( ) => {
910 body = await request ( url ) ;
10- return expect ( body . includes ( 'Страница с мокапом' ) ) . to . equal ( true ) ;
11+ return chai . expect ( body . includes ( 'Страница с мокапом' ) ) . to . equal ( true ) ;
1112 } ) ;
1213
1314 it ( 'Should be exist "mock-server works"' , async ( ) => {
1415 body = await request ( url ) ;
15- expect ( body . includes ( 'mock-server works' ) ) . to . equal ( true ) ;
16+ chai . expect ( body . includes ( 'mock-server works' ) ) . to . equal ( true ) ;
1617 } ) ;
1718} ) ;
Original file line number Diff line number Diff line change 11const expect = require ( 'chai' ) ;
2-
32const request = require ( './request-service' ) ;
43let body : string ;
54const page = '/back' ;
You can’t perform that action at this time.
0 commit comments