Skip to content

Commit

Permalink
fix(test): spelling mistakes of ACQUIRE_TIMEOUT constant
Browse files Browse the repository at this point in the history
  • Loading branch information
fenying committed Apr 10, 2024
1 parent f6a5fa8 commit a97ff42
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/integration/test-pool-acquire-timeout.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ const common = require('../common');

const poolConfig = common.getConfig();

const ACQUITE_TIMEOUT = 500;
const ACQUIRE_TIMEOUT = 500;
const poolWithAcquireTimeout = new mysql.createPool({
...poolConfig,
acquireTimeout: ACQUITE_TIMEOUT,
acquireTimeout: ACQUIRE_TIMEOUT,
connectionLimit: 2
});

Expand All @@ -32,8 +32,8 @@ poolWithAcquireTimeout.getConnection((err, c1) => {
'timeout of pool is full': () => {
assert.equal(e3 !== null, true);
assert.equal(!c3, true);
assert.equal(C3_DONE_AT - C3_STARTED_AT >= ACQUITE_TIMEOUT, true);
assert.equal(C3_DONE_AT - C3_STARTED_AT < ACQUITE_TIMEOUT * 2, true);
assert.equal(C3_DONE_AT - C3_STARTED_AT >= ACQUIRE_TIMEOUT, true);
assert.equal(C3_DONE_AT - C3_STARTED_AT < ACQUIRE_TIMEOUT * 2, true);
},
'ok if pool is not full': () => {
assert.equal(e4 === null, true);
Expand Down

0 comments on commit a97ff42

Please sign in to comment.