mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-09 21:04:31 +00:00
fix(msteams): detect windows local paths for uploads
This commit is contained in:
@@ -145,6 +145,15 @@ describe("msteams media-helpers", () => {
|
||||
expect(isLocalPath("~/Downloads/image.png")).toBe(true);
|
||||
});
|
||||
|
||||
it("returns true for Windows absolute drive paths", () => {
|
||||
expect(isLocalPath("C:\\Users\\test\\image.png")).toBe(true);
|
||||
expect(isLocalPath("D:/data/photo.jpg")).toBe(true);
|
||||
});
|
||||
|
||||
it("returns true for Windows UNC paths", () => {
|
||||
expect(isLocalPath("\\\\server\\share\\image.png")).toBe(true);
|
||||
});
|
||||
|
||||
it("returns false for http URLs", () => {
|
||||
expect(isLocalPath("http://example.com/image.png")).toBe(false);
|
||||
expect(isLocalPath("https://example.com/image.png")).toBe(false);
|
||||
|
||||
Reference in New Issue
Block a user