budibase/packages/server/__mocks__/mysql.js

13 lines
188 B
JavaScript

const mysql = {}
const client = {
connect: jest.fn(),
query: jest.fn((query, fn) => {
fn(null, [])
}),
}
mysql.createConnection = jest.fn(() => client)
module.exports = mysql