Skip to content

Commit 10a3df5

Browse files
test: compare the unminified asset to its source, not an LF literal
Claude-Session: https://claude.ai/code/session_01EpeANYvMKyZwSDTRVE5LoG
1 parent aaee515 commit 10a3df5

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

‎test/configCases/asset-modules/minimize-fragment-names/test.config.js‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,11 @@ module.exports = {
1818
expect(read(`${index}/script.js`)).toMatchSnapshot();
1919
}
2020

21-
// The extension is read before the fragment, so `#a.css` claims nothing.
22-
expect(read("1/data.txt")).toBe("not css {\n");
21+
// The extension is read before the fragment, so `#a.css` claims nothing:
22+
// the copy matches its source byte for byte, whatever line endings it has.
23+
expect(read("1/data.txt")).toBe(
24+
fs.readFileSync(path.join(__dirname, "files/data.txt"), "utf8")
25+
);
2326

2427
// Only the second build enables native CSS and HTML.
2528
expect(read("1/style.css")).toMatchSnapshot();

0 commit comments

Comments
 (0)