Skip to content

Commit 6ab0807

Browse files
committed
ui-tests: let SetWorkTree() accept a directory base name
This base name should be different for the different UI tests (once we have more than one) so that they do not clash. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent da687f1 commit 6ab0807

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

ui-tests/background-hook.ahk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
; This was fixed in the Cygwin/MSYS2 runtime, but then regressed again.
1212
; This test is meant to verify that the issue is fixed and remains so.
1313

14-
SetWorkTree()
14+
SetWorkTree('git-test-background-hook')
1515

1616
SetWorkingDir(EnvGet('TEMP'))
1717
Info 'uname: ' RunWaitOne('uname -a')

ui-tests/ui-test-library.ahk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
; Reusable library functions for the UI tests.
22

3-
SetWorkTree() {
3+
SetWorkTree(defaultName) {
44
global workTree
55
; First, set the worktree path; This path will be reused
66
; for the `.log` file).
@@ -9,7 +9,7 @@ SetWorkTree() {
99
else
1010
{
1111
; Create a unique worktree path in the TEMP directory.
12-
workTree := EnvGet('TEMP') . '\git-test-background-hook'
12+
workTree := EnvGet('TEMP') . '\' . defaultName
1313
if FileExist(workTree)
1414
{
1515
counter := 0

0 commit comments

Comments
 (0)