From b17b61b8c6854657177dbdc23fad8ea98f4e779f Mon Sep 17 00:00:00 2001 From: dave caruso Date: Sat, 22 Jul 2023 16:45:45 -0700 Subject: fix path.format for `vite build` (#3734) * fix path.format for vite * Update path.test.js --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> --- test/js/node/path/path.test.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'test/js') diff --git a/test/js/node/path/path.test.js b/test/js/node/path/path.test.js index 8f5a76da7..03037c2e9 100644 --- a/test/js/node/path/path.test.js +++ b/test/js/node/path/path.test.js @@ -1,6 +1,6 @@ const { file } = import.meta; -import { describe, it, expect } from "bun:test"; +import { describe, it, expect, test } from "bun:test"; import path from "node:path"; import assert from "assert"; import { hideFromStackTrace } from "harness"; @@ -586,3 +586,7 @@ it("path.parse", () => { name: "another_dir", }); }); + +test("path.format works for vite's example", () => { + expect(path.format({ root: "", dir: "", name: "index", base: undefined, ext: ".css" })).toBe("index.css"); +}); -- cgit v1.2.3