@@ -3,6 +3,7 @@ var path = require("path");
33var local = path . join . bind ( path , __dirname ) ;
44var _ = require ( "lodash" ) ;
55var fp = require ( "lodash/fp" ) ;
6+ var fs = require ( "fs" ) ;
67
78var garbageCollect = require ( "../utils/garbage_collect.js" ) ;
89var RepoUtils = require ( "../utils/repository_setup" ) ;
@@ -346,6 +347,10 @@ describe("Remote", function() {
346347
347348 if ( ! isNode8 ) {
348349 it ( "will reject if credentials promise rejects" , function ( ) {
350+ const tracing = require ( "trace_events" ) . createTracing ( {
351+ categories : [ "v8" , "node.async_hooks" , "node.perf" , "node.vm.script" ]
352+ } ) ;
353+ tracing . enable ( ) ;
349354 var repo = this . repository ;
350355 var branch = "should-not-exist" ;
351356 return Remote . lookup ( repo , "origin" )
@@ -402,9 +407,13 @@ describe("Remote", function() {
402407 return remote . push ( refs , options ) ;
403408 } )
404409 . then ( function ( ) {
410+ tracing . disable ( ) ;
411+ console . log ( fs . readFileSync ( "node_trace.1.log" , "utf8" ) ) ;
405412 return Promise . reject (
406413 new Error ( "should not be able to push to the repository" ) ) ;
407414 } , function ( err ) {
415+ tracing . disable ( ) ;
416+ console . log ( fs . readFileSync ( "node_trace.1.log" , "utf8" ) ) ;
408417 if ( err . message === "Method push has thrown an error." )
409418 {
410419 return Promise . resolve ( ) ;
0 commit comments