refactor: use global.root_path instead relative paths (#3883)

This commit is contained in:
Karsten Hassel
2025-09-09 08:09:45 +02:00
committed by GitHub
parent 31bafc3297
commit b1865d8115
16 changed files with 34 additions and 35 deletions

View File

@@ -3,7 +3,7 @@ const helpers = require("./helpers/global-setup");
describe("All font files from roboto.css should be downloadable", () => {
const fontFiles = [];
// Statements below filters out all 'url' lines in the CSS file
const fileContent = require("node:fs").readFileSync(`${__dirname}/../../css/roboto.css`, "utf8");
const fileContent = require("node:fs").readFileSync(`${global.root_path}/css/roboto.css`, "utf8");
const regex = /\burl\(['"]([^'"]+)['"]\)/g;
let match = regex.exec(fileContent);
while (match !== null) {