Skip to content

Commit d42b84a

Browse files
CopilotCopilot
andcommitted
fix: handle Linux root path in HTML export test
The test was checking that absolute paths (like Windows drive letters) are not embedded in HTML output. However, on Linux, Path.GetPathRoot() returns '/', which is commonly found in HTML content. Updated the test to skip this check on non-Windows platforms. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent b9d6ceb commit d42b84a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/tests/Graphify.Tests/Export/RelativePathHandlingTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,7 @@ public async Task HtmlExport_EmbeddedPaths_AreRelative()
333333

334334
// Verify no absolute paths are embedded
335335
var drive = Path.GetPathRoot(_projectRoot);
336-
if (!string.IsNullOrEmpty(drive))
336+
if (!string.IsNullOrEmpty(drive) && drive != "/")
337337
{
338338
Assert.DoesNotContain(drive, html);
339339
}

0 commit comments

Comments
 (0)