File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -303,6 +303,9 @@ describe('addTargetClient', () => {
303303 link : 'https://example.com' ,
304304 description : 'A custom HTTP library' ,
305305 extname : '.custom' ,
306+ installation : request => {
307+ return `brew install ${ request . fullUrl } ` ;
308+ } ,
306309 } ,
307310 convert : ( ) => {
308311 return 'This was generated from a custom client.' ;
@@ -314,8 +317,10 @@ describe('addTargetClient', () => {
314317 const snippet = new HTTPSnippet ( short . log . entries [ 0 ] . request as Request , { } ) ;
315318
316319 const result = snippet . convert ( 'node' , 'custom' ) [ 0 ] ;
317-
318320 expect ( result ) . toBe ( 'This was generated from a custom client.' ) ;
321+
322+ const install = snippet . installation ( 'node' , 'custom' ) [ 0 ] ;
323+ expect ( install ) . toBe ( 'brew install https://httpbin.org/anything' ) ;
319324 } ) ;
320325} ) ;
321326
You can’t perform that action at this time.
0 commit comments