File tree Expand file tree Collapse file tree 2 files changed +7
-6
lines changed
Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -86,11 +86,11 @@ describe('pool', function() {
8686
8787 it ( 'can close multiple times on a pool' , async function ( ) {
8888 const pool = new pg . Pool ( { max : 1 } )
89- const run = ( ) =>
90- new Promise ( async resolve => {
91- const cursor = new Cursor ( text )
92- const client = await pool . connect ( )
93- client . query ( cursor )
89+ const run = async ( ) => {
90+ const cursor = new Cursor ( text )
91+ const client = await pool . connect ( )
92+ client . query ( cursor )
93+ new Promise ( resolve => {
9494 cursor . read ( 25 , function ( err ) {
9595 assert . ifError ( err )
9696 cursor . close ( function ( err ) {
@@ -100,6 +100,7 @@ describe('pool', function() {
100100 } )
101101 } )
102102 } )
103+ }
103104 await Promise . all ( [ run ( ) , run ( ) , run ( ) ] )
104105 await pool . end ( )
105106 } )
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ describe('transactions', () => {
2828 await client . end ( )
2929 } )
3030
31- it . only ( 'can execute multiple statements in a transaction if no data' , async ( ) => {
31+ it ( 'can execute multiple statements in a transaction if no data' , async ( ) => {
3232 const client = new pg . Client ( )
3333 await client . connect ( )
3434 await client . query ( 'begin' )
You can’t perform that action at this time.
0 commit comments