diff --git a/server/src/lib/database-seeds/repo.ts b/server/src/lib/database-seeds/repo.ts index a16cce669..aaf5c6ff4 100644 --- a/server/src/lib/database-seeds/repo.ts +++ b/server/src/lib/database-seeds/repo.ts @@ -106,6 +106,20 @@ export class DatabaseSeedsRepo { return false; } + // Ok, Testing this is actually a bad idea. Hear me out. + // It's exceptionally difficult to actually store and look at the test output. (potentially huge) + // especially when filesystem size is our biggest constraint at the moment. + // + // It's better for us to commit straight away, and have the tests on our github CI fail + // (and subsequently yell at us.) + // + // try { + // await asyncExec(`cd "${this.baseDir}/scripts" || exit 2; pnpm install; pnpm test`); + // } catch ({ err, stdout, stderr }) { + // logger.error(`Testing the changes failed. ${err}. Not committing back!`, { err }); + // throw err; + // } + this.logger.info(`Changes. Committing changes back.`); const { stdout: commitOut } = await asyncExec( diff --git a/server/src/utils/misc.ts b/server/src/utils/misc.ts index 95a067ab9..4907373d2 100644 --- a/server/src/utils/misc.ts +++ b/server/src/utils/misc.ts @@ -176,7 +176,7 @@ export function asyncExec(command: string) { exec(command, (err, stdout, stderr) => { if (err) { // eslint-disable-next-line prefer-promise-reject-errors - return reject({ stdout, stderr, err }); + return reject({ err, stdout, stderr }); } return resolve({ stdout, stderr });