test(hooks): match the installer canonical worktree path

This commit is contained in:
creatixchu committed 2026-09-26 12:09:58 +08:00
1 parent 683e42a3b0
commit 5e6524bca4
1 file changed
+2 -1
+2 -1
View File
@@ -160,7 +160,8 @@ function gitDirectory(fixture: Fixture, root: string): string {
function commonDirectory(fixture: Fixture): string {
const output = git(fixture, fixture.main, ['rev-parse', '--git-common-dir'])
return isAbsolute(output) ? output : resolve(fixture.main, output)
// Git can expand a Windows short path before the installer constructs its lock path.
return isAbsolute(output) ? output : resolve(git(fixture, fixture.main, ['rev-parse', '--show-toplevel']), output)
}
function hooksPath(fixture: Fixture, root: string): string {