File tree 2 files changed +16
-24
lines changed
e2e-tests/development-runtime/cypress/integration/eslint-rules
2 files changed +16
-24
lines changed Original file line number Diff line number Diff line change 1
1
describe ( `limited-exports-page-templates` , ( ) => {
2
- // Skipped because HMR not show warnings because of https://github.com/webpack-contrib/webpack-hot-middleware/pull/397
3
- it . skip ( `should log warning to console for invalid export` , ( ) => {
4
- cy . visit ( `/eslint-rules/limited-exports-page-templates` , {
5
- onBeforeLoad ( win ) {
6
- cy . stub ( win . console , "log" ) . as ( `consoleLog` )
7
- } ,
8
- } ) . waitForRouteChange ( )
2
+ it ( `should log warning to console for invalid export` , ( ) => {
3
+ cy . visit (
4
+ `/eslint-rules/limited-exports-page-templates`
5
+ ) . waitForRouteChange ( )
9
6
10
- cy . get ( `@consoleLog ` ) . should (
7
+ cy . get ( `@hmrConsoleLog ` ) . should (
11
8
`be.calledWithMatch` ,
12
9
/ 1 5 : 1 w a r n i n g I n p a g e t e m p l a t e s o n l y a d e f a u l t e x p o r t o f a v a l i d R e a c t c o m p o n e n t a n d t h e n a m e d e x p o r t o f a p a g e q u e r y i s a l l o w e d ./ i
13
10
)
14
- cy . get ( `@consoleLog ` ) . should (
11
+ cy . get ( `@hmrConsoleLog ` ) . should (
15
12
`not.be.calledWithMatch` ,
16
13
/ 1 7 : 1 w a r n i n g I n p a g e t e m p l a t e s o n l y a d e f a u l t e x p o r t o f a v a l i d R e a c t c o m p o n e n t a n d t h e n a m e d e x p o r t o f a p a g e q u e r y i s a l l o w e d ./ i
17
14
)
Original file line number Diff line number Diff line change 1
1
describe ( `no-anonymous-exports-page-templates` , ( ) => {
2
- // Skipped because HMR not show warnings because of https://github.com/webpack-contrib/webpack-hot-middleware/pull/397
3
- it . skip ( `should log warning to console for arrow functions` , ( ) => {
4
- cy . visit ( `/eslint-rules/no-anonymous-exports-page-templates` , {
5
- onBeforeLoad ( win ) {
6
- cy . stub ( win . console , "log" ) . as ( `consoleLog` )
7
- } ,
8
- } ) . waitForRouteChange ( )
2
+ it ( `should log warning to console for arrow functions` , ( ) => {
3
+ cy . visit (
4
+ `/eslint-rules/no-anonymous-exports-page-templates`
5
+ ) . waitForRouteChange ( )
9
6
10
- cy . get ( `@consoleLog ` ) . should (
7
+ cy . get ( `@hmrConsoleLog ` ) . should (
11
8
`be.calledWithMatch` ,
12
9
/ A n o n y m o u s a r r o w f u n c t i o n s c a u s e F a s t R e f r e s h t o n o t p r e s e r v e l o c a l c o m p o n e n t s t a t e ./ i
13
10
)
14
11
} )
15
- it . skip ( `should log warning to console for function declarations` , ( ) => {
16
- cy . visit ( `/eslint-rules/no-anonymous-exports-page-templates-function` , {
17
- onBeforeLoad ( win ) {
18
- cy . stub ( win . console , "log" ) . as ( `consoleLog` )
19
- } ,
20
- } ) . waitForRouteChange ( )
12
+ it ( `should log warning to console for function declarations` , ( ) => {
13
+ cy . visit (
14
+ `/eslint-rules/no-anonymous-exports-page-templates-function`
15
+ ) . waitForRouteChange ( )
21
16
22
- cy . get ( `@consoleLog ` ) . should (
17
+ cy . get ( `@hmrConsoleLog ` ) . should (
23
18
`be.calledWithMatch` ,
24
19
/ A n o n y m o u s f u n c t i o n d e c l a r a t i o n s c a u s e F a s t R e f r e s h t o n o t p r e s e r v e l o c a l c o m p o n e n t s t a t e ./ i
25
20
)
You can’t perform that action at this time.
0 commit comments