1
0
Fork 0
mirror of synced 2024-06-29 11:31:06 +12:00
budibase/packages/server/__mocks__/mysql2/promise.ts
2022-03-03 23:50:46 +00:00

18 lines
271 B
TypeScript

module MySQLMock {
const mysql: any = {}
const client = {
connect: jest.fn(),
end: jest.fn(),
query: jest.fn(async () => {
return [[]]
}),
}
mysql.createConnection = jest.fn(async () => {
return client
})
module.exports = mysql
}