Use `vitest` for backend tests: - `bench` script now uses [vitest's `bench`](https://vitest.dev/api/#bench) - e2e test fails with same error happening now with jest:`data-testid` attribute not present. vitest left, jest right <img width="1264" height="603" alt="image" src="https://github.com/user-attachments/assets/56fc43a6-e143-4208-bf14-7e016aae7fa9" />
12 lines
309 B
JavaScript
12 lines
309 B
JavaScript
import { describe, expect, it } from "vitest";
|
|
|
|
import { encodeHTML } from "../src/common/html.js";
|
|
|
|
describe("Test html.js", () => {
|
|
it("should test encodeHTML", () => {
|
|
expect(encodeHTML(`<html>hello world<,.#4^&^@%!))`)).toBe(
|
|
"<html>hello world<,.#4^&^@%!))",
|
|
);
|
|
});
|
|
});
|