Fix E2E Tests

This commit is contained in:
Sidharth Vinod
2023-02-19 14:03:11 +05:30
parent d2927435ab
commit 735aceb37a
74 changed files with 298 additions and 334 deletions

View File

@@ -1,13 +1,7 @@
import express, { NextFunction, Request, Response } from 'express';
import express from 'express';
import cors from 'cors';
import { createServer as createViteServer } from 'vite';
const cors = (req: Request, res: Response, next: NextFunction) => {
res.header('Access-Control-Allow-Origin', '*');
res.header('Access-Control-Allow-Methods', 'GET,PUT,POST,DELETE');
res.header('Access-Control-Allow-Headers', 'Content-Type');
next();
};
async function createServer() {
const app = express();