Add __TESTS__ variable to web app when the tests are running

This commit is contained in:
Jonatan Heyman 2024-10-29 17:19:14 +01:00
parent 74ecd36b71
commit b90c338a1c
2 changed files with 1 additions and 2 deletions

View File

@ -122,7 +122,6 @@ function migrateBufferFileToLibrary() {
}
migrateBufferFileToLibrary()
const Heynote = {
platform: platform,
defaultFontFamily: "Hack",

View File

@ -26,7 +26,6 @@ const middleware = () => {
}
}
// https://vitejs.dev/config/
export default defineConfig({
publicDir: "../public",
@ -54,5 +53,6 @@ export default defineConfig({
define: {
'__APP_VERSION__': JSON.stringify(process.env.npm_package_version),
'__GIT_HASH__': JSON.stringify(child.execSync('git rev-parse --short HEAD').toString().trim()),
'__TESTS__': process.env.HEYNOTE_TESTS,
},
})