@@ -52,7 +52,7 @@ describe('server', () => {
52
52
53
53
it ( 'calls express listen when start is called' , ( ) => {
54
54
const listen = jest . fn ( ) ;
55
- loopback . mockReturnValue ( { listen } ) ;
55
+ loopback . mockReturnValue ( { listen} ) ;
56
56
getApp ( ) . start ( ) ;
57
57
expect ( listen ) . toBeCalledWith ( expect . any ( Function ) ) ;
58
58
} ) ;
@@ -61,7 +61,7 @@ describe('server', () => {
61
61
const get = jest . fn ( ( ) => 'foo' ) ;
62
62
const listen = jest . fn ( cb => cb ( ) ) ;
63
63
const emit = jest . fn ( ) ;
64
- loopback . mockReturnValue ( { listen, get, emit } ) ;
64
+ loopback . mockReturnValue ( { listen, get, emit} ) ;
65
65
getApp ( ) . start ( ) ;
66
66
expect ( emit ) . toBeCalledWith ( 'started' ) ;
67
67
} ) ;
@@ -71,7 +71,7 @@ describe('server', () => {
71
71
const listen = jest . fn ( cb => cb ( ) ) ;
72
72
const emit = jest . fn ( ) ;
73
73
console . log = jest . fn ( ) ;
74
- loopback . mockReturnValue ( { listen, get, emit } ) ;
74
+ loopback . mockReturnValue ( { listen, get, emit} ) ;
75
75
getApp ( ) . start ( ) ;
76
76
expect ( console . log ) . toBeCalledWith (
77
77
expect . any ( String ) ,
@@ -80,11 +80,13 @@ describe('server', () => {
80
80
} ) ;
81
81
82
82
it ( 'log explorer url when start is called' , ( ) => {
83
- const get = jest . fn ( term => ( term === 'url' ? 'url' : { mountPath : 'foo' } ) ) ;
83
+ const get = jest . fn (
84
+ term => ( term === 'url' ? 'url' : { mountPath : 'foo' } )
85
+ ) ;
84
86
const listen = jest . fn ( cb => cb ( ) ) ;
85
87
const emit = jest . fn ( ) ;
86
88
console . log = jest . fn ( ) ;
87
- loopback . mockReturnValue ( { listen, get, emit } ) ;
89
+ loopback . mockReturnValue ( { listen, get, emit} ) ;
88
90
getApp ( ) . start ( ) ;
89
91
expect ( console . log ) . toBeCalledWith (
90
92
expect . any ( String ) ,
@@ -95,8 +97,8 @@ describe('server', () => {
95
97
96
98
it ( 'close server when close is called' , ( ) => {
97
99
const close = jest . fn ( ) ;
98
- const listen = jest . fn ( ( ) => ( { close } ) ) ;
99
- loopback . mockReturnValue ( { listen } ) ;
100
+ const listen = jest . fn ( ( ) => ( { close} ) ) ;
101
+ loopback . mockReturnValue ( { listen} ) ;
100
102
getApp ( ) . start ( ) ;
101
103
getApp ( ) . close ( ) ;
102
104
expect ( close ) . toBeCalled ( ) ;
0 commit comments