Skip to content

Commit

Permalink
fix(test): glob root match test matches against platform-normalized path
Browse files Browse the repository at this point in the history
  • Loading branch information
boneskull committed Jan 4, 2023
1 parent fd7a896 commit 6c1b4ac
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/test/utils/fs.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import * as fs from "fs";
import { createServer } from "net";
import { Project, tempdirProject } from "@typestrong/fs-fixture-builder";
import { AssertionError, deepStrictEqual as equal } from "assert";
import { basename, dirname, resolve } from "path";
import { basename, dirname, resolve, normalize } from "path";
import { glob } from "../../lib/utils/fs";

describe("fs.ts", () => {
Expand All @@ -20,7 +20,7 @@ describe("fs.ts", () => {
fix.write();

const result = glob(fix.cwd, fix.cwd, { includeDirectories: true });
equal(result, [fix.cwd]);
equal(result.map(normalize), [fix.cwd].map(normalize));
});

it("Handles basic globbing", () => {
Expand Down

0 comments on commit 6c1b4ac

Please sign in to comment.