fix: restore placeholders within filenames
This commit is contained in:
@@ -129,6 +129,16 @@ describe("Velum-Projektstände", () => {
|
||||
expect(project.restorePath("PERSON_01_Bericht.txt", {
|
||||
PERSON_01: { original: "Max Mustermann", type: "PERSON" },
|
||||
})).toBe("Max Mustermann_Bericht.txt");
|
||||
expect(project.restorePath("Archiv/BerichtPERSON_01.docx", {
|
||||
PERSON_01: { original: "Max Mustermann", type: "PERSON" },
|
||||
})).toBe("Archiv/BerichtMax Mustermann.docx");
|
||||
expect(project.restoreText("BerichtPERSON_01", {
|
||||
PERSON_01: { original: "Max Mustermann", type: "PERSON" },
|
||||
})).toBe("BerichtPERSON_01");
|
||||
expect(project.restorePath("PERSON_0101.txt", {
|
||||
PERSON_01: { original: "Falsch", type: "PERSON" },
|
||||
PERSON_0101: { original: "Richtig", type: "PERSON" },
|
||||
})).toBe("Richtig.txt");
|
||||
expect(() => project.safeRelativePath("../geheim.txt")).toThrow();
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user