adding jest and jest files

This commit is contained in:
Aster Fialla
2026-02-14 18:16:10 -05:00
committed by pieartsy
parent 68629fd75d
commit a2c0530118
9 changed files with 9 additions and 0 deletions

View File

@@ -37,6 +37,9 @@ database.members = sequelize.define('Member', {
}
});
/**
* Checks Sequelize database connection.
*/
database.check_connection = async function() {
await sequelize.authenticate().then(async (result) => {
console.log('Connection has been established successfully.');
@@ -47,6 +50,9 @@ database.check_connection = async function() {
});
}
/**
* Syncs Sequelize models.
*/
async function syncModels() {
await sequelize.sync().then(() => {
console.log('Models synced successfully.');