mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-09-03 04:38:33 +00:00
fix(lint): ignore macOS AppleDouble HTML files (#2191)
This commit is contained in:
@@ -914,6 +914,19 @@ describe("multiple_root_compositions", () => {
|
||||
expect(finding).toBeUndefined();
|
||||
});
|
||||
|
||||
it("ignores macOS AppleDouble HTML metadata files", async () => {
|
||||
const project = makeProject(validHtml());
|
||||
writeFileSync(join(project, "._index.html"), validHtml());
|
||||
mkdirSync(join(project, "compositions"), { recursive: true });
|
||||
writeFileSync(join(project, "compositions", "._scene.html"), validHtml("scene"));
|
||||
const { results } = await lintProject(project);
|
||||
const finding = results[0]?.result.findings.find(
|
||||
(f) => f.code === "multiple_root_compositions",
|
||||
);
|
||||
expect(finding).toBeUndefined();
|
||||
expect(results.some((result) => result.file.includes("._"))).toBe(false);
|
||||
});
|
||||
|
||||
it("ignores HTML files without data-composition-id", async () => {
|
||||
const project = makeProject(validHtml());
|
||||
writeFileSync(join(project, "readme.html"), "<html><body>Not a composition</body></html>");
|
||||
|
||||
Reference in New Issue
Block a user