imageFilenames and imageFilename, backend integration tests, frontend tests, removed username references

This commit is contained in:
jackiettran
2025-11-26 23:13:23 -05:00
parent f2d3aac029
commit 11593606aa
52 changed files with 2815 additions and 150 deletions

25
frontend/jest.env.js Normal file
View File

@@ -0,0 +1,25 @@
const JSDOMEnvironment = require('jest-environment-jsdom').default;
const { TextEncoder, TextDecoder } = require('util');
class CustomEnvironment extends JSDOMEnvironment {
constructor(config, context) {
super(config, context);
// Add polyfills to global before any test code runs
this.global.TextEncoder = TextEncoder;
this.global.TextDecoder = TextDecoder;
// BroadcastChannel polyfill
this.global.BroadcastChannel = class BroadcastChannel {
constructor(name) {
this.name = name;
}
postMessage() {}
close() {}
addEventListener() {}
removeEventListener() {}
};
}
}
module.exports = CustomEnvironment;