mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-06-21 09:10:42 +00:00
fix failing nationNameLength test (#2556)
## Description: Fixes the failing nationNameLength.test by usinbg the proper absolute path glob syntax Also switches to fast-glob because I don't see a reason to not use it. ## Please complete the following: - [x] I have added screenshots for all UI updates - [x] I process any text displayed to the user through translateText() and I've added it to the en.json file - [x] I have added relevant tests to the test directory - [x] I confirm I have thoroughly tested these changes and take full responsibility for any bugs introduced ## Please put your Discord username so you can be contacted if a bug or regression is found: Lavodan
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
import fs from "fs";
|
||||
import { globSync } from "glob";
|
||||
import path from "path";
|
||||
|
||||
type Nation = {
|
||||
name?: string;
|
||||
@@ -12,9 +11,7 @@ type Manifest = {
|
||||
|
||||
describe("Map manifests: nation name length constraint", () => {
|
||||
test("All nations' names must be ≤ 27 characters", () => {
|
||||
const manifestPaths = globSync(
|
||||
path.resolve(process.cwd(), "resources/maps/**/manifest.json"),
|
||||
);
|
||||
const manifestPaths = globSync("resources/maps/**/manifest.json");
|
||||
|
||||
expect(manifestPaths.length).toBeGreaterThan(0);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user