Fix expected values of setup tests on Windows
On Windows, bash stores absolute path names in shell variables in POSIX format that begins with a slash, rather than in drive-letter format; such a value is converted to the latter format when it is passed to a non-MSYS program such as git. When an expected test value is constructed, it must contain the value that will be produced by git, which will be in the drive-letter format. But TRASH_DIRECTORY is in POSIX format. Fix this by using $(pwd), which produces drive-letter format since 4114156a (Tests on Windows: $(pwd) must return Windows-style paths). The change in t1510 is a straight seach-and-replace, except for the first hunk of the diff. Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Johannes Sixt committed
Dec 30, 2010 at 21:51 UTC
e6ec2b6a23a364de76cd8868d4df20627264eb45
2 files changed
+1168
-1167
t/t1501-worktree.sh
+1
-1
@@ -343,7 +343,7 @@ test_expect_success 'make_relative_path handles double slashes in GIT_DIR' '
343
test_expect_success 'relative $GIT_WORK_TREE and git subprocesses' '
344
GIT_DIR=repo.git GIT_WORK_TREE=repo.git/work \
345
test-subprocess --setup-work-tree rev-parse --show-toplevel >actual &&
346
- echo "$TRASH_DIRECTORY/repo.git/work" >expected &&
346
+ echo "$(pwd)/repo.git/work" >expected &&
347
test_cmp expected actual
348
'
349
t/t1510-repo-setup.sh
+1167
-1166
@@ -82,14 +82,15 @@ test_repo() {
82
test_expect_success '#0: setup' '
83
sane_unset GIT_DIR GIT_WORK_TREE &&
84
mkdir 0 0/sub &&
85
- cd 0 && git init && cd ..
85
+ (cd 0 && git init) &&
86
+ here=$(pwd)
87
'
88
89
test_expect_success '#0: at root' '
90
cat >0/expected <<EOF &&
91
setup: git_dir: .git
91
-setup: worktree: $TRASH_DIRECTORY/0
92
-setup: cwd: $TRASH_DIRECTORY/0
92
+setup: worktree: $here/0
93
+setup: cwd: $here/0
94
setup: prefix: (null)
95
EOF
96
test_repo 0
@@ -98,8 +99,8 @@ EOF
99
test_expect_success '#0: in subdir' '
100
cat >0/sub/expected <<EOF &&
101
setup: git_dir: .git
101
-setup: worktree: $TRASH_DIRECTORY/0
102
-setup: cwd: $TRASH_DIRECTORY/0
102
+setup: worktree: $here/0
103
+setup: cwd: $here/0
104
setup: prefix: sub/
105
EOF
106
test_repo 0/sub
@@ -135,8 +136,8 @@ test_expect_success '#1: setup' '
136
test_expect_success '#1: at root' '
137
cat >1/expected <<EOF &&
138
setup: git_dir: .git
138
-setup: worktree: $TRASH_DIRECTORY/1
139
-setup: cwd: $TRASH_DIRECTORY/1
139
+setup: worktree: $here/1
140
+setup: cwd: $here/1
141
setup: prefix: (null)
142
EOF
143
test_repo 1
@@ -145,8 +146,8 @@ EOF
146
test_expect_success '#1: in subdir' '
147
cat >1/sub/expected <<EOF &&
148
setup: git_dir: .git
148
-setup: worktree: $TRASH_DIRECTORY/1
149
-setup: cwd: $TRASH_DIRECTORY/1
149
+setup: worktree: $here/1
150
+setup: cwd: $here/1
151
setup: prefix: sub/
152
EOF
153
test_repo 1/sub
@@ -181,29 +182,29 @@ test_expect_success '#2: setup' '
182
183
test_expect_success '#2: at root' '
184
cat >2/expected <<EOF &&
184
-setup: git_dir: $TRASH_DIRECTORY/2/.git
185
-setup: worktree: $TRASH_DIRECTORY/2
186
-setup: cwd: $TRASH_DIRECTORY/2
185
+setup: git_dir: $here/2/.git
186
+setup: worktree: $here/2
187
+setup: cwd: $here/2
188
setup: prefix: (null)
189
EOF
189
- test_repo 2 "$TRASH_DIRECTORY/2/.git"
190
+ test_repo 2 "$here/2/.git"
191
'
192
193
test_expect_success '#2: in subdir' '
194
cat >2/sub/expected <<EOF &&
194
-setup: git_dir: $TRASH_DIRECTORY/2/.git
195
-setup: worktree: $TRASH_DIRECTORY/2/sub
196
-setup: cwd: $TRASH_DIRECTORY/2/sub
195
+setup: git_dir: $here/2/.git
196
+setup: worktree: $here/2/sub
197
+setup: cwd: $here/2/sub
198
setup: prefix: (null)
199
EOF
199
- test_repo 2/sub "$TRASH_DIRECTORY/2/.git"
200
+ test_repo 2/sub "$here/2/.git"
201
'
202
203
test_expect_success '#2: relative GIT_DIR at root' '
204
cat >2/expected <<EOF &&
205
setup: git_dir: .git
205
-setup: worktree: $TRASH_DIRECTORY/2
206
-setup: cwd: $TRASH_DIRECTORY/2
206
+setup: worktree: $here/2
207
+setup: cwd: $here/2
208
setup: prefix: (null)
209
EOF
210
test_repo 2 .git
@@ -212,8 +213,8 @@ EOF
213
test_expect_success '#2: relative GIT_DIR in subdir' '
214
cat >2/sub/expected <<EOF &&
215
setup: git_dir: ../.git
215
-setup: worktree: $TRASH_DIRECTORY/2/sub
216
-setup: cwd: $TRASH_DIRECTORY/2/sub
216
+setup: worktree: $here/2/sub
217
+setup: cwd: $here/2/sub
218
setup: prefix: (null)
219
EOF
220
test_repo 2/sub ../.git
@@ -249,18 +250,18 @@ test_expect_success '#3: setup' '
250
test_expect_success '#3: GIT_DIR(rel), GIT_WORK_TREE=root at root' '
251
cat >3/expected <<EOF &&
252
setup: git_dir: .git
252
-setup: worktree: $TRASH_DIRECTORY/3
253
-setup: cwd: $TRASH_DIRECTORY/3
253
+setup: worktree: $here/3
254
+setup: cwd: $here/3
255
setup: prefix: (null)
256
EOF
256
- test_repo 3 .git "$TRASH_DIRECTORY/3"
257
+ test_repo 3 .git "$here/3"
258
'
259
260
test_expect_success '#3: GIT_DIR(rel), GIT_WORK_TREE=root(rel) at root' '
261
cat >3/expected <<EOF &&
262
setup: git_dir: .git
262
-setup: worktree: $TRASH_DIRECTORY/3
263
-setup: cwd: $TRASH_DIRECTORY/3
263
+setup: worktree: $here/3
264
+setup: cwd: $here/3
265
setup: prefix: (null)
266
EOF
267
test_repo 3 .git .
@@ -268,39 +269,39 @@ EOF
269
270
test_expect_success '#3: GIT_DIR, GIT_WORK_TREE=root at root' '
271
cat >3/expected <<EOF &&
271
-setup: git_dir: $TRASH_DIRECTORY/3/.git
272
-setup: worktree: $TRASH_DIRECTORY/3
273
-setup: cwd: $TRASH_DIRECTORY/3
272
+setup: git_dir: $here/3/.git
273
+setup: worktree: $here/3
274
+setup: cwd: $here/3
275
setup: prefix: (null)
276
EOF
276
- test_repo 3 "$TRASH_DIRECTORY/3/.git" "$TRASH_DIRECTORY/3"
277
+ test_repo 3 "$here/3/.git" "$here/3"
278
'
279
280
test_expect_success '#3: GIT_DIR, GIT_WORK_TREE=root(rel) at root' '
281
cat >3/expected <<EOF &&
281
-setup: git_dir: $TRASH_DIRECTORY/3/.git
282
-setup: worktree: $TRASH_DIRECTORY/3
283
-setup: cwd: $TRASH_DIRECTORY/3
282
+setup: git_dir: $here/3/.git
283
+setup: worktree: $here/3
284
+setup: cwd: $here/3
285
setup: prefix: (null)
286
EOF
286
- test_repo 3 "$TRASH_DIRECTORY/3/.git" .
287
+ test_repo 3 "$here/3/.git" .
288
'
289
290
test_expect_success '#3: GIT_DIR(rel), GIT_WORKTREE=root in subdir' '
291
cat >3/sub/sub/expected <<EOF &&
291
-setup: git_dir: $TRASH_DIRECTORY/3/.git
292
-setup: worktree: $TRASH_DIRECTORY/3
293
-setup: cwd: $TRASH_DIRECTORY/3
292
+setup: git_dir: $here/3/.git
293
+setup: worktree: $here/3
294
+setup: cwd: $here/3
295
setup: prefix: sub/sub/
296
EOF
296
- test_repo 3/sub/sub ../../.git "$TRASH_DIRECTORY/3"
297
+ test_repo 3/sub/sub ../../.git "$here/3"
298
'
299
300
test_expect_success '#3: GIT_DIR(rel), GIT_WORKTREE=root(rel) in subdir' '
301
cat >3/sub/sub/expected <<EOF &&
301
-setup: git_dir: $TRASH_DIRECTORY/3/.git
302
-setup: worktree: $TRASH_DIRECTORY/3
303
-setup: cwd: $TRASH_DIRECTORY/3
302
+setup: git_dir: $here/3/.git
303
+setup: worktree: $here/3
304
+setup: cwd: $here/3
305
setup: prefix: sub/sub/
306
EOF
307
test_repo 3/sub/sub ../../.git ../..
@@ -308,39 +309,39 @@ EOF
309
310
test_expect_success '#3: GIT_DIR, GIT_WORKTREE=root in subdir' '
311
cat >3/sub/expected <<EOF &&
311
-setup: git_dir: $TRASH_DIRECTORY/3/.git
312
-setup: worktree: $TRASH_DIRECTORY/3
313
-setup: cwd: $TRASH_DIRECTORY/3
312
+setup: git_dir: $here/3/.git
313
+setup: worktree: $here/3
314
+setup: cwd: $here/3
315
setup: prefix: sub/
316
EOF
316
- test_repo 3/sub "$TRASH_DIRECTORY/3/.git" "$TRASH_DIRECTORY/3"
317
+ test_repo 3/sub "$here/3/.git" "$here/3"
318
'
319
320
test_expect_success '#3: GIT_DIR, GIT_WORKTREE=root(rel) in subdir' '
321
cat >3/sub/sub/expected <<EOF &&
321
-setup: git_dir: $TRASH_DIRECTORY/3/.git
322
-setup: worktree: $TRASH_DIRECTORY/3
323
-setup: cwd: $TRASH_DIRECTORY/3
322
+setup: git_dir: $here/3/.git
323
+setup: worktree: $here/3
324
+setup: cwd: $here/3
325
setup: prefix: sub/sub/
326
EOF
326
- test_repo 3/sub/sub "$TRASH_DIRECTORY/3/.git" ../..
327
+ test_repo 3/sub/sub "$here/3/.git" ../..
328
'
329
330
test_expect_success '#3: GIT_DIR(rel), GIT_WORK_TREE=wt at root' '
331
cat >3/expected <<EOF &&
332
setup: git_dir: .git
332
-setup: worktree: $TRASH_DIRECTORY/3/wt
333
-setup: cwd: $TRASH_DIRECTORY/3
333
+setup: worktree: $here/3/wt
334
+setup: cwd: $here/3
335
setup: prefix: (null)
336
EOF
336
- test_repo 3 .git "$TRASH_DIRECTORY/3/wt"
337
+ test_repo 3 .git "$here/3/wt"
338
'
339
340
test_expect_success '#3: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) at root' '
341
cat >3/expected <<EOF &&
342
setup: git_dir: .git
342
-setup: worktree: $TRASH_DIRECTORY/3/wt
343
-setup: cwd: $TRASH_DIRECTORY/3
343
+setup: worktree: $here/3/wt
344
+setup: cwd: $here/3
345
setup: prefix: (null)
346
EOF
347
test_repo 3 .git wt
@@ -348,39 +349,39 @@ EOF
349
350
test_expect_success '#3: GIT_DIR, GIT_WORK_TREE=wt(rel) at root' '
351
cat >3/expected <<EOF &&
351
-setup: git_dir: $TRASH_DIRECTORY/3/.git
352
-setup: worktree: $TRASH_DIRECTORY/3/wt
353
-setup: cwd: $TRASH_DIRECTORY/3
352
+setup: git_dir: $here/3/.git
353
+setup: worktree: $here/3/wt
354
+setup: cwd: $here/3
355
setup: prefix: (null)
356
EOF
356
- test_repo 3 "$TRASH_DIRECTORY/3/.git" wt
357
+ test_repo 3 "$here/3/.git" wt
358
'
359
360
test_expect_success '#3: GIT_DIR, GIT_WORK_TREE=wt at root' '
361
cat >3/expected <<EOF &&
361
-setup: git_dir: $TRASH_DIRECTORY/3/.git
362
-setup: worktree: $TRASH_DIRECTORY/3/wt
363
-setup: cwd: $TRASH_DIRECTORY/3
362
+setup: git_dir: $here/3/.git
363
+setup: worktree: $here/3/wt
364
+setup: cwd: $here/3
365
setup: prefix: (null)
366
EOF
366
- test_repo 3 "$TRASH_DIRECTORY/3/.git" "$TRASH_DIRECTORY/3/wt"
367
+ test_repo 3 "$here/3/.git" "$here/3/wt"
368
'
369
370
test_expect_success '#3: GIT_DIR(rel), GIT_WORK_TREE=wt in subdir' '
371
cat >3/sub/sub/expected <<EOF &&
372
setup: git_dir: ../../.git
372
-setup: worktree: $TRASH_DIRECTORY/3/wt
373
-setup: cwd: $TRASH_DIRECTORY/3/sub/sub
373
+setup: worktree: $here/3/wt
374
+setup: cwd: $here/3/sub/sub
375
setup: prefix: (null)
376
EOF
376
- test_repo 3/sub/sub ../../.git "$TRASH_DIRECTORY/3/wt"
377
+ test_repo 3/sub/sub ../../.git "$here/3/wt"
378
'
379
380
test_expect_success '#3: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) in subdir' '
381
cat >3/sub/sub/expected <<EOF &&
382
setup: git_dir: ../../.git
382
-setup: worktree: $TRASH_DIRECTORY/3/wt
383
-setup: cwd: $TRASH_DIRECTORY/3/sub/sub
383
+setup: worktree: $here/3/wt
384
+setup: cwd: $here/3/sub/sub
385
setup: prefix: (null)
386
EOF
387
test_repo 3/sub/sub ../../.git ../../wt
@@ -388,39 +389,39 @@ EOF
389
390
test_expect_success '#3: GIT_DIR, GIT_WORK_TREE=wt(rel) in subdir' '
391
cat >3/sub/sub/expected <<EOF &&
391
-setup: git_dir: $TRASH_DIRECTORY/3/.git
392
-setup: worktree: $TRASH_DIRECTORY/3/wt
393
-setup: cwd: $TRASH_DIRECTORY/3/sub/sub
392
+setup: git_dir: $here/3/.git
393
+setup: worktree: $here/3/wt
394
+setup: cwd: $here/3/sub/sub
395
setup: prefix: (null)
396
EOF
396
- test_repo 3/sub/sub "$TRASH_DIRECTORY/3/.git" ../../wt
397
+ test_repo 3/sub/sub "$here/3/.git" ../../wt
398
'
399
400
test_expect_success '#3: GIT_DIR, GIT_WORK_TREE=wt in subdir' '
401
cat >3/sub/sub/expected <<EOF &&
401
-setup: git_dir: $TRASH_DIRECTORY/3/.git
402
-setup: worktree: $TRASH_DIRECTORY/3/wt
403
-setup: cwd: $TRASH_DIRECTORY/3/sub/sub
402
+setup: git_dir: $here/3/.git
403
+setup: worktree: $here/3/wt
404
+setup: cwd: $here/3/sub/sub
405
setup: prefix: (null)
406
EOF
406
- test_repo 3/sub/sub "$TRASH_DIRECTORY/3/.git" "$TRASH_DIRECTORY/3/wt"
407
+ test_repo 3/sub/sub "$here/3/.git" "$here/3/wt"
408
'
409
410
test_expect_success '#3: GIT_DIR(rel), GIT_WORK_TREE=.. at root' '
411
cat >3/expected <<EOF &&
411
-setup: git_dir: $TRASH_DIRECTORY/3/.git
412
-setup: worktree: $TRASH_DIRECTORY
413
-setup: cwd: $TRASH_DIRECTORY
412
+setup: git_dir: $here/3/.git
413
+setup: worktree: $here
414
+setup: cwd: $here
415
setup: prefix: 3/
416
EOF
416
- test_repo 3 .git "$TRASH_DIRECTORY"
417
+ test_repo 3 .git "$here"
418
'
419
420
test_expect_success '#3: GIT_DIR(rel), GIT_WORK_TREE=..(rel) at root' '
421
cat >3/expected <<EOF &&
421
-setup: git_dir: $TRASH_DIRECTORY/3/.git
422
-setup: worktree: $TRASH_DIRECTORY
423
-setup: cwd: $TRASH_DIRECTORY
422
+setup: git_dir: $here/3/.git
423
+setup: worktree: $here
424
+setup: cwd: $here
425
setup: prefix: 3/
426
EOF
427
test_repo 3 .git ..
@@ -428,39 +429,39 @@ EOF
429
430
test_expect_success '#3: GIT_DIR, GIT_WORK_TREE=..(rel) at root' '
431
cat >3/expected <<EOF &&
431
-setup: git_dir: $TRASH_DIRECTORY/3/.git
432
-setup: worktree: $TRASH_DIRECTORY
433
-setup: cwd: $TRASH_DIRECTORY
432
+setup: git_dir: $here/3/.git
433
+setup: worktree: $here
434
+setup: cwd: $here
435
setup: prefix: 3/
436
EOF
436
- test_repo 3 "$TRASH_DIRECTORY/3/.git" ..
437
+ test_repo 3 "$here/3/.git" ..
438
'
439
440
test_expect_success '#3: GIT_DIR, GIT_WORK_TREE=.. at root' '
441
cat >3/expected <<EOF &&
441
-setup: git_dir: $TRASH_DIRECTORY/3/.git
442
-setup: worktree: $TRASH_DIRECTORY
443
-setup: cwd: $TRASH_DIRECTORY
442
+setup: git_dir: $here/3/.git
443
+setup: worktree: $here
444
+setup: cwd: $here
445
setup: prefix: 3/
446
EOF
446
- test_repo 3 "$TRASH_DIRECTORY/3/.git" "$TRASH_DIRECTORY"
447
+ test_repo 3 "$here/3/.git" "$here"
448
'
449
450
test_expect_success '#3: GIT_DIR(rel), GIT_WORK_TREE=.. in subdir' '
451
cat >3/sub/sub/expected <<EOF &&
451
-setup: git_dir: $TRASH_DIRECTORY/3/.git
452
-setup: worktree: $TRASH_DIRECTORY
453
-setup: cwd: $TRASH_DIRECTORY
452
+setup: git_dir: $here/3/.git
453
+setup: worktree: $here
454
+setup: cwd: $here
455
setup: prefix: 3/sub/sub/
456
EOF
456
- test_repo 3/sub/sub ../../.git "$TRASH_DIRECTORY"
457
+ test_repo 3/sub/sub ../../.git "$here"
458
'
459
460
test_expect_success '#3: GIT_DIR(rel), GIT_WORK_TREE=..(rel) in subdir' '
461
cat >3/sub/sub/expected <<EOF &&
461
-setup: git_dir: $TRASH_DIRECTORY/3/.git
462
-setup: worktree: $TRASH_DIRECTORY
463
-setup: cwd: $TRASH_DIRECTORY
462
+setup: git_dir: $here/3/.git
463
+setup: worktree: $here
464
+setup: cwd: $here
465
setup: prefix: 3/sub/sub/
466
EOF
467
test_repo 3/sub/sub ../../.git ../../..
@@ -468,22 +469,22 @@ EOF
469
470
test_expect_success '#3: GIT_DIR, GIT_WORK_TREE=..(rel) in subdir' '
471
cat >3/sub/sub/expected <<EOF &&
471
-setup: git_dir: $TRASH_DIRECTORY/3/.git
472
-setup: worktree: $TRASH_DIRECTORY
473
-setup: cwd: $TRASH_DIRECTORY
472
+setup: git_dir: $here/3/.git
473
+setup: worktree: $here
474
+setup: cwd: $here
475
setup: prefix: 3/sub/sub/
476
EOF
476
- test_repo 3/sub/sub "$TRASH_DIRECTORY/3/.git" ../../../
477
+ test_repo 3/sub/sub "$here/3/.git" ../../../
478
'
479
480
test_expect_success '#3: GIT_DIR, GIT_WORK_TREE=.. in subdir' '
481
cat >3/sub/sub/expected <<EOF &&
481
-setup: git_dir: $TRASH_DIRECTORY/3/.git
482
-setup: worktree: $TRASH_DIRECTORY
483
-setup: cwd: $TRASH_DIRECTORY
482
+setup: git_dir: $here/3/.git
483
+setup: worktree: $here
484
+setup: cwd: $here
485
setup: prefix: 3/sub/sub/
486
EOF
486
- test_repo 3/sub/sub "$TRASH_DIRECTORY/3/.git" "$TRASH_DIRECTORY"
487
+ test_repo 3/sub/sub "$here/3/.git" "$here"
488
'
489
490
#
@@ -515,8 +516,8 @@ test_expect_success '#4: setup' '
516
test_expect_success '#4: at root' '
517
cat >4/expected <<EOF &&
518
setup: git_dir: .git
518
-setup: worktree: $TRASH_DIRECTORY/4
519
-setup: cwd: $TRASH_DIRECTORY/4
519
+setup: worktree: $here/4
520
+setup: cwd: $here/4
521
setup: prefix: (null)
522
EOF
523
test_repo 4
@@ -525,8 +526,8 @@ EOF
526
test_expect_success '#4: in subdir' '
527
cat >4/sub/expected <<EOF &&
528
setup: git_dir: .git
528
-setup: worktree: $TRASH_DIRECTORY/4
529
-setup: cwd: $TRASH_DIRECTORY/4
529
+setup: worktree: $here/4
530
+setup: cwd: $here/4
531
setup: prefix: sub/
532
EOF
533
test_repo 4/sub
@@ -563,8 +564,8 @@ test_expect_success '#5: setup' '
564
test_expect_success '#5: at root' '
565
cat >5/expected <<EOF &&
566
setup: git_dir: .git
566
-setup: worktree: $TRASH_DIRECTORY/5
567
-setup: cwd: $TRASH_DIRECTORY/5
567
+setup: worktree: $here/5
568
+setup: cwd: $here/5
569
setup: prefix: (null)
570
EOF
571
test_repo 5
@@ -573,8 +574,8 @@ EOF
574
test_expect_success '#5: in subdir' '
575
cat >5/sub/expected <<EOF &&
576
setup: git_dir: .git
576
-setup: worktree: $TRASH_DIRECTORY/5
577
-setup: cwd: $TRASH_DIRECTORY/5
577
+setup: worktree: $here/5
578
+setup: cwd: $here/5
579
setup: prefix: sub/
580
EOF
581
test_repo 5/sub
@@ -610,265 +611,265 @@ test_expect_success '#6: setup' '
611
test_expect_success '#6: GIT_DIR(rel), core.worktree=.. at root' '
612
cat >6/expected <<EOF &&
613
setup: git_dir: .git
613
-setup: worktree: $TRASH_DIRECTORY/6
614
-setup: cwd: $TRASH_DIRECTORY/6
614
+setup: worktree: $here/6
615
+setup: cwd: $here/6
616
setup: prefix: (null)
617
EOF
617
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY/6" &&
618
+ git config --file="$here/6/.git/config" core.worktree "$here/6" &&
619
test_repo 6 .git
620
'
621
622
test_expect_success '#6: GIT_DIR(rel), core.worktree=..(rel) at root' '
623
cat >6/expected <<EOF &&
624
setup: git_dir: .git
624
-setup: worktree: $TRASH_DIRECTORY/6
625
-setup: cwd: $TRASH_DIRECTORY/6
625
+setup: worktree: $here/6
626
+setup: cwd: $here/6
627
setup: prefix: (null)
628
EOF
628
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree .. &&
629
+ git config --file="$here/6/.git/config" core.worktree .. &&
630
test_repo 6 .git
631
'
632
633
test_expect_success '#6: GIT_DIR, core.worktree=.. at root' '
634
cat >6/expected <<EOF &&
634
-setup: git_dir: $TRASH_DIRECTORY/6/.git
635
-setup: worktree: $TRASH_DIRECTORY/6
636
-setup: cwd: $TRASH_DIRECTORY/6
635
+setup: git_dir: $here/6/.git
636
+setup: worktree: $here/6
637
+setup: cwd: $here/6
638
setup: prefix: (null)
639
EOF
639
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY/6" &&
640
- test_repo 6 "$TRASH_DIRECTORY/6/.git"
640
+ git config --file="$here/6/.git/config" core.worktree "$here/6" &&
641
+ test_repo 6 "$here/6/.git"
642
'
643
644
test_expect_success '#6: GIT_DIR, core.worktree=..(rel) at root' '
645
cat >6/expected <<EOF &&
645
-setup: git_dir: $TRASH_DIRECTORY/6/.git
646
-setup: worktree: $TRASH_DIRECTORY/6
647
-setup: cwd: $TRASH_DIRECTORY/6
646
+setup: git_dir: $here/6/.git
647
+setup: worktree: $here/6
648
+setup: cwd: $here/6
649
setup: prefix: (null)
650
EOF
650
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree .. &&
651
- test_repo 6 "$TRASH_DIRECTORY/6/.git"
651
+ git config --file="$here/6/.git/config" core.worktree .. &&
652
+ test_repo 6 "$here/6/.git"
653
'
654
655
test_expect_success '#6: GIT_DIR(rel), core.worktree=.. in subdir' '
656
cat >6/sub/sub/expected <<EOF &&
656
-setup: git_dir: $TRASH_DIRECTORY/6/.git
657
-setup: worktree: $TRASH_DIRECTORY/6
658
-setup: cwd: $TRASH_DIRECTORY/6
657
+setup: git_dir: $here/6/.git
658
+setup: worktree: $here/6
659
+setup: cwd: $here/6
660
setup: prefix: sub/sub/
661
EOF
661
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY/6" &&
662
+ git config --file="$here/6/.git/config" core.worktree "$here/6" &&
663
test_repo 6/sub/sub ../../.git
664
'
665
666
test_expect_success '#6: GIT_DIR(rel), core.worktree=..(rel) in subdir' '
667
cat >6/sub/sub/expected <<EOF &&
667
-setup: git_dir: $TRASH_DIRECTORY/6/.git
668
-setup: worktree: $TRASH_DIRECTORY/6
669
-setup: cwd: $TRASH_DIRECTORY/6
668
+setup: git_dir: $here/6/.git
669
+setup: worktree: $here/6
670
+setup: cwd: $here/6
671
setup: prefix: sub/sub/
672
EOF
672
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree .. &&
673
+ git config --file="$here/6/.git/config" core.worktree .. &&
674
test_repo 6/sub/sub ../../.git
675
'
676
677
test_expect_success '#6: GIT_DIR, core.worktree=.. in subdir' '
678
cat >6/sub/expected <<EOF &&
678
-setup: git_dir: $TRASH_DIRECTORY/6/.git
679
-setup: worktree: $TRASH_DIRECTORY/6
680
-setup: cwd: $TRASH_DIRECTORY/6
679
+setup: git_dir: $here/6/.git
680
+setup: worktree: $here/6
681
+setup: cwd: $here/6
682
setup: prefix: sub/
683
EOF
683
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY/6" &&
684
- test_repo 6/sub "$TRASH_DIRECTORY/6/.git"
684
+ git config --file="$here/6/.git/config" core.worktree "$here/6" &&
685
+ test_repo 6/sub "$here/6/.git"
686
'
687
688
test_expect_success '#6: GIT_DIR, core.worktree=..(rel) in subdir' '
689
cat >6/sub/sub/expected <<EOF &&
689
-setup: git_dir: $TRASH_DIRECTORY/6/.git
690
-setup: worktree: $TRASH_DIRECTORY/6
691
-setup: cwd: $TRASH_DIRECTORY/6
690
+setup: git_dir: $here/6/.git
691
+setup: worktree: $here/6
692
+setup: cwd: $here/6
693
setup: prefix: sub/sub/
694
EOF
694
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree .. &&
695
- test_repo 6/sub/sub "$TRASH_DIRECTORY/6/.git"
695
+ git config --file="$here/6/.git/config" core.worktree .. &&
696
+ test_repo 6/sub/sub "$here/6/.git"
697
'
698
699
test_expect_success '#6: GIT_DIR(rel), core.worktree=../wt at root' '
700
cat >6/expected <<EOF &&
701
setup: git_dir: .git
701
-setup: worktree: $TRASH_DIRECTORY/6/wt
702
-setup: cwd: $TRASH_DIRECTORY/6
702
+setup: worktree: $here/6/wt
703
+setup: cwd: $here/6
704
setup: prefix: (null)
705
EOF
705
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY/6/wt" &&
706
+ git config --file="$here/6/.git/config" core.worktree "$here/6/wt" &&
707
test_repo 6 .git
708
'
709
710
test_expect_success '#6: GIT_DIR(rel), core.worktree=../wt(rel) at root' '
711
cat >6/expected <<EOF &&
712
setup: git_dir: .git
712
-setup: worktree: $TRASH_DIRECTORY/6/wt
713
-setup: cwd: $TRASH_DIRECTORY/6
713
+setup: worktree: $here/6/wt
714
+setup: cwd: $here/6
715
setup: prefix: (null)
716
EOF
716
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree ../wt &&
717
+ git config --file="$here/6/.git/config" core.worktree ../wt &&
718
test_repo 6 .git
719
'
720
721
test_expect_success '#6: GIT_DIR, core.worktree=../wt(rel) at root' '
722
cat >6/expected <<EOF &&
722
-setup: git_dir: $TRASH_DIRECTORY/6/.git
723
-setup: worktree: $TRASH_DIRECTORY/6/wt
724
-setup: cwd: $TRASH_DIRECTORY/6
723
+setup: git_dir: $here/6/.git
724
+setup: worktree: $here/6/wt
725
+setup: cwd: $here/6
726
setup: prefix: (null)
727
EOF
727
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree ../wt &&
728
- test_repo 6 "$TRASH_DIRECTORY/6/.git"
728
+ git config --file="$here/6/.git/config" core.worktree ../wt &&
729
+ test_repo 6 "$here/6/.git"
730
'
731
732
test_expect_success '#6: GIT_DIR, core.worktree=../wt at root' '
733
cat >6/expected <<EOF &&
733
-setup: git_dir: $TRASH_DIRECTORY/6/.git
734
-setup: worktree: $TRASH_DIRECTORY/6/wt
735
-setup: cwd: $TRASH_DIRECTORY/6
734
+setup: git_dir: $here/6/.git
735
+setup: worktree: $here/6/wt
736
+setup: cwd: $here/6
737
setup: prefix: (null)
738
EOF
738
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY/6/wt" &&
739
- test_repo 6 "$TRASH_DIRECTORY/6/.git"
739
+ git config --file="$here/6/.git/config" core.worktree "$here/6/wt" &&
740
+ test_repo 6 "$here/6/.git"
741
'
742
743
test_expect_success '#6: GIT_DIR(rel), core.worktree=../wt in subdir' '
744
cat >6/sub/sub/expected <<EOF &&
745
setup: git_dir: ../../.git
745
-setup: worktree: $TRASH_DIRECTORY/6/wt
746
-setup: cwd: $TRASH_DIRECTORY/6/sub/sub
746
+setup: worktree: $here/6/wt
747
+setup: cwd: $here/6/sub/sub
748
setup: prefix: (null)
749
EOF
749
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY/6/wt" &&
750
+ git config --file="$here/6/.git/config" core.worktree "$here/6/wt" &&
751
test_repo 6/sub/sub ../../.git
752
'
753
754
test_expect_success '#6: GIT_DIR(rel), core.worktree=../wt(rel) in subdir' '
755
cat >6/sub/sub/expected <<EOF &&
756
setup: git_dir: ../../.git
756
-setup: worktree: $TRASH_DIRECTORY/6/wt
757
-setup: cwd: $TRASH_DIRECTORY/6/sub/sub
757
+setup: worktree: $here/6/wt
758
+setup: cwd: $here/6/sub/sub
759
setup: prefix: (null)
760
EOF
760
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree ../wt &&
761
+ git config --file="$here/6/.git/config" core.worktree ../wt &&
762
test_repo 6/sub/sub ../../.git
763
'
764
765
test_expect_success '#6: GIT_DIR, core.worktree=../wt(rel) in subdir' '
766
cat >6/sub/sub/expected <<EOF &&
766
-setup: git_dir: $TRASH_DIRECTORY/6/.git
767
-setup: worktree: $TRASH_DIRECTORY/6/wt
768
-setup: cwd: $TRASH_DIRECTORY/6/sub/sub
767
+setup: git_dir: $here/6/.git
768
+setup: worktree: $here/6/wt
769
+setup: cwd: $here/6/sub/sub
770
setup: prefix: (null)
771
EOF
771
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree ../wt &&
772
- test_repo 6/sub/sub "$TRASH_DIRECTORY/6/.git"
772
+ git config --file="$here/6/.git/config" core.worktree ../wt &&
773
+ test_repo 6/sub/sub "$here/6/.git"
774
'
775
776
test_expect_success '#6: GIT_DIR, core.worktree=../wt in subdir' '
777
cat >6/sub/sub/expected <<EOF &&
777
-setup: git_dir: $TRASH_DIRECTORY/6/.git
778
-setup: worktree: $TRASH_DIRECTORY/6/wt
779
-setup: cwd: $TRASH_DIRECTORY/6/sub/sub
778
+setup: git_dir: $here/6/.git
779
+setup: worktree: $here/6/wt
780
+setup: cwd: $here/6/sub/sub
781
setup: prefix: (null)
782
EOF
782
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY/6/wt" &&
783
- test_repo 6/sub/sub "$TRASH_DIRECTORY/6/.git"
783
+ git config --file="$here/6/.git/config" core.worktree "$here/6/wt" &&
784
+ test_repo 6/sub/sub "$here/6/.git"
785
'
786
787
test_expect_success '#6: GIT_DIR(rel), core.worktree=../.. at root' '
788
cat >6/expected <<EOF &&
788
-setup: git_dir: $TRASH_DIRECTORY/6/.git
789
-setup: worktree: $TRASH_DIRECTORY
790
-setup: cwd: $TRASH_DIRECTORY
789
+setup: git_dir: $here/6/.git
790
+setup: worktree: $here
791
+setup: cwd: $here
792
setup: prefix: 6/
793
EOF
793
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY" &&
794
+ git config --file="$here/6/.git/config" core.worktree "$here" &&
795
test_repo 6 .git
796
'
797
798
test_expect_success '#6: GIT_DIR(rel), core.worktree=../..(rel) at root' '
799
cat >6/expected <<EOF &&
799
-setup: git_dir: $TRASH_DIRECTORY/6/.git
800
-setup: worktree: $TRASH_DIRECTORY
801
-setup: cwd: $TRASH_DIRECTORY
800
+setup: git_dir: $here/6/.git
801
+setup: worktree: $here
802
+setup: cwd: $here
803
setup: prefix: 6/
804
EOF
804
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree ../../ &&
805
+ git config --file="$here/6/.git/config" core.worktree ../../ &&
806
test_repo 6 .git
807
'
808
809
test_expect_success '#6: GIT_DIR, core.worktree=../..(rel) at root' '
810
cat >6/expected <<EOF &&
810
-setup: git_dir: $TRASH_DIRECTORY/6/.git
811
-setup: worktree: $TRASH_DIRECTORY
812
-setup: cwd: $TRASH_DIRECTORY
811
+setup: git_dir: $here/6/.git
812
+setup: worktree: $here
813
+setup: cwd: $here
814
setup: prefix: 6/
815
EOF
815
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree ../../ &&
816
- test_repo 6 "$TRASH_DIRECTORY/6/.git"
816
+ git config --file="$here/6/.git/config" core.worktree ../../ &&
817
+ test_repo 6 "$here/6/.git"
818
'
819
820
test_expect_success '#6: GIT_DIR, core.worktree=../.. at root' '
821
cat >6/expected <<EOF &&
821
-setup: git_dir: $TRASH_DIRECTORY/6/.git
822
-setup: worktree: $TRASH_DIRECTORY
823
-setup: cwd: $TRASH_DIRECTORY
822
+setup: git_dir: $here/6/.git
823
+setup: worktree: $here
824
+setup: cwd: $here
825
setup: prefix: 6/
826
EOF
826
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY" &&
827
- test_repo 6 "$TRASH_DIRECTORY/6/.git"
827
+ git config --file="$here/6/.git/config" core.worktree "$here" &&
828
+ test_repo 6 "$here/6/.git"
829
'
830
831
test_expect_success '#6: GIT_DIR(rel), core.worktree=../.. in subdir' '
832
cat >6/sub/sub/expected <<EOF &&
832
-setup: git_dir: $TRASH_DIRECTORY/6/.git
833
-setup: worktree: $TRASH_DIRECTORY
834
-setup: cwd: $TRASH_DIRECTORY
833
+setup: git_dir: $here/6/.git
834
+setup: worktree: $here
835
+setup: cwd: $here
836
setup: prefix: 6/sub/sub/
837
EOF
837
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY" &&
838
+ git config --file="$here/6/.git/config" core.worktree "$here" &&
839
test_repo 6/sub/sub ../../.git
840
'
841
842
test_expect_success '#6: GIT_DIR(rel), core.worktree=../..(rel) in subdir' '
843
cat >6/sub/sub/expected <<EOF &&
843
-setup: git_dir: $TRASH_DIRECTORY/6/.git
844
-setup: worktree: $TRASH_DIRECTORY
845
-setup: cwd: $TRASH_DIRECTORY
844
+setup: git_dir: $here/6/.git
845
+setup: worktree: $here
846
+setup: cwd: $here
847
setup: prefix: 6/sub/sub/
848
EOF
848
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree ../.. &&
849
+ git config --file="$here/6/.git/config" core.worktree ../.. &&
850
test_repo 6/sub/sub ../../.git
851
'
852
853
test_expect_success '#6: GIT_DIR, core.worktree=../..(rel) in subdir' '
854
cat >6/sub/sub/expected <<EOF &&
854
-setup: git_dir: $TRASH_DIRECTORY/6/.git
855
-setup: worktree: $TRASH_DIRECTORY
856
-setup: cwd: $TRASH_DIRECTORY
855
+setup: git_dir: $here/6/.git
856
+setup: worktree: $here
857
+setup: cwd: $here
858
setup: prefix: 6/sub/sub/
859
EOF
859
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree ../.. &&
860
- test_repo 6/sub/sub "$TRASH_DIRECTORY/6/.git"
860
+ git config --file="$here/6/.git/config" core.worktree ../.. &&
861
+ test_repo 6/sub/sub "$here/6/.git"
862
'
863
864
test_expect_success '#6: GIT_DIR, core.worktree=../.. in subdir' '
865
cat >6/sub/sub/expected <<EOF &&
865
-setup: git_dir: $TRASH_DIRECTORY/6/.git
866
-setup: worktree: $TRASH_DIRECTORY
867
-setup: cwd: $TRASH_DIRECTORY
866
+setup: git_dir: $here/6/.git
867
+setup: worktree: $here
868
+setup: cwd: $here
869
setup: prefix: 6/sub/sub/
870
EOF
870
- git config --file="$TRASH_DIRECTORY/6/.git/config" core.worktree "$TRASH_DIRECTORY" &&
871
- test_repo 6/sub/sub "$TRASH_DIRECTORY/6/.git"
871
+ git config --file="$here/6/.git/config" core.worktree "$here" &&
872
+ test_repo 6/sub/sub "$here/6/.git"
873
'
874
875
#
@@ -900,18 +901,18 @@ test_expect_success '#7: setup' '
901
test_expect_success '#7: GIT_DIR(rel), GIT_WORK_TREE=root at root' '
902
cat >7/expected <<EOF &&
903
setup: git_dir: .git
903
-setup: worktree: $TRASH_DIRECTORY/7
904
-setup: cwd: $TRASH_DIRECTORY/7
904
+setup: worktree: $here/7
905
+setup: cwd: $here/7
906
setup: prefix: (null)
907
EOF
907
- test_repo 7 .git "$TRASH_DIRECTORY/7"
908
+ test_repo 7 .git "$here/7"
909
'
910
911
test_expect_success '#7: GIT_DIR(rel), GIT_WORK_TREE=root(rel) at root' '
912
cat >7/expected <<EOF &&
913
setup: git_dir: .git
913
-setup: worktree: $TRASH_DIRECTORY/7
914
-setup: cwd: $TRASH_DIRECTORY/7
914
+setup: worktree: $here/7
915
+setup: cwd: $here/7
916
setup: prefix: (null)
917
EOF
918
test_repo 7 .git .
@@ -919,39 +920,39 @@ EOF
920
921
test_expect_success '#7: GIT_DIR, GIT_WORK_TREE=root at root' '
922
cat >7/expected <<EOF &&
922
-setup: git_dir: $TRASH_DIRECTORY/7/.git
923
-setup: worktree: $TRASH_DIRECTORY/7
924
-setup: cwd: $TRASH_DIRECTORY/7
923
+setup: git_dir: $here/7/.git
924
+setup: worktree: $here/7
925
+setup: cwd: $here/7
926
setup: prefix: (null)
927
EOF
927
- test_repo 7 "$TRASH_DIRECTORY/7/.git" "$TRASH_DIRECTORY/7"
928
+ test_repo 7 "$here/7/.git" "$here/7"
929
'
930
931
test_expect_success '#7: GIT_DIR, GIT_WORK_TREE=root(rel) at root' '
932
cat >7/expected <<EOF &&
932
-setup: git_dir: $TRASH_DIRECTORY/7/.git
933
-setup: worktree: $TRASH_DIRECTORY/7
934
-setup: cwd: $TRASH_DIRECTORY/7
933
+setup: git_dir: $here/7/.git
934
+setup: worktree: $here/7
935
+setup: cwd: $here/7
936
setup: prefix: (null)
937
EOF
937
- test_repo 7 "$TRASH_DIRECTORY/7/.git" .
938
+ test_repo 7 "$here/7/.git" .
939
'
940
941
test_expect_success '#7: GIT_DIR(rel), GIT_WORKTREE=root in subdir' '
942
cat >7/sub/sub/expected <<EOF &&
942
-setup: git_dir: $TRASH_DIRECTORY/7/.git
943
-setup: worktree: $TRASH_DIRECTORY/7
944
-setup: cwd: $TRASH_DIRECTORY/7
943
+setup: git_dir: $here/7/.git
944
+setup: worktree: $here/7
945
+setup: cwd: $here/7
946
setup: prefix: sub/sub/
947
EOF
947
- test_repo 7/sub/sub ../../.git "$TRASH_DIRECTORY/7"
948
+ test_repo 7/sub/sub ../../.git "$here/7"
949
'
950
951
test_expect_success '#7: GIT_DIR(rel), GIT_WORKTREE=root(rel) in subdir' '
952
cat >7/sub/sub/expected <<EOF &&
952
-setup: git_dir: $TRASH_DIRECTORY/7/.git
953
-setup: worktree: $TRASH_DIRECTORY/7
954
-setup: cwd: $TRASH_DIRECTORY/7
953
+setup: git_dir: $here/7/.git
954
+setup: worktree: $here/7
955
+setup: cwd: $here/7
956
setup: prefix: sub/sub/
957
EOF
958
test_repo 7/sub/sub ../../.git ../..
@@ -959,39 +960,39 @@ EOF
960
961
test_expect_success '#7: GIT_DIR, GIT_WORKTREE=root in subdir' '
962
cat >7/sub/expected <<EOF &&
962
-setup: git_dir: $TRASH_DIRECTORY/7/.git
963
-setup: worktree: $TRASH_DIRECTORY/7
964
-setup: cwd: $TRASH_DIRECTORY/7
963
+setup: git_dir: $here/7/.git
964
+setup: worktree: $here/7
965
+setup: cwd: $here/7
966
setup: prefix: sub/
967
EOF
967
- test_repo 7/sub "$TRASH_DIRECTORY/7/.git" "$TRASH_DIRECTORY/7"
968
+ test_repo 7/sub "$here/7/.git" "$here/7"
969
'
970
971
test_expect_success '#7: GIT_DIR, GIT_WORKTREE=root(rel) in subdir' '
972
cat >7/sub/sub/expected <<EOF &&
972
-setup: git_dir: $TRASH_DIRECTORY/7/.git
973
-setup: worktree: $TRASH_DIRECTORY/7
974
-setup: cwd: $TRASH_DIRECTORY/7
973
+setup: git_dir: $here/7/.git
974
+setup: worktree: $here/7
975
+setup: cwd: $here/7
976
setup: prefix: sub/sub/
977
EOF
977
- test_repo 7/sub/sub "$TRASH_DIRECTORY/7/.git" ../..
978
+ test_repo 7/sub/sub "$here/7/.git" ../..
979
'
980
981
test_expect_success '#7: GIT_DIR(rel), GIT_WORK_TREE=wt at root' '
982
cat >7/expected <<EOF &&
983
setup: git_dir: .git
983
-setup: worktree: $TRASH_DIRECTORY/7/wt
984
-setup: cwd: $TRASH_DIRECTORY/7
984
+setup: worktree: $here/7/wt
985
+setup: cwd: $here/7
986
setup: prefix: (null)
987
EOF
987
- test_repo 7 .git "$TRASH_DIRECTORY/7/wt"
988
+ test_repo 7 .git "$here/7/wt"
989
'
990
991
test_expect_success '#7: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) at root' '
992
cat >7/expected <<EOF &&
993
setup: git_dir: .git
993
-setup: worktree: $TRASH_DIRECTORY/7/wt
994
-setup: cwd: $TRASH_DIRECTORY/7
994
+setup: worktree: $here/7/wt
995
+setup: cwd: $here/7
996
setup: prefix: (null)
997
EOF
998
test_repo 7 .git wt
@@ -999,39 +1000,39 @@ EOF
1000
1001
test_expect_success '#7: GIT_DIR, GIT_WORK_TREE=wt(rel) at root' '
1002
cat >7/expected <<EOF &&
1002
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1003
-setup: worktree: $TRASH_DIRECTORY/7/wt
1004
-setup: cwd: $TRASH_DIRECTORY/7
1003
+setup: git_dir: $here/7/.git
1004
+setup: worktree: $here/7/wt
1005
+setup: cwd: $here/7
1006
setup: prefix: (null)
1007
EOF
1007
- test_repo 7 "$TRASH_DIRECTORY/7/.git" wt
1008
+ test_repo 7 "$here/7/.git" wt
1009
'
1010
1011
test_expect_success '#7: GIT_DIR, GIT_WORK_TREE=wt at root' '
1012
cat >7/expected <<EOF &&
1012
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1013
-setup: worktree: $TRASH_DIRECTORY/7/wt
1014
-setup: cwd: $TRASH_DIRECTORY/7
1013
+setup: git_dir: $here/7/.git
1014
+setup: worktree: $here/7/wt
1015
+setup: cwd: $here/7
1016
setup: prefix: (null)
1017
EOF
1017
- test_repo 7 "$TRASH_DIRECTORY/7/.git" "$TRASH_DIRECTORY/7/wt"
1018
+ test_repo 7 "$here/7/.git" "$here/7/wt"
1019
'
1020
1021
test_expect_success '#7: GIT_DIR(rel), GIT_WORK_TREE=wt in subdir' '
1022
cat >7/sub/sub/expected <<EOF &&
1023
setup: git_dir: ../../.git
1023
-setup: worktree: $TRASH_DIRECTORY/7/wt
1024
-setup: cwd: $TRASH_DIRECTORY/7/sub/sub
1024
+setup: worktree: $here/7/wt
1025
+setup: cwd: $here/7/sub/sub
1026
setup: prefix: (null)
1027
EOF
1027
- test_repo 7/sub/sub ../../.git "$TRASH_DIRECTORY/7/wt"
1028
+ test_repo 7/sub/sub ../../.git "$here/7/wt"
1029
'
1030
1031
test_expect_success '#7: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) in subdir' '
1032
cat >7/sub/sub/expected <<EOF &&
1033
setup: git_dir: ../../.git
1033
-setup: worktree: $TRASH_DIRECTORY/7/wt
1034
-setup: cwd: $TRASH_DIRECTORY/7/sub/sub
1034
+setup: worktree: $here/7/wt
1035
+setup: cwd: $here/7/sub/sub
1036
setup: prefix: (null)
1037
EOF
1038
test_repo 7/sub/sub ../../.git ../../wt
@@ -1039,39 +1040,39 @@ EOF
1040
1041
test_expect_success '#7: GIT_DIR, GIT_WORK_TREE=wt(rel) in subdir' '
1042
cat >7/sub/sub/expected <<EOF &&
1042
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1043
-setup: worktree: $TRASH_DIRECTORY/7/wt
1044
-setup: cwd: $TRASH_DIRECTORY/7/sub/sub
1043
+setup: git_dir: $here/7/.git
1044
+setup: worktree: $here/7/wt
1045
+setup: cwd: $here/7/sub/sub
1046
setup: prefix: (null)
1047
EOF
1047
- test_repo 7/sub/sub "$TRASH_DIRECTORY/7/.git" ../../wt
1048
+ test_repo 7/sub/sub "$here/7/.git" ../../wt
1049
'
1050
1051
test_expect_success '#7: GIT_DIR, GIT_WORK_TREE=wt in subdir' '
1052
cat >7/sub/sub/expected <<EOF &&
1052
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1053
-setup: worktree: $TRASH_DIRECTORY/7/wt
1054
-setup: cwd: $TRASH_DIRECTORY/7/sub/sub
1053
+setup: git_dir: $here/7/.git
1054
+setup: worktree: $here/7/wt
1055
+setup: cwd: $here/7/sub/sub
1056
setup: prefix: (null)
1057
EOF
1057
- test_repo 7/sub/sub "$TRASH_DIRECTORY/7/.git" "$TRASH_DIRECTORY/7/wt"
1058
+ test_repo 7/sub/sub "$here/7/.git" "$here/7/wt"
1059
'
1060
1061
test_expect_success '#7: GIT_DIR(rel), GIT_WORK_TREE=.. at root' '
1062
cat >7/expected <<EOF &&
1062
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1063
-setup: worktree: $TRASH_DIRECTORY
1064
-setup: cwd: $TRASH_DIRECTORY
1063
+setup: git_dir: $here/7/.git
1064
+setup: worktree: $here
1065
+setup: cwd: $here
1066
setup: prefix: 7/
1067
EOF
1067
- test_repo 7 .git "$TRASH_DIRECTORY"
1068
+ test_repo 7 .git "$here"
1069
'
1070
1071
test_expect_success '#7: GIT_DIR(rel), GIT_WORK_TREE=..(rel) at root' '
1072
cat >7/expected <<EOF &&
1072
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1073
-setup: worktree: $TRASH_DIRECTORY
1074
-setup: cwd: $TRASH_DIRECTORY
1073
+setup: git_dir: $here/7/.git
1074
+setup: worktree: $here
1075
+setup: cwd: $here
1076
setup: prefix: 7/
1077
EOF
1078
test_repo 7 .git ..
@@ -1079,39 +1080,39 @@ EOF
1080
1081
test_expect_success '#7: GIT_DIR, GIT_WORK_TREE=..(rel) at root' '
1082
cat >7/expected <<EOF &&
1082
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1083
-setup: worktree: $TRASH_DIRECTORY
1084
-setup: cwd: $TRASH_DIRECTORY
1083
+setup: git_dir: $here/7/.git
1084
+setup: worktree: $here
1085
+setup: cwd: $here
1086
setup: prefix: 7/
1087
EOF
1087
- test_repo 7 "$TRASH_DIRECTORY/7/.git" ..
1088
+ test_repo 7 "$here/7/.git" ..
1089
'
1090
1091
test_expect_success '#7: GIT_DIR, GIT_WORK_TREE=.. at root' '
1092
cat >7/expected <<EOF &&
1092
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1093
-setup: worktree: $TRASH_DIRECTORY
1094
-setup: cwd: $TRASH_DIRECTORY
1093
+setup: git_dir: $here/7/.git
1094
+setup: worktree: $here
1095
+setup: cwd: $here
1096
setup: prefix: 7/
1097
EOF
1097
- test_repo 7 "$TRASH_DIRECTORY/7/.git" "$TRASH_DIRECTORY"
1098
+ test_repo 7 "$here/7/.git" "$here"
1099
'
1100
1101
test_expect_success '#7: GIT_DIR(rel), GIT_WORK_TREE=.. in subdir' '
1102
cat >7/sub/sub/expected <<EOF &&
1102
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1103
-setup: worktree: $TRASH_DIRECTORY
1104
-setup: cwd: $TRASH_DIRECTORY
1103
+setup: git_dir: $here/7/.git
1104
+setup: worktree: $here
1105
+setup: cwd: $here
1106
setup: prefix: 7/sub/sub/
1107
EOF
1107
- test_repo 7/sub/sub ../../.git "$TRASH_DIRECTORY"
1108
+ test_repo 7/sub/sub ../../.git "$here"
1109
'
1110
1111
test_expect_success '#7: GIT_DIR(rel), GIT_WORK_TREE=..(rel) in subdir' '
1112
cat >7/sub/sub/expected <<EOF &&
1112
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1113
-setup: worktree: $TRASH_DIRECTORY
1114
-setup: cwd: $TRASH_DIRECTORY
1113
+setup: git_dir: $here/7/.git
1114
+setup: worktree: $here
1115
+setup: cwd: $here
1116
setup: prefix: 7/sub/sub/
1117
EOF
1118
test_repo 7/sub/sub ../../.git ../../..
@@ -1119,22 +1120,22 @@ EOF
1120
1121
test_expect_success '#7: GIT_DIR, GIT_WORK_TREE=..(rel) in subdir' '
1122
cat >7/sub/sub/expected <<EOF &&
1122
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1123
-setup: worktree: $TRASH_DIRECTORY
1124
-setup: cwd: $TRASH_DIRECTORY
1123
+setup: git_dir: $here/7/.git
1124
+setup: worktree: $here
1125
+setup: cwd: $here
1126
setup: prefix: 7/sub/sub/
1127
EOF
1127
- test_repo 7/sub/sub "$TRASH_DIRECTORY/7/.git" ../../../
1128
+ test_repo 7/sub/sub "$here/7/.git" ../../../
1129
'
1130
1131
test_expect_success '#7: GIT_DIR, GIT_WORK_TREE=.. in subdir' '
1132
cat >7/sub/sub/expected <<EOF &&
1132
-setup: git_dir: $TRASH_DIRECTORY/7/.git
1133
-setup: worktree: $TRASH_DIRECTORY
1134
-setup: cwd: $TRASH_DIRECTORY
1133
+setup: git_dir: $here/7/.git
1134
+setup: worktree: $here
1135
+setup: cwd: $here
1136
setup: prefix: 7/sub/sub/
1137
EOF
1137
- test_repo 7/sub/sub "$TRASH_DIRECTORY/7/.git" "$TRASH_DIRECTORY"
1138
+ test_repo 7/sub/sub "$here/7/.git" "$here"
1139
'
1140
1141
#
@@ -1166,9 +1167,9 @@ test_expect_success '#8: setup' '
1167
1168
test_expect_success '#8: at root' '
1169
cat >8/expected <<EOF &&
1169
-setup: git_dir: $TRASH_DIRECTORY/8.git
1170
-setup: worktree: $TRASH_DIRECTORY/8
1171
-setup: cwd: $TRASH_DIRECTORY/8
1170
+setup: git_dir: $here/8.git
1171
+setup: worktree: $here/8
1172
+setup: cwd: $here/8
1173
setup: prefix: (null)
1174
EOF
1175
test_repo 8
@@ -1176,9 +1177,9 @@ EOF
1177
1178
test_expect_success '#8: in subdir' '
1179
cat >8/sub/expected <<EOF &&
1179
-setup: git_dir: $TRASH_DIRECTORY/8.git
1180
-setup: worktree: $TRASH_DIRECTORY/8
1181
-setup: cwd: $TRASH_DIRECTORY/8
1180
+setup: git_dir: $here/8.git
1181
+setup: worktree: $here/8
1182
+setup: cwd: $here/8
1183
setup: prefix: sub/
1184
EOF
1185
test_repo 8/sub
@@ -1215,9 +1216,9 @@ test_expect_success '#9: setup' '
1216
1217
test_expect_success '#9: at root' '
1218
cat >9/expected <<EOF &&
1218
-setup: git_dir: $TRASH_DIRECTORY/9.git
1219
-setup: worktree: $TRASH_DIRECTORY/9
1220
-setup: cwd: $TRASH_DIRECTORY/9
1219
+setup: git_dir: $here/9.git
1220
+setup: worktree: $here/9
1221
+setup: cwd: $here/9
1222
setup: prefix: (null)
1223
EOF
1224
test_repo 9
@@ -1225,9 +1226,9 @@ EOF
1226
1227
test_expect_success '#9: in subdir' '
1228
cat >9/sub/expected <<EOF &&
1228
-setup: git_dir: $TRASH_DIRECTORY/9.git
1229
-setup: worktree: $TRASH_DIRECTORY/9
1230
-setup: cwd: $TRASH_DIRECTORY/9
1229
+setup: git_dir: $here/9.git
1230
+setup: worktree: $here/9
1231
+setup: cwd: $here/9
1232
setup: prefix: sub/
1233
EOF
1234
test_repo 9/sub
@@ -1262,29 +1263,29 @@ test_expect_success '#10: setup' '
1263
1264
test_expect_success '#10: at root' '
1265
cat >10/expected <<EOF &&
1265
-setup: git_dir: $TRASH_DIRECTORY/10.git
1266
-setup: worktree: $TRASH_DIRECTORY/10
1267
-setup: cwd: $TRASH_DIRECTORY/10
1266
+setup: git_dir: $here/10.git
1267
+setup: worktree: $here/10
1268
+setup: cwd: $here/10
1269
setup: prefix: (null)
1270
EOF
1270
- test_repo 10 "$TRASH_DIRECTORY/10/.git"
1271
+ test_repo 10 "$here/10/.git"
1272
'
1273
1274
test_expect_success '#10: in subdir' '
1275
cat >10/sub/expected <<EOF &&
1275
-setup: git_dir: $TRASH_DIRECTORY/10.git
1276
-setup: worktree: $TRASH_DIRECTORY/10/sub
1277
-setup: cwd: $TRASH_DIRECTORY/10/sub
1276
+setup: git_dir: $here/10.git
1277
+setup: worktree: $here/10/sub
1278
+setup: cwd: $here/10/sub
1279
setup: prefix: (null)
1280
EOF
1280
- test_repo 10/sub "$TRASH_DIRECTORY/10/.git"
1281
+ test_repo 10/sub "$here/10/.git"
1282
'
1283
1284
test_expect_success '#10: relative GIT_DIR at root' '
1285
cat >10/expected <<EOF &&
1285
-setup: git_dir: $TRASH_DIRECTORY/10.git
1286
-setup: worktree: $TRASH_DIRECTORY/10
1287
-setup: cwd: $TRASH_DIRECTORY/10
1286
+setup: git_dir: $here/10.git
1287
+setup: worktree: $here/10
1288
+setup: cwd: $here/10
1289
setup: prefix: (null)
1290
EOF
1291
test_repo 10 .git
@@ -1292,9 +1293,9 @@ EOF
1293
1294
test_expect_success '#10: relative GIT_DIR in subdir' '
1295
cat >10/sub/expected <<EOF &&
1295
-setup: git_dir: $TRASH_DIRECTORY/10.git
1296
-setup: worktree: $TRASH_DIRECTORY/10/sub
1297
-setup: cwd: $TRASH_DIRECTORY/10/sub
1296
+setup: git_dir: $here/10.git
1297
+setup: worktree: $here/10/sub
1298
+setup: cwd: $here/10/sub
1299
setup: prefix: (null)
1300
EOF
1301
test_repo 10/sub ../.git
@@ -1329,19 +1330,19 @@ test_expect_success '#11: setup' '
1330
1331
test_expect_success '#11: GIT_DIR(rel), GIT_WORK_TREE=root at root' '
1332
cat >11/expected <<EOF &&
1332
-setup: git_dir: $TRASH_DIRECTORY/11.git
1333
-setup: worktree: $TRASH_DIRECTORY/11
1334
-setup: cwd: $TRASH_DIRECTORY/11
1333
+setup: git_dir: $here/11.git
1334
+setup: worktree: $here/11
1335
+setup: cwd: $here/11
1336
setup: prefix: (null)
1337
EOF
1337
- test_repo 11 .git "$TRASH_DIRECTORY/11"
1338
+ test_repo 11 .git "$here/11"
1339
'
1340
1341
test_expect_success '#11: GIT_DIR(rel), GIT_WORK_TREE=root(rel) at root' '
1342
cat >11/expected <<EOF &&
1342
-setup: git_dir: $TRASH_DIRECTORY/11.git
1343
-setup: worktree: $TRASH_DIRECTORY/11
1344
-setup: cwd: $TRASH_DIRECTORY/11
1343
+setup: git_dir: $here/11.git
1344
+setup: worktree: $here/11
1345
+setup: cwd: $here/11
1346
setup: prefix: (null)
1347
EOF
1348
test_repo 11 .git .
@@ -1349,39 +1350,39 @@ EOF
1350
1351
test_expect_success '#11: GIT_DIR, GIT_WORK_TREE=root at root' '
1352
cat >11/expected <<EOF &&
1352
-setup: git_dir: $TRASH_DIRECTORY/11.git
1353
-setup: worktree: $TRASH_DIRECTORY/11
1354
-setup: cwd: $TRASH_DIRECTORY/11
1353
+setup: git_dir: $here/11.git
1354
+setup: worktree: $here/11
1355
+setup: cwd: $here/11
1356
setup: prefix: (null)
1357
EOF
1357
- test_repo 11 "$TRASH_DIRECTORY/11/.git" "$TRASH_DIRECTORY/11"
1358
+ test_repo 11 "$here/11/.git" "$here/11"
1359
'
1360
1361
test_expect_success '#11: GIT_DIR, GIT_WORK_TREE=root(rel) at root' '
1362
cat >11/expected <<EOF &&
1362
-setup: git_dir: $TRASH_DIRECTORY/11.git
1363
-setup: worktree: $TRASH_DIRECTORY/11
1364
-setup: cwd: $TRASH_DIRECTORY/11
1363
+setup: git_dir: $here/11.git
1364
+setup: worktree: $here/11
1365
+setup: cwd: $here/11
1366
setup: prefix: (null)
1367
EOF
1367
- test_repo 11 "$TRASH_DIRECTORY/11/.git" .
1368
+ test_repo 11 "$here/11/.git" .
1369
'
1370
1371
test_expect_success '#11: GIT_DIR(rel), GIT_WORKTREE=root in subdir' '
1372
cat >11/sub/sub/expected <<EOF &&
1372
-setup: git_dir: $TRASH_DIRECTORY/11.git
1373
-setup: worktree: $TRASH_DIRECTORY/11
1374
-setup: cwd: $TRASH_DIRECTORY/11
1373
+setup: git_dir: $here/11.git
1374
+setup: worktree: $here/11
1375
+setup: cwd: $here/11
1376
setup: prefix: sub/sub/
1377
EOF
1377
- test_repo 11/sub/sub ../../.git "$TRASH_DIRECTORY/11"
1378
+ test_repo 11/sub/sub ../../.git "$here/11"
1379
'
1380
1381
test_expect_success '#11: GIT_DIR(rel), GIT_WORKTREE=root(rel) in subdir' '
1382
cat >11/sub/sub/expected <<EOF &&
1382
-setup: git_dir: $TRASH_DIRECTORY/11.git
1383
-setup: worktree: $TRASH_DIRECTORY/11
1384
-setup: cwd: $TRASH_DIRECTORY/11
1383
+setup: git_dir: $here/11.git
1384
+setup: worktree: $here/11
1385
+setup: cwd: $here/11
1386
setup: prefix: sub/sub/
1387
EOF
1388
test_repo 11/sub/sub ../../.git ../..
@@ -1389,39 +1390,39 @@ EOF
1390
1391
test_expect_success '#11: GIT_DIR, GIT_WORKTREE=root in subdir' '
1392
cat >11/sub/expected <<EOF &&
1392
-setup: git_dir: $TRASH_DIRECTORY/11.git
1393
-setup: worktree: $TRASH_DIRECTORY/11
1394
-setup: cwd: $TRASH_DIRECTORY/11
1393
+setup: git_dir: $here/11.git
1394
+setup: worktree: $here/11
1395
+setup: cwd: $here/11
1396
setup: prefix: sub/
1397
EOF
1397
- test_repo 11/sub "$TRASH_DIRECTORY/11/.git" "$TRASH_DIRECTORY/11"
1398
+ test_repo 11/sub "$here/11/.git" "$here/11"
1399
'
1400
1401
test_expect_success '#11: GIT_DIR, GIT_WORKTREE=root(rel) in subdir' '
1402
cat >11/sub/sub/expected <<EOF &&
1402
-setup: git_dir: $TRASH_DIRECTORY/11.git
1403
-setup: worktree: $TRASH_DIRECTORY/11
1404
-setup: cwd: $TRASH_DIRECTORY/11
1403
+setup: git_dir: $here/11.git
1404
+setup: worktree: $here/11
1405
+setup: cwd: $here/11
1406
setup: prefix: sub/sub/
1407
EOF
1407
- test_repo 11/sub/sub "$TRASH_DIRECTORY/11/.git" ../..
1408
+ test_repo 11/sub/sub "$here/11/.git" ../..
1409
'
1410
1411
test_expect_success '#11: GIT_DIR(rel), GIT_WORK_TREE=wt at root' '
1412
cat >11/expected <<EOF &&
1412
-setup: git_dir: $TRASH_DIRECTORY/11.git
1413
-setup: worktree: $TRASH_DIRECTORY/11/wt
1414
-setup: cwd: $TRASH_DIRECTORY/11
1413
+setup: git_dir: $here/11.git
1414
+setup: worktree: $here/11/wt
1415
+setup: cwd: $here/11
1416
setup: prefix: (null)
1417
EOF
1417
- test_repo 11 .git "$TRASH_DIRECTORY/11/wt"
1418
+ test_repo 11 .git "$here/11/wt"
1419
'
1420
1421
test_expect_success '#11: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) at root' '
1422
cat >11/expected <<EOF &&
1422
-setup: git_dir: $TRASH_DIRECTORY/11.git
1423
-setup: worktree: $TRASH_DIRECTORY/11/wt
1424
-setup: cwd: $TRASH_DIRECTORY/11
1423
+setup: git_dir: $here/11.git
1424
+setup: worktree: $here/11/wt
1425
+setup: cwd: $here/11
1426
setup: prefix: (null)
1427
EOF
1428
test_repo 11 .git wt
@@ -1429,39 +1430,39 @@ EOF
1430
1431
test_expect_success '#11: GIT_DIR, GIT_WORK_TREE=wt(rel) at root' '
1432
cat >11/expected <<EOF &&
1432
-setup: git_dir: $TRASH_DIRECTORY/11.git
1433
-setup: worktree: $TRASH_DIRECTORY/11/wt
1434
-setup: cwd: $TRASH_DIRECTORY/11
1433
+setup: git_dir: $here/11.git
1434
+setup: worktree: $here/11/wt
1435
+setup: cwd: $here/11
1436
setup: prefix: (null)
1437
EOF
1437
- test_repo 11 "$TRASH_DIRECTORY/11/.git" wt
1438
+ test_repo 11 "$here/11/.git" wt
1439
'
1440
1441
test_expect_success '#11: GIT_DIR, GIT_WORK_TREE=wt at root' '
1442
cat >11/expected <<EOF &&
1442
-setup: git_dir: $TRASH_DIRECTORY/11.git
1443
-setup: worktree: $TRASH_DIRECTORY/11/wt
1444
-setup: cwd: $TRASH_DIRECTORY/11
1443
+setup: git_dir: $here/11.git
1444
+setup: worktree: $here/11/wt
1445
+setup: cwd: $here/11
1446
setup: prefix: (null)
1447
EOF
1447
- test_repo 11 "$TRASH_DIRECTORY/11/.git" "$TRASH_DIRECTORY/11/wt"
1448
+ test_repo 11 "$here/11/.git" "$here/11/wt"
1449
'
1450
1451
test_expect_success '#11: GIT_DIR(rel), GIT_WORK_TREE=wt in subdir' '
1452
cat >11/sub/sub/expected <<EOF &&
1452
-setup: git_dir: $TRASH_DIRECTORY/11.git
1453
-setup: worktree: $TRASH_DIRECTORY/11/wt
1454
-setup: cwd: $TRASH_DIRECTORY/11/sub/sub
1453
+setup: git_dir: $here/11.git
1454
+setup: worktree: $here/11/wt
1455
+setup: cwd: $here/11/sub/sub
1456
setup: prefix: (null)
1457
EOF
1457
- test_repo 11/sub/sub ../../.git "$TRASH_DIRECTORY/11/wt"
1458
+ test_repo 11/sub/sub ../../.git "$here/11/wt"
1459
'
1460
1461
test_expect_success '#11: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) in subdir' '
1462
cat >11/sub/sub/expected <<EOF &&
1462
-setup: git_dir: $TRASH_DIRECTORY/11.git
1463
-setup: worktree: $TRASH_DIRECTORY/11/wt
1464
-setup: cwd: $TRASH_DIRECTORY/11/sub/sub
1463
+setup: git_dir: $here/11.git
1464
+setup: worktree: $here/11/wt
1465
+setup: cwd: $here/11/sub/sub
1466
setup: prefix: (null)
1467
EOF
1468
test_repo 11/sub/sub ../../.git ../../wt
@@ -1469,39 +1470,39 @@ EOF
1470
1471
test_expect_success '#11: GIT_DIR, GIT_WORK_TREE=wt(rel) in subdir' '
1472
cat >11/sub/sub/expected <<EOF &&
1472
-setup: git_dir: $TRASH_DIRECTORY/11.git
1473
-setup: worktree: $TRASH_DIRECTORY/11/wt
1474
-setup: cwd: $TRASH_DIRECTORY/11/sub/sub
1473
+setup: git_dir: $here/11.git
1474
+setup: worktree: $here/11/wt
1475
+setup: cwd: $here/11/sub/sub
1476
setup: prefix: (null)
1477
EOF
1477
- test_repo 11/sub/sub "$TRASH_DIRECTORY/11/.git" ../../wt
1478
+ test_repo 11/sub/sub "$here/11/.git" ../../wt
1479
'
1480
1481
test_expect_success '#11: GIT_DIR, GIT_WORK_TREE=wt in subdir' '
1482
cat >11/sub/sub/expected <<EOF &&
1482
-setup: git_dir: $TRASH_DIRECTORY/11.git
1483
-setup: worktree: $TRASH_DIRECTORY/11/wt
1484
-setup: cwd: $TRASH_DIRECTORY/11/sub/sub
1483
+setup: git_dir: $here/11.git
1484
+setup: worktree: $here/11/wt
1485
+setup: cwd: $here/11/sub/sub
1486
setup: prefix: (null)
1487
EOF
1487
- test_repo 11/sub/sub "$TRASH_DIRECTORY/11/.git" "$TRASH_DIRECTORY/11/wt"
1488
+ test_repo 11/sub/sub "$here/11/.git" "$here/11/wt"
1489
'
1490
1491
test_expect_success '#11: GIT_DIR(rel), GIT_WORK_TREE=.. at root' '
1492
cat >11/expected <<EOF &&
1492
-setup: git_dir: $TRASH_DIRECTORY/11.git
1493
-setup: worktree: $TRASH_DIRECTORY
1494
-setup: cwd: $TRASH_DIRECTORY
1493
+setup: git_dir: $here/11.git
1494
+setup: worktree: $here
1495
+setup: cwd: $here
1496
setup: prefix: 11/
1497
EOF
1497
- test_repo 11 .git "$TRASH_DIRECTORY"
1498
+ test_repo 11 .git "$here"
1499
'
1500
1501
test_expect_success '#11: GIT_DIR(rel), GIT_WORK_TREE=..(rel) at root' '
1502
cat >11/expected <<EOF &&
1502
-setup: git_dir: $TRASH_DIRECTORY/11.git
1503
-setup: worktree: $TRASH_DIRECTORY
1504
-setup: cwd: $TRASH_DIRECTORY
1503
+setup: git_dir: $here/11.git
1504
+setup: worktree: $here
1505
+setup: cwd: $here
1506
setup: prefix: 11/
1507
EOF
1508
test_repo 11 .git ..
@@ -1509,39 +1510,39 @@ EOF
1510
1511
test_expect_success '#11: GIT_DIR, GIT_WORK_TREE=..(rel) at root' '
1512
cat >11/expected <<EOF &&
1512
-setup: git_dir: $TRASH_DIRECTORY/11.git
1513
-setup: worktree: $TRASH_DIRECTORY
1514
-setup: cwd: $TRASH_DIRECTORY
1513
+setup: git_dir: $here/11.git
1514
+setup: worktree: $here
1515
+setup: cwd: $here
1516
setup: prefix: 11/
1517
EOF
1517
- test_repo 11 "$TRASH_DIRECTORY/11/.git" ..
1518
+ test_repo 11 "$here/11/.git" ..
1519
'
1520
1521
test_expect_success '#11: GIT_DIR, GIT_WORK_TREE=.. at root' '
1522
cat >11/expected <<EOF &&
1522
-setup: git_dir: $TRASH_DIRECTORY/11.git
1523
-setup: worktree: $TRASH_DIRECTORY
1524
-setup: cwd: $TRASH_DIRECTORY
1523
+setup: git_dir: $here/11.git
1524
+setup: worktree: $here
1525
+setup: cwd: $here
1526
setup: prefix: 11/
1527
EOF
1527
- test_repo 11 "$TRASH_DIRECTORY/11/.git" "$TRASH_DIRECTORY"
1528
+ test_repo 11 "$here/11/.git" "$here"
1529
'
1530
1531
test_expect_success '#11: GIT_DIR(rel), GIT_WORK_TREE=.. in subdir' '
1532
cat >11/sub/sub/expected <<EOF &&
1532
-setup: git_dir: $TRASH_DIRECTORY/11.git
1533
-setup: worktree: $TRASH_DIRECTORY
1534
-setup: cwd: $TRASH_DIRECTORY
1533
+setup: git_dir: $here/11.git
1534
+setup: worktree: $here
1535
+setup: cwd: $here
1536
setup: prefix: 11/sub/sub/
1537
EOF
1537
- test_repo 11/sub/sub ../../.git "$TRASH_DIRECTORY"
1538
+ test_repo 11/sub/sub ../../.git "$here"
1539
'
1540
1541
test_expect_success '#11: GIT_DIR(rel), GIT_WORK_TREE=..(rel) in subdir' '
1542
cat >11/sub/sub/expected <<EOF &&
1542
-setup: git_dir: $TRASH_DIRECTORY/11.git
1543
-setup: worktree: $TRASH_DIRECTORY
1544
-setup: cwd: $TRASH_DIRECTORY
1543
+setup: git_dir: $here/11.git
1544
+setup: worktree: $here
1545
+setup: cwd: $here
1546
setup: prefix: 11/sub/sub/
1547
EOF
1548
test_repo 11/sub/sub ../../.git ../../..
@@ -1549,22 +1550,22 @@ EOF
1550
1551
test_expect_success '#11: GIT_DIR, GIT_WORK_TREE=..(rel) in subdir' '
1552
cat >11/sub/sub/expected <<EOF &&
1552
-setup: git_dir: $TRASH_DIRECTORY/11.git
1553
-setup: worktree: $TRASH_DIRECTORY
1554
-setup: cwd: $TRASH_DIRECTORY
1553
+setup: git_dir: $here/11.git
1554
+setup: worktree: $here
1555
+setup: cwd: $here
1556
setup: prefix: 11/sub/sub/
1557
EOF
1557
- test_repo 11/sub/sub "$TRASH_DIRECTORY/11/.git" ../../../
1558
+ test_repo 11/sub/sub "$here/11/.git" ../../../
1559
'
1560
1561
test_expect_success '#11: GIT_DIR, GIT_WORK_TREE=.. in subdir' '
1562
cat >11/sub/sub/expected <<EOF &&
1562
-setup: git_dir: $TRASH_DIRECTORY/11.git
1563
-setup: worktree: $TRASH_DIRECTORY
1564
-setup: cwd: $TRASH_DIRECTORY
1563
+setup: git_dir: $here/11.git
1564
+setup: worktree: $here
1565
+setup: cwd: $here
1566
setup: prefix: 11/sub/sub/
1567
EOF
1567
- test_repo 11/sub/sub "$TRASH_DIRECTORY/11/.git" "$TRASH_DIRECTORY"
1568
+ test_repo 11/sub/sub "$here/11/.git" "$here"
1569
'
1570
1571
#
@@ -1598,9 +1599,9 @@ test_expect_success '#12: setup' '
1599
1600
test_expect_success '#12: at root' '
1601
cat >12/expected <<EOF &&
1601
-setup: git_dir: $TRASH_DIRECTORY/12.git
1602
-setup: worktree: $TRASH_DIRECTORY/12
1603
-setup: cwd: $TRASH_DIRECTORY/12
1602
+setup: git_dir: $here/12.git
1603
+setup: worktree: $here/12
1604
+setup: cwd: $here/12
1605
setup: prefix: (null)
1606
EOF
1607
test_repo 12
@@ -1608,9 +1609,9 @@ EOF
1609
1610
test_expect_success '#12: in subdir' '
1611
cat >12/sub/expected <<EOF &&
1611
-setup: git_dir: $TRASH_DIRECTORY/12.git
1612
-setup: worktree: $TRASH_DIRECTORY/12
1613
-setup: cwd: $TRASH_DIRECTORY/12
1612
+setup: git_dir: $here/12.git
1613
+setup: worktree: $here/12
1614
+setup: cwd: $here/12
1615
setup: prefix: sub/
1616
EOF
1617
test_repo 12/sub
@@ -1648,9 +1649,9 @@ test_expect_success '#13: setup' '
1649
1650
test_expect_success '#13: at root' '
1651
cat >13/expected <<EOF &&
1651
-setup: git_dir: $TRASH_DIRECTORY/13.git
1652
-setup: worktree: $TRASH_DIRECTORY/13
1653
-setup: cwd: $TRASH_DIRECTORY/13
1652
+setup: git_dir: $here/13.git
1653
+setup: worktree: $here/13
1654
+setup: cwd: $here/13
1655
setup: prefix: (null)
1656
EOF
1657
test_repo 13
@@ -1658,9 +1659,9 @@ EOF
1659
1660
test_expect_success '#13: in subdir' '
1661
cat >13/sub/expected <<EOF &&
1661
-setup: git_dir: $TRASH_DIRECTORY/13.git
1662
-setup: worktree: $TRASH_DIRECTORY/13
1663
-setup: cwd: $TRASH_DIRECTORY/13
1662
+setup: git_dir: $here/13.git
1663
+setup: worktree: $here/13
1664
+setup: cwd: $here/13
1665
setup: prefix: sub/
1666
EOF
1667
test_repo 13/sub
@@ -1695,266 +1696,266 @@ test_expect_success '#14: setup' '
1696
1697
test_expect_success '#14: GIT_DIR(rel), core.worktree=../14 at root' '
1698
cat >14/expected <<EOF &&
1698
-setup: git_dir: $TRASH_DIRECTORY/14.git
1699
-setup: worktree: $TRASH_DIRECTORY/14
1700
-setup: cwd: $TRASH_DIRECTORY/14
1699
+setup: git_dir: $here/14.git
1700
+setup: worktree: $here/14
1701
+setup: cwd: $here/14
1702
setup: prefix: (null)
1703
EOF
1703
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY/14" &&
1704
+ git config --file="$here/14.git/config" core.worktree "$here/14" &&
1705
test_repo 14 .git
1706
'
1707
1708
test_expect_success '#14: GIT_DIR(rel), core.worktree=../14(rel) at root' '
1709
cat >14/expected <<EOF &&
1709
-setup: git_dir: $TRASH_DIRECTORY/14.git
1710
-setup: worktree: $TRASH_DIRECTORY/14
1711
-setup: cwd: $TRASH_DIRECTORY/14
1710
+setup: git_dir: $here/14.git
1711
+setup: worktree: $here/14
1712
+setup: cwd: $here/14
1713
setup: prefix: (null)
1714
EOF
1714
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree ../14 &&
1715
+ git config --file="$here/14.git/config" core.worktree ../14 &&
1716
test_repo 14 .git
1717
'
1718
1719
test_expect_success '#14: GIT_DIR, core.worktree=../14 at root' '
1720
cat >14/expected <<EOF &&
1720
-setup: git_dir: $TRASH_DIRECTORY/14.git
1721
-setup: worktree: $TRASH_DIRECTORY/14
1722
-setup: cwd: $TRASH_DIRECTORY/14
1721
+setup: git_dir: $here/14.git
1722
+setup: worktree: $here/14
1723
+setup: cwd: $here/14
1724
setup: prefix: (null)
1725
EOF
1725
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY/14" &&
1726
- test_repo 14 "$TRASH_DIRECTORY/14/.git"
1726
+ git config --file="$here/14.git/config" core.worktree "$here/14" &&
1727
+ test_repo 14 "$here/14/.git"
1728
'
1729
1730
test_expect_success '#14: GIT_DIR, core.worktree=../14(rel) at root' '
1731
cat >14/expected <<EOF &&
1731
-setup: git_dir: $TRASH_DIRECTORY/14.git
1732
-setup: worktree: $TRASH_DIRECTORY/14
1733
-setup: cwd: $TRASH_DIRECTORY/14
1732
+setup: git_dir: $here/14.git
1733
+setup: worktree: $here/14
1734
+setup: cwd: $here/14
1735
setup: prefix: (null)
1736
EOF
1736
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree ../14 &&
1737
- test_repo 14 "$TRASH_DIRECTORY/14/.git"
1737
+ git config --file="$here/14.git/config" core.worktree ../14 &&
1738
+ test_repo 14 "$here/14/.git"
1739
'
1740
1741
test_expect_success '#14: GIT_DIR(rel), core.worktree=../14 in subdir' '
1742
cat >14/sub/sub/expected <<EOF &&
1742
-setup: git_dir: $TRASH_DIRECTORY/14.git
1743
-setup: worktree: $TRASH_DIRECTORY/14
1744
-setup: cwd: $TRASH_DIRECTORY/14
1743
+setup: git_dir: $here/14.git
1744
+setup: worktree: $here/14
1745
+setup: cwd: $here/14
1746
setup: prefix: sub/sub/
1747
EOF
1747
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY/14" &&
1748
+ git config --file="$here/14.git/config" core.worktree "$here/14" &&
1749
test_repo 14/sub/sub ../../.git
1750
'
1751
1752
test_expect_success '#14: GIT_DIR(rel), core.worktree=../14(rel) in subdir' '
1753
cat >14/sub/sub/expected <<EOF &&
1753
-setup: git_dir: $TRASH_DIRECTORY/14.git
1754
-setup: worktree: $TRASH_DIRECTORY/14
1755
-setup: cwd: $TRASH_DIRECTORY/14
1754
+setup: git_dir: $here/14.git
1755
+setup: worktree: $here/14
1756
+setup: cwd: $here/14
1757
setup: prefix: sub/sub/
1758
EOF
1758
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree ../14 &&
1759
+ git config --file="$here/14.git/config" core.worktree ../14 &&
1760
test_repo 14/sub/sub ../../.git
1761
'
1762
1763
test_expect_success '#14: GIT_DIR, core.worktree=../14 in subdir' '
1764
cat >14/sub/expected <<EOF &&
1764
-setup: git_dir: $TRASH_DIRECTORY/14.git
1765
-setup: worktree: $TRASH_DIRECTORY/14
1766
-setup: cwd: $TRASH_DIRECTORY/14
1765
+setup: git_dir: $here/14.git
1766
+setup: worktree: $here/14
1767
+setup: cwd: $here/14
1768
setup: prefix: sub/
1769
EOF
1769
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY/14" &&
1770
- test_repo 14/sub "$TRASH_DIRECTORY/14/.git"
1770
+ git config --file="$here/14.git/config" core.worktree "$here/14" &&
1771
+ test_repo 14/sub "$here/14/.git"
1772
'
1773
1774
test_expect_success '#14: GIT_DIR, core.worktree=../14(rel) in subdir' '
1775
cat >14/sub/sub/expected <<EOF &&
1775
-setup: git_dir: $TRASH_DIRECTORY/14.git
1776
-setup: worktree: $TRASH_DIRECTORY/14
1777
-setup: cwd: $TRASH_DIRECTORY/14
1776
+setup: git_dir: $here/14.git
1777
+setup: worktree: $here/14
1778
+setup: cwd: $here/14
1779
setup: prefix: sub/sub/
1780
EOF
1780
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree ../14 &&
1781
- test_repo 14/sub/sub "$TRASH_DIRECTORY/14/.git"
1781
+ git config --file="$here/14.git/config" core.worktree ../14 &&
1782
+ test_repo 14/sub/sub "$here/14/.git"
1783
'
1784
1785
test_expect_success '#14: GIT_DIR(rel), core.worktree=../14/wt at root' '
1786
cat >14/expected <<EOF &&
1786
-setup: git_dir: $TRASH_DIRECTORY/14.git
1787
-setup: worktree: $TRASH_DIRECTORY/14/wt
1788
-setup: cwd: $TRASH_DIRECTORY/14
1787
+setup: git_dir: $here/14.git
1788
+setup: worktree: $here/14/wt
1789
+setup: cwd: $here/14
1790
setup: prefix: (null)
1791
EOF
1791
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY/14/wt" &&
1792
+ git config --file="$here/14.git/config" core.worktree "$here/14/wt" &&
1793
test_repo 14 .git
1794
'
1795
1796
test_expect_success '#14: GIT_DIR(rel), core.worktree=../14/wt(rel) at root' '
1797
cat >14/expected <<EOF &&
1797
-setup: git_dir: $TRASH_DIRECTORY/14.git
1798
-setup: worktree: $TRASH_DIRECTORY/14/wt
1799
-setup: cwd: $TRASH_DIRECTORY/14
1798
+setup: git_dir: $here/14.git
1799
+setup: worktree: $here/14/wt
1800
+setup: cwd: $here/14
1801
setup: prefix: (null)
1802
EOF
1802
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree ../14/wt &&
1803
+ git config --file="$here/14.git/config" core.worktree ../14/wt &&
1804
test_repo 14 .git
1805
'
1806
1807
test_expect_success '#14: GIT_DIR, core.worktree=../14/wt(rel) at root' '
1808
cat >14/expected <<EOF &&
1808
-setup: git_dir: $TRASH_DIRECTORY/14.git
1809
-setup: worktree: $TRASH_DIRECTORY/14/wt
1810
-setup: cwd: $TRASH_DIRECTORY/14
1809
+setup: git_dir: $here/14.git
1810
+setup: worktree: $here/14/wt
1811
+setup: cwd: $here/14
1812
setup: prefix: (null)
1813
EOF
1813
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree ../14/wt &&
1814
- test_repo 14 "$TRASH_DIRECTORY/14/.git"
1814
+ git config --file="$here/14.git/config" core.worktree ../14/wt &&
1815
+ test_repo 14 "$here/14/.git"
1816
'
1817
1818
test_expect_success '#14: GIT_DIR, core.worktree=../14/wt at root' '
1819
cat >14/expected <<EOF &&
1819
-setup: git_dir: $TRASH_DIRECTORY/14.git
1820
-setup: worktree: $TRASH_DIRECTORY/14/wt
1821
-setup: cwd: $TRASH_DIRECTORY/14
1820
+setup: git_dir: $here/14.git
1821
+setup: worktree: $here/14/wt
1822
+setup: cwd: $here/14
1823
setup: prefix: (null)
1824
EOF
1824
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY/14/wt" &&
1825
- test_repo 14 "$TRASH_DIRECTORY/14/.git"
1825
+ git config --file="$here/14.git/config" core.worktree "$here/14/wt" &&
1826
+ test_repo 14 "$here/14/.git"
1827
'
1828
1829
test_expect_success '#14: GIT_DIR(rel), core.worktree=../14/wt in subdir' '
1830
cat >14/sub/sub/expected <<EOF &&
1830
-setup: git_dir: $TRASH_DIRECTORY/14.git
1831
-setup: worktree: $TRASH_DIRECTORY/14/wt
1832
-setup: cwd: $TRASH_DIRECTORY/14/sub/sub
1831
+setup: git_dir: $here/14.git
1832
+setup: worktree: $here/14/wt
1833
+setup: cwd: $here/14/sub/sub
1834
setup: prefix: (null)
1835
EOF
1835
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY/14/wt" &&
1836
+ git config --file="$here/14.git/config" core.worktree "$here/14/wt" &&
1837
test_repo 14/sub/sub ../../.git
1838
'
1839
1840
test_expect_success '#14: GIT_DIR(rel), core.worktree=../14/wt(rel) in subdir' '
1841
cat >14/sub/sub/expected <<EOF &&
1841
-setup: git_dir: $TRASH_DIRECTORY/14.git
1842
-setup: worktree: $TRASH_DIRECTORY/14/wt
1843
-setup: cwd: $TRASH_DIRECTORY/14/sub/sub
1842
+setup: git_dir: $here/14.git
1843
+setup: worktree: $here/14/wt
1844
+setup: cwd: $here/14/sub/sub
1845
setup: prefix: (null)
1846
EOF
1846
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree ../14/wt &&
1847
+ git config --file="$here/14.git/config" core.worktree ../14/wt &&
1848
test_repo 14/sub/sub ../../.git
1849
'
1850
1851
test_expect_success '#14: GIT_DIR, core.worktree=../14/wt(rel) in subdir' '
1852
cat >14/sub/sub/expected <<EOF &&
1852
-setup: git_dir: $TRASH_DIRECTORY/14.git
1853
-setup: worktree: $TRASH_DIRECTORY/14/wt
1854
-setup: cwd: $TRASH_DIRECTORY/14/sub/sub
1853
+setup: git_dir: $here/14.git
1854
+setup: worktree: $here/14/wt
1855
+setup: cwd: $here/14/sub/sub
1856
setup: prefix: (null)
1857
EOF
1857
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree ../14/wt &&
1858
- test_repo 14/sub/sub "$TRASH_DIRECTORY/14/.git"
1858
+ git config --file="$here/14.git/config" core.worktree ../14/wt &&
1859
+ test_repo 14/sub/sub "$here/14/.git"
1860
'
1861
1862
test_expect_success '#14: GIT_DIR, core.worktree=../14/wt in subdir' '
1863
cat >14/sub/sub/expected <<EOF &&
1863
-setup: git_dir: $TRASH_DIRECTORY/14.git
1864
-setup: worktree: $TRASH_DIRECTORY/14/wt
1865
-setup: cwd: $TRASH_DIRECTORY/14/sub/sub
1864
+setup: git_dir: $here/14.git
1865
+setup: worktree: $here/14/wt
1866
+setup: cwd: $here/14/sub/sub
1867
setup: prefix: (null)
1868
EOF
1868
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY/14/wt" &&
1869
- test_repo 14/sub/sub "$TRASH_DIRECTORY/14/.git"
1869
+ git config --file="$here/14.git/config" core.worktree "$here/14/wt" &&
1870
+ test_repo 14/sub/sub "$here/14/.git"
1871
'
1872
1873
test_expect_success '#14: GIT_DIR(rel), core.worktree=.. at root' '
1874
cat >14/expected <<EOF &&
1874
-setup: git_dir: $TRASH_DIRECTORY/14.git
1875
-setup: worktree: $TRASH_DIRECTORY
1876
-setup: cwd: $TRASH_DIRECTORY
1875
+setup: git_dir: $here/14.git
1876
+setup: worktree: $here
1877
+setup: cwd: $here
1878
setup: prefix: 14/
1879
EOF
1879
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY" &&
1880
+ git config --file="$here/14.git/config" core.worktree "$here" &&
1881
test_repo 14 .git
1882
'
1883
1884
test_expect_success '#14: GIT_DIR(rel), core.worktree=..(rel) at root' '
1885
cat >14/expected <<EOF &&
1885
-setup: git_dir: $TRASH_DIRECTORY/14.git
1886
-setup: worktree: $TRASH_DIRECTORY
1887
-setup: cwd: $TRASH_DIRECTORY
1886
+setup: git_dir: $here/14.git
1887
+setup: worktree: $here
1888
+setup: cwd: $here
1889
setup: prefix: 14/
1890
EOF
1890
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree .. &&
1891
+ git config --file="$here/14.git/config" core.worktree .. &&
1892
test_repo 14 .git
1893
'
1894
1895
test_expect_success '#14: GIT_DIR, core.worktree=..(rel) at root' '
1896
cat >14/expected <<EOF &&
1896
-setup: git_dir: $TRASH_DIRECTORY/14.git
1897
-setup: worktree: $TRASH_DIRECTORY
1898
-setup: cwd: $TRASH_DIRECTORY
1897
+setup: git_dir: $here/14.git
1898
+setup: worktree: $here
1899
+setup: cwd: $here
1900
setup: prefix: 14/
1901
EOF
1901
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree .. &&
1902
- test_repo 14 "$TRASH_DIRECTORY/14/.git"
1902
+ git config --file="$here/14.git/config" core.worktree .. &&
1903
+ test_repo 14 "$here/14/.git"
1904
'
1905
1906
test_expect_success '#14: GIT_DIR, core.worktree=.. at root' '
1907
cat >14/expected <<EOF &&
1907
-setup: git_dir: $TRASH_DIRECTORY/14.git
1908
-setup: worktree: $TRASH_DIRECTORY
1909
-setup: cwd: $TRASH_DIRECTORY
1908
+setup: git_dir: $here/14.git
1909
+setup: worktree: $here
1910
+setup: cwd: $here
1911
setup: prefix: 14/
1912
EOF
1912
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY" &&
1913
- test_repo 14 "$TRASH_DIRECTORY/14/.git"
1913
+ git config --file="$here/14.git/config" core.worktree "$here" &&
1914
+ test_repo 14 "$here/14/.git"
1915
'
1916
1917
test_expect_success '#14: GIT_DIR(rel), core.worktree=.. in subdir' '
1918
cat >14/sub/sub/expected <<EOF &&
1918
-setup: git_dir: $TRASH_DIRECTORY/14.git
1919
-setup: worktree: $TRASH_DIRECTORY
1920
-setup: cwd: $TRASH_DIRECTORY
1919
+setup: git_dir: $here/14.git
1920
+setup: worktree: $here
1921
+setup: cwd: $here
1922
setup: prefix: 14/sub/sub/
1923
EOF
1923
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY" &&
1924
+ git config --file="$here/14.git/config" core.worktree "$here" &&
1925
test_repo 14/sub/sub ../../.git
1926
'
1927
1928
test_expect_success '#14: GIT_DIR(rel), core.worktree=..(rel) in subdir' '
1929
cat >14/sub/sub/expected <<EOF &&
1929
-setup: git_dir: $TRASH_DIRECTORY/14.git
1930
-setup: worktree: $TRASH_DIRECTORY
1931
-setup: cwd: $TRASH_DIRECTORY
1930
+setup: git_dir: $here/14.git
1931
+setup: worktree: $here
1932
+setup: cwd: $here
1933
setup: prefix: 14/sub/sub/
1934
EOF
1934
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree .. &&
1935
+ git config --file="$here/14.git/config" core.worktree .. &&
1936
test_repo 14/sub/sub ../../.git
1937
'
1938
1939
test_expect_success '#14: GIT_DIR, core.worktree=..(rel) in subdir' '
1940
cat >14/sub/sub/expected <<EOF &&
1940
-setup: git_dir: $TRASH_DIRECTORY/14.git
1941
-setup: worktree: $TRASH_DIRECTORY
1942
-setup: cwd: $TRASH_DIRECTORY
1941
+setup: git_dir: $here/14.git
1942
+setup: worktree: $here
1943
+setup: cwd: $here
1944
setup: prefix: 14/sub/sub/
1945
EOF
1945
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree .. &&
1946
- test_repo 14/sub/sub "$TRASH_DIRECTORY/14/.git"
1946
+ git config --file="$here/14.git/config" core.worktree .. &&
1947
+ test_repo 14/sub/sub "$here/14/.git"
1948
'
1949
1950
test_expect_success '#14: GIT_DIR, core.worktree=.. in subdir' '
1951
cat >14/sub/sub/expected <<EOF &&
1951
-setup: git_dir: $TRASH_DIRECTORY/14.git
1952
-setup: worktree: $TRASH_DIRECTORY
1953
-setup: cwd: $TRASH_DIRECTORY
1952
+setup: git_dir: $here/14.git
1953
+setup: worktree: $here
1954
+setup: cwd: $here
1955
setup: prefix: 14/sub/sub/
1956
EOF
1956
- git config --file="$TRASH_DIRECTORY/14.git/config" core.worktree "$TRASH_DIRECTORY" &&
1957
- test_repo 14/sub/sub "$TRASH_DIRECTORY/14/.git"
1957
+ git config --file="$here/14.git/config" core.worktree "$here" &&
1958
+ test_repo 14/sub/sub "$here/14/.git"
1959
'
1960
1961
#
@@ -1987,19 +1988,19 @@ test_expect_success '#15: setup' '
1988
1989
test_expect_success '#15: GIT_DIR(rel), GIT_WORK_TREE=root at root' '
1990
cat >15/expected <<EOF &&
1990
-setup: git_dir: $TRASH_DIRECTORY/15.git
1991
-setup: worktree: $TRASH_DIRECTORY/15
1992
-setup: cwd: $TRASH_DIRECTORY/15
1991
+setup: git_dir: $here/15.git
1992
+setup: worktree: $here/15
1993
+setup: cwd: $here/15
1994
setup: prefix: (null)
1995
EOF
1995
- test_repo 15 .git "$TRASH_DIRECTORY/15"
1996
+ test_repo 15 .git "$here/15"
1997
'
1998
1999
test_expect_success '#15: GIT_DIR(rel), GIT_WORK_TREE=root(rel) at root' '
2000
cat >15/expected <<EOF &&
2000
-setup: git_dir: $TRASH_DIRECTORY/15.git
2001
-setup: worktree: $TRASH_DIRECTORY/15
2002
-setup: cwd: $TRASH_DIRECTORY/15
2001
+setup: git_dir: $here/15.git
2002
+setup: worktree: $here/15
2003
+setup: cwd: $here/15
2004
setup: prefix: (null)
2005
EOF
2006
test_repo 15 .git .
@@ -2007,39 +2008,39 @@ EOF
2008
2009
test_expect_success '#15: GIT_DIR, GIT_WORK_TREE=root at root' '
2010
cat >15/expected <<EOF &&
2010
-setup: git_dir: $TRASH_DIRECTORY/15.git
2011
-setup: worktree: $TRASH_DIRECTORY/15
2012
-setup: cwd: $TRASH_DIRECTORY/15
2011
+setup: git_dir: $here/15.git
2012
+setup: worktree: $here/15
2013
+setup: cwd: $here/15
2014
setup: prefix: (null)
2015
EOF
2015
- test_repo 15 "$TRASH_DIRECTORY/15/.git" "$TRASH_DIRECTORY/15"
2016
+ test_repo 15 "$here/15/.git" "$here/15"
2017
'
2018
2019
test_expect_success '#15: GIT_DIR, GIT_WORK_TREE=root(rel) at root' '
2020
cat >15/expected <<EOF &&
2020
-setup: git_dir: $TRASH_DIRECTORY/15.git
2021
-setup: worktree: $TRASH_DIRECTORY/15
2022
-setup: cwd: $TRASH_DIRECTORY/15
2021
+setup: git_dir: $here/15.git
2022
+setup: worktree: $here/15
2023
+setup: cwd: $here/15
2024
setup: prefix: (null)
2025
EOF
2025
- test_repo 15 "$TRASH_DIRECTORY/15/.git" .
2026
+ test_repo 15 "$here/15/.git" .
2027
'
2028
2029
test_expect_success '#15: GIT_DIR(rel), GIT_WORKTREE=root in subdir' '
2030
cat >15/sub/sub/expected <<EOF &&
2030
-setup: git_dir: $TRASH_DIRECTORY/15.git
2031
-setup: worktree: $TRASH_DIRECTORY/15
2032
-setup: cwd: $TRASH_DIRECTORY/15
2031
+setup: git_dir: $here/15.git
2032
+setup: worktree: $here/15
2033
+setup: cwd: $here/15
2034
setup: prefix: sub/sub/
2035
EOF
2035
- test_repo 15/sub/sub ../../.git "$TRASH_DIRECTORY/15"
2036
+ test_repo 15/sub/sub ../../.git "$here/15"
2037
'
2038
2039
test_expect_success '#15: GIT_DIR(rel), GIT_WORKTREE=root(rel) in subdir' '
2040
cat >15/sub/sub/expected <<EOF &&
2040
-setup: git_dir: $TRASH_DIRECTORY/15.git
2041
-setup: worktree: $TRASH_DIRECTORY/15
2042
-setup: cwd: $TRASH_DIRECTORY/15
2041
+setup: git_dir: $here/15.git
2042
+setup: worktree: $here/15
2043
+setup: cwd: $here/15
2044
setup: prefix: sub/sub/
2045
EOF
2046
test_repo 15/sub/sub ../../.git ../..
@@ -2047,39 +2048,39 @@ EOF
2048
2049
test_expect_success '#15: GIT_DIR, GIT_WORKTREE=root in subdir' '
2050
cat >15/sub/expected <<EOF &&
2050
-setup: git_dir: $TRASH_DIRECTORY/15.git
2051
-setup: worktree: $TRASH_DIRECTORY/15
2052
-setup: cwd: $TRASH_DIRECTORY/15
2051
+setup: git_dir: $here/15.git
2052
+setup: worktree: $here/15
2053
+setup: cwd: $here/15
2054
setup: prefix: sub/
2055
EOF
2055
- test_repo 15/sub "$TRASH_DIRECTORY/15/.git" "$TRASH_DIRECTORY/15"
2056
+ test_repo 15/sub "$here/15/.git" "$here/15"
2057
'
2058
2059
test_expect_success '#15: GIT_DIR, GIT_WORKTREE=root(rel) in subdir' '
2060
cat >15/sub/sub/expected <<EOF &&
2060
-setup: git_dir: $TRASH_DIRECTORY/15.git
2061
-setup: worktree: $TRASH_DIRECTORY/15
2062
-setup: cwd: $TRASH_DIRECTORY/15
2061
+setup: git_dir: $here/15.git
2062
+setup: worktree: $here/15
2063
+setup: cwd: $here/15
2064
setup: prefix: sub/sub/
2065
EOF
2065
- test_repo 15/sub/sub "$TRASH_DIRECTORY/15/.git" ../..
2066
+ test_repo 15/sub/sub "$here/15/.git" ../..
2067
'
2068
2069
test_expect_success '#15: GIT_DIR(rel), GIT_WORK_TREE=wt at root' '
2070
cat >15/expected <<EOF &&
2070
-setup: git_dir: $TRASH_DIRECTORY/15.git
2071
-setup: worktree: $TRASH_DIRECTORY/15/wt
2072
-setup: cwd: $TRASH_DIRECTORY/15
2071
+setup: git_dir: $here/15.git
2072
+setup: worktree: $here/15/wt
2073
+setup: cwd: $here/15
2074
setup: prefix: (null)
2075
EOF
2075
- test_repo 15 .git "$TRASH_DIRECTORY/15/wt"
2076
+ test_repo 15 .git "$here/15/wt"
2077
'
2078
2079
test_expect_success '#15: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) at root' '
2080
cat >15/expected <<EOF &&
2080
-setup: git_dir: $TRASH_DIRECTORY/15.git
2081
-setup: worktree: $TRASH_DIRECTORY/15/wt
2082
-setup: cwd: $TRASH_DIRECTORY/15
2081
+setup: git_dir: $here/15.git
2082
+setup: worktree: $here/15/wt
2083
+setup: cwd: $here/15
2084
setup: prefix: (null)
2085
EOF
2086
test_repo 15 .git wt
@@ -2087,39 +2088,39 @@ EOF
2088
2089
test_expect_success '#15: GIT_DIR, GIT_WORK_TREE=wt(rel) at root' '
2090
cat >15/expected <<EOF &&
2090
-setup: git_dir: $TRASH_DIRECTORY/15.git
2091
-setup: worktree: $TRASH_DIRECTORY/15/wt
2092
-setup: cwd: $TRASH_DIRECTORY/15
2091
+setup: git_dir: $here/15.git
2092
+setup: worktree: $here/15/wt
2093
+setup: cwd: $here/15
2094
setup: prefix: (null)
2095
EOF
2095
- test_repo 15 "$TRASH_DIRECTORY/15/.git" wt
2096
+ test_repo 15 "$here/15/.git" wt
2097
'
2098
2099
test_expect_success '#15: GIT_DIR, GIT_WORK_TREE=wt at root' '
2100
cat >15/expected <<EOF &&
2100
-setup: git_dir: $TRASH_DIRECTORY/15.git
2101
-setup: worktree: $TRASH_DIRECTORY/15/wt
2102
-setup: cwd: $TRASH_DIRECTORY/15
2101
+setup: git_dir: $here/15.git
2102
+setup: worktree: $here/15/wt
2103
+setup: cwd: $here/15
2104
setup: prefix: (null)
2105
EOF
2105
- test_repo 15 "$TRASH_DIRECTORY/15/.git" "$TRASH_DIRECTORY/15/wt"
2106
+ test_repo 15 "$here/15/.git" "$here/15/wt"
2107
'
2108
2109
test_expect_success '#15: GIT_DIR(rel), GIT_WORK_TREE=wt in subdir' '
2110
cat >15/sub/sub/expected <<EOF &&
2110
-setup: git_dir: $TRASH_DIRECTORY/15.git
2111
-setup: worktree: $TRASH_DIRECTORY/15/wt
2112
-setup: cwd: $TRASH_DIRECTORY/15/sub/sub
2111
+setup: git_dir: $here/15.git
2112
+setup: worktree: $here/15/wt
2113
+setup: cwd: $here/15/sub/sub
2114
setup: prefix: (null)
2115
EOF
2115
- test_repo 15/sub/sub ../../.git "$TRASH_DIRECTORY/15/wt"
2116
+ test_repo 15/sub/sub ../../.git "$here/15/wt"
2117
'
2118
2119
test_expect_success '#15: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) in subdir' '
2120
cat >15/sub/sub/expected <<EOF &&
2120
-setup: git_dir: $TRASH_DIRECTORY/15.git
2121
-setup: worktree: $TRASH_DIRECTORY/15/wt
2122
-setup: cwd: $TRASH_DIRECTORY/15/sub/sub
2121
+setup: git_dir: $here/15.git
2122
+setup: worktree: $here/15/wt
2123
+setup: cwd: $here/15/sub/sub
2124
setup: prefix: (null)
2125
EOF
2126
test_repo 15/sub/sub ../../.git ../../wt
@@ -2127,39 +2128,39 @@ EOF
2128
2129
test_expect_success '#15: GIT_DIR, GIT_WORK_TREE=wt(rel) in subdir' '
2130
cat >15/sub/sub/expected <<EOF &&
2130
-setup: git_dir: $TRASH_DIRECTORY/15.git
2131
-setup: worktree: $TRASH_DIRECTORY/15/wt
2132
-setup: cwd: $TRASH_DIRECTORY/15/sub/sub
2131
+setup: git_dir: $here/15.git
2132
+setup: worktree: $here/15/wt
2133
+setup: cwd: $here/15/sub/sub
2134
setup: prefix: (null)
2135
EOF
2135
- test_repo 15/sub/sub "$TRASH_DIRECTORY/15/.git" ../../wt
2136
+ test_repo 15/sub/sub "$here/15/.git" ../../wt
2137
'
2138
2139
test_expect_success '#15: GIT_DIR, GIT_WORK_TREE=wt in subdir' '
2140
cat >15/sub/sub/expected <<EOF &&
2140
-setup: git_dir: $TRASH_DIRECTORY/15.git
2141
-setup: worktree: $TRASH_DIRECTORY/15/wt
2142
-setup: cwd: $TRASH_DIRECTORY/15/sub/sub
2141
+setup: git_dir: $here/15.git
2142
+setup: worktree: $here/15/wt
2143
+setup: cwd: $here/15/sub/sub
2144
setup: prefix: (null)
2145
EOF
2145
- test_repo 15/sub/sub "$TRASH_DIRECTORY/15/.git" "$TRASH_DIRECTORY/15/wt"
2146
+ test_repo 15/sub/sub "$here/15/.git" "$here/15/wt"
2147
'
2148
2149
test_expect_success '#15: GIT_DIR(rel), GIT_WORK_TREE=.. at root' '
2150
cat >15/expected <<EOF &&
2150
-setup: git_dir: $TRASH_DIRECTORY/15.git
2151
-setup: worktree: $TRASH_DIRECTORY
2152
-setup: cwd: $TRASH_DIRECTORY
2151
+setup: git_dir: $here/15.git
2152
+setup: worktree: $here
2153
+setup: cwd: $here
2154
setup: prefix: 15/
2155
EOF
2155
- test_repo 15 .git "$TRASH_DIRECTORY"
2156
+ test_repo 15 .git "$here"
2157
'
2158
2159
test_expect_success '#15: GIT_DIR(rel), GIT_WORK_TREE=..(rel) at root' '
2160
cat >15/expected <<EOF &&
2160
-setup: git_dir: $TRASH_DIRECTORY/15.git
2161
-setup: worktree: $TRASH_DIRECTORY
2162
-setup: cwd: $TRASH_DIRECTORY
2161
+setup: git_dir: $here/15.git
2162
+setup: worktree: $here
2163
+setup: cwd: $here
2164
setup: prefix: 15/
2165
EOF
2166
test_repo 15 .git ..
@@ -2167,39 +2168,39 @@ EOF
2168
2169
test_expect_success '#15: GIT_DIR, GIT_WORK_TREE=..(rel) at root' '
2170
cat >15/expected <<EOF &&
2170
-setup: git_dir: $TRASH_DIRECTORY/15.git
2171
-setup: worktree: $TRASH_DIRECTORY
2172
-setup: cwd: $TRASH_DIRECTORY
2171
+setup: git_dir: $here/15.git
2172
+setup: worktree: $here
2173
+setup: cwd: $here
2174
setup: prefix: 15/
2175
EOF
2175
- test_repo 15 "$TRASH_DIRECTORY/15/.git" ..
2176
+ test_repo 15 "$here/15/.git" ..
2177
'
2178
2179
test_expect_success '#15: GIT_DIR, GIT_WORK_TREE=.. at root' '
2180
cat >15/expected <<EOF &&
2180
-setup: git_dir: $TRASH_DIRECTORY/15.git
2181
-setup: worktree: $TRASH_DIRECTORY
2182
-setup: cwd: $TRASH_DIRECTORY
2181
+setup: git_dir: $here/15.git
2182
+setup: worktree: $here
2183
+setup: cwd: $here
2184
setup: prefix: 15/
2185
EOF
2185
- test_repo 15 "$TRASH_DIRECTORY/15/.git" "$TRASH_DIRECTORY"
2186
+ test_repo 15 "$here/15/.git" "$here"
2187
'
2188
2189
test_expect_success '#15: GIT_DIR(rel), GIT_WORK_TREE=.. in subdir' '
2190
cat >15/sub/sub/expected <<EOF &&
2190
-setup: git_dir: $TRASH_DIRECTORY/15.git
2191
-setup: worktree: $TRASH_DIRECTORY
2192
-setup: cwd: $TRASH_DIRECTORY
2191
+setup: git_dir: $here/15.git
2192
+setup: worktree: $here
2193
+setup: cwd: $here
2194
setup: prefix: 15/sub/sub/
2195
EOF
2195
- test_repo 15/sub/sub ../../.git "$TRASH_DIRECTORY"
2196
+ test_repo 15/sub/sub ../../.git "$here"
2197
'
2198
2199
test_expect_success '#15: GIT_DIR(rel), GIT_WORK_TREE=..(rel) in subdir' '
2200
cat >15/sub/sub/expected <<EOF &&
2200
-setup: git_dir: $TRASH_DIRECTORY/15.git
2201
-setup: worktree: $TRASH_DIRECTORY
2202
-setup: cwd: $TRASH_DIRECTORY
2201
+setup: git_dir: $here/15.git
2202
+setup: worktree: $here
2203
+setup: cwd: $here
2204
setup: prefix: 15/sub/sub/
2205
EOF
2206
test_repo 15/sub/sub ../../.git ../../..
@@ -2207,22 +2208,22 @@ EOF
2208
2209
test_expect_success '#15: GIT_DIR, GIT_WORK_TREE=..(rel) in subdir' '
2210
cat >15/sub/sub/expected <<EOF &&
2210
-setup: git_dir: $TRASH_DIRECTORY/15.git
2211
-setup: worktree: $TRASH_DIRECTORY
2212
-setup: cwd: $TRASH_DIRECTORY
2211
+setup: git_dir: $here/15.git
2212
+setup: worktree: $here
2213
+setup: cwd: $here
2214
setup: prefix: 15/sub/sub/
2215
EOF
2215
- test_repo 15/sub/sub "$TRASH_DIRECTORY/15/.git" ../../../
2216
+ test_repo 15/sub/sub "$here/15/.git" ../../../
2217
'
2218
2219
test_expect_success '#15: GIT_DIR, GIT_WORK_TREE=.. in subdir' '
2220
cat >15/sub/sub/expected <<EOF &&
2220
-setup: git_dir: $TRASH_DIRECTORY/15.git
2221
-setup: worktree: $TRASH_DIRECTORY
2222
-setup: cwd: $TRASH_DIRECTORY
2221
+setup: git_dir: $here/15.git
2222
+setup: worktree: $here
2223
+setup: cwd: $here
2224
setup: prefix: 15/sub/sub/
2225
EOF
2225
- test_repo 15/sub/sub "$TRASH_DIRECTORY/15/.git" "$TRASH_DIRECTORY"
2226
+ test_repo 15/sub/sub "$here/15/.git" "$here"
2227
'
2228
2229
#
@@ -2259,7 +2260,7 @@ test_expect_success '#16.1: at .git' '
2260
cat >16/.git/expected <<EOF &&
2261
setup: git_dir: .
2262
setup: worktree: (null)
2262
-setup: cwd: $TRASH_DIRECTORY/16/.git
2263
+setup: cwd: $here/16/.git
2264
setup: prefix: (null)
2265
EOF
2266
test_repo 16/.git
@@ -2267,9 +2268,9 @@ EOF
2268
2269
test_expect_success '#16.1: in .git/wt' '
2270
cat >16/.git/wt/expected <<EOF &&
2270
-setup: git_dir: $TRASH_DIRECTORY/16/.git
2271
+setup: git_dir: $here/16/.git
2272
setup: worktree: (null)
2272
-setup: cwd: $TRASH_DIRECTORY/16/.git/wt
2273
+setup: cwd: $here/16/.git/wt
2274
setup: prefix: (null)
2275
EOF
2276
test_repo 16/.git/wt
@@ -2277,9 +2278,9 @@ EOF
2278
2279
test_expect_success '#16.1: in .git/wt/sub' '
2280
cat >16/.git/wt/sub/expected <<EOF &&
2280
-setup: git_dir: $TRASH_DIRECTORY/16/.git
2281
+setup: git_dir: $here/16/.git
2282
setup: worktree: (null)
2282
-setup: cwd: $TRASH_DIRECTORY/16/.git/wt/sub
2283
+setup: cwd: $here/16/.git/wt/sub
2284
setup: prefix: (null)
2285
EOF
2286
test_repo 16/.git/wt/sub
@@ -2307,14 +2308,14 @@ EOF
2308
# - cwd can't be outside worktree
2309
2310
test_expect_success '#16.2: setup' '
2310
- git config --file="$TRASH_DIRECTORY/16/.git/config" core.bare true
2311
+ git config --file="$here/16/.git/config" core.bare true
2312
'
2313
2314
test_expect_success '#16.2: at .git' '
2315
cat >16/.git/expected <<EOF &&
2316
setup: git_dir: .
2317
setup: worktree: (null)
2317
-setup: cwd: $TRASH_DIRECTORY/16/.git
2318
+setup: cwd: $here/16/.git
2319
setup: prefix: (null)
2320
EOF
2321
test_repo 16/.git
@@ -2322,9 +2323,9 @@ EOF
2323
2324
test_expect_success '#16.2: in .git/wt' '
2325
cat >16/.git/wt/expected <<EOF &&
2325
-setup: git_dir: $TRASH_DIRECTORY/16/.git
2326
+setup: git_dir: $here/16/.git
2327
setup: worktree: (null)
2327
-setup: cwd: $TRASH_DIRECTORY/16/.git/wt
2328
+setup: cwd: $here/16/.git/wt
2329
setup: prefix: (null)
2330
EOF
2331
test_repo 16/.git/wt
@@ -2332,9 +2333,9 @@ EOF
2333
2334
test_expect_success '#16.2: in .git/wt/sub' '
2335
cat >16/.git/wt/sub/expected <<EOF &&
2335
-setup: git_dir: $TRASH_DIRECTORY/16/.git
2336
+setup: git_dir: $here/16/.git
2337
setup: worktree: (null)
2337
-setup: cwd: $TRASH_DIRECTORY/16/.git/wt/sub
2338
+setup: cwd: $here/16/.git/wt/sub
2339
setup: prefix: (null)
2340
EOF
2341
test_repo 16/.git/wt/sub
@@ -2344,7 +2345,7 @@ test_expect_success '#16.2: at root' '
2345
cat >16/expected <<EOF &&
2346
setup: git_dir: .git
2347
setup: worktree: (null)
2347
-setup: cwd: $TRASH_DIRECTORY/16
2348
+setup: cwd: $here/16
2349
setup: prefix: (null)
2350
EOF
2351
test_repo 16
@@ -2352,9 +2353,9 @@ EOF
2353
2354
test_expect_success '#16.2: in subdir' '
2355
cat >16/sub/expected <<EOF &&
2355
-setup: git_dir: $TRASH_DIRECTORY/16/.git
2356
+setup: git_dir: $here/16/.git
2357
setup: worktree: (null)
2357
-setup: cwd: $TRASH_DIRECTORY/16/sub
2358
+setup: cwd: $here/16/sub
2359
setup: prefix: (null)
2360
EOF
2361
test_repo 16/sub
@@ -2392,7 +2393,7 @@ test_expect_success '#17.1: at .git' '
2393
cat >17/.git/expected <<EOF &&
2394
setup: git_dir: .
2395
setup: worktree: (null)
2395
-setup: cwd: $TRASH_DIRECTORY/17/.git
2396
+setup: cwd: $here/17/.git
2397
setup: prefix: (null)
2398
EOF
2399
test_repo 17/.git
@@ -2400,9 +2401,9 @@ EOF
2401
2402
test_expect_success '#17.1: in .git/wt' '
2403
cat >17/.git/wt/expected <<EOF &&
2403
-setup: git_dir: $TRASH_DIRECTORY/17/.git
2404
+setup: git_dir: $here/17/.git
2405
setup: worktree: (null)
2405
-setup: cwd: $TRASH_DIRECTORY/17/.git/wt
2406
+setup: cwd: $here/17/.git/wt
2407
setup: prefix: (null)
2408
EOF
2409
test_repo 17/.git/wt
@@ -2410,9 +2411,9 @@ EOF
2411
2412
test_expect_success '#17.1: in .git/wt/sub' '
2413
cat >17/.git/wt/sub/expected <<EOF &&
2413
-setup: git_dir: $TRASH_DIRECTORY/17/.git
2414
+setup: git_dir: $here/17/.git
2415
setup: worktree: (null)
2415
-setup: cwd: $TRASH_DIRECTORY/17/.git/wt/sub
2416
+setup: cwd: $here/17/.git/wt/sub
2417
setup: prefix: (null)
2418
EOF
2419
test_repo 17/.git/wt/sub
@@ -2436,14 +2437,14 @@ EOF
2437
# GIT_WORK_TREE is ignored -> #16.2 (with warnings perhaps)
2438
2439
test_expect_success '#17.2: setup' '
2439
- git config --file="$TRASH_DIRECTORY/17/.git/config" core.bare true
2440
+ git config --file="$here/17/.git/config" core.bare true
2441
'
2442
2443
test_expect_success '#17.2: at .git' '
2444
cat >17/.git/expected <<EOF &&
2445
setup: git_dir: .
2446
setup: worktree: (null)
2446
-setup: cwd: $TRASH_DIRECTORY/17/.git
2447
+setup: cwd: $here/17/.git
2448
setup: prefix: (null)
2449
EOF
2450
test_repo 17/.git
@@ -2451,9 +2452,9 @@ EOF
2452
2453
test_expect_success '#17.2: in .git/wt' '
2454
cat >17/.git/wt/expected <<EOF &&
2454
-setup: git_dir: $TRASH_DIRECTORY/17/.git
2455
+setup: git_dir: $here/17/.git
2456
setup: worktree: (null)
2456
-setup: cwd: $TRASH_DIRECTORY/17/.git/wt
2457
+setup: cwd: $here/17/.git/wt
2458
setup: prefix: (null)
2459
EOF
2460
test_repo 17/.git/wt
@@ -2461,9 +2462,9 @@ EOF
2462
2463
test_expect_success '#17.2: in .git/wt/sub' '
2464
cat >17/.git/wt/sub/expected <<EOF &&
2464
-setup: git_dir: $TRASH_DIRECTORY/17/.git
2465
+setup: git_dir: $here/17/.git
2466
setup: worktree: (null)
2466
-setup: cwd: $TRASH_DIRECTORY/17/.git/wt/sub
2467
+setup: cwd: $here/17/.git/wt/sub
2468
setup: prefix: (null)
2469
EOF
2470
test_repo 17/.git/wt/sub
@@ -2473,7 +2474,7 @@ test_expect_success '#17.2: at root' '
2474
cat >17/expected <<EOF &&
2475
setup: git_dir: .git
2476
setup: worktree: (null)
2476
-setup: cwd: $TRASH_DIRECTORY/17
2477
+setup: cwd: $here/17
2478
setup: prefix: (null)
2479
EOF
2480
test_repo 17
@@ -2481,9 +2482,9 @@ EOF
2482
2483
test_expect_success '#17.2: in subdir' '
2484
cat >17/sub/expected <<EOF &&
2484
-setup: git_dir: $TRASH_DIRECTORY/17/.git
2485
+setup: git_dir: $here/17/.git
2486
setup: worktree: (null)
2486
-setup: cwd: $TRASH_DIRECTORY/17/sub
2487
+setup: cwd: $here/17/sub
2488
setup: prefix: (null)
2489
EOF
2490
test_repo 17/sub
@@ -2524,7 +2525,7 @@ test_expect_success '#18: (rel) at root' '
2525
cat >18/expected <<EOF &&
2526
setup: git_dir: .git
2527
setup: worktree: (null)
2527
-setup: cwd: $TRASH_DIRECTORY/18
2528
+setup: cwd: $here/18
2529
setup: prefix: (null)
2530
EOF
2531
test_repo 18 .git
@@ -2532,19 +2533,19 @@ EOF
2533
2534
test_expect_success '#18: at root' '
2535
cat >18/expected <<EOF &&
2535
-setup: git_dir: $TRASH_DIRECTORY/18/.git
2536
+setup: git_dir: $here/18/.git
2537
setup: worktree: (null)
2537
-setup: cwd: $TRASH_DIRECTORY/18
2538
+setup: cwd: $here/18
2539
setup: prefix: (null)
2540
EOF
2540
- test_repo 18 "$TRASH_DIRECTORY/18/.git"
2541
+ test_repo 18 "$here/18/.git"
2542
'
2543
2544
test_expect_success '#18: (rel) in subdir' '
2545
cat >18/sub/expected <<EOF &&
2546
setup: git_dir: ../.git
2547
setup: worktree: (null)
2547
-setup: cwd: $TRASH_DIRECTORY/18/sub
2548
+setup: cwd: $here/18/sub
2549
setup: prefix: (null)
2550
EOF
2551
test_repo 18/sub ../.git
@@ -2552,12 +2553,12 @@ EOF
2553
2554
test_expect_success '#18: in subdir' '
2555
cat >18/sub/expected <<EOF &&
2555
-setup: git_dir: $TRASH_DIRECTORY/18/.git
2556
+setup: git_dir: $here/18/.git
2557
setup: worktree: (null)
2557
-setup: cwd: $TRASH_DIRECTORY/18/sub
2558
+setup: cwd: $here/18/sub
2559
setup: prefix: (null)
2560
EOF
2560
- test_repo 18/sub "$TRASH_DIRECTORY/18/.git"
2561
+ test_repo 18/sub "$here/18/.git"
2562
'
2563
2564
#
@@ -2589,18 +2590,18 @@ test_expect_success '#19: setup' '
2590
test_expect_success '#19: GIT_DIR(rel), GIT_WORK_TREE=root at root' '
2591
cat >19/expected <<EOF &&
2592
setup: git_dir: .git
2592
-setup: worktree: $TRASH_DIRECTORY/19
2593
-setup: cwd: $TRASH_DIRECTORY/19
2593
+setup: worktree: $here/19
2594
+setup: cwd: $here/19
2595
setup: prefix: (null)
2596
EOF
2596
- test_repo 19 .git "$TRASH_DIRECTORY/19"
2597
+ test_repo 19 .git "$here/19"
2598
'
2599
2600
test_expect_success '#19: GIT_DIR(rel), GIT_WORK_TREE=root(rel) at root' '
2601
cat >19/expected <<EOF &&
2602
setup: git_dir: .git
2602
-setup: worktree: $TRASH_DIRECTORY/19
2603
-setup: cwd: $TRASH_DIRECTORY/19
2603
+setup: worktree: $here/19
2604
+setup: cwd: $here/19
2605
setup: prefix: (null)
2606
EOF
2607
test_repo 19 .git .
@@ -2608,39 +2609,39 @@ EOF
2609
2610
test_expect_success '#19: GIT_DIR, GIT_WORK_TREE=root at root' '
2611
cat >19/expected <<EOF &&
2611
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2612
-setup: worktree: $TRASH_DIRECTORY/19
2613
-setup: cwd: $TRASH_DIRECTORY/19
2612
+setup: git_dir: $here/19/.git
2613
+setup: worktree: $here/19
2614
+setup: cwd: $here/19
2615
setup: prefix: (null)
2616
EOF
2616
- test_repo 19 "$TRASH_DIRECTORY/19/.git" "$TRASH_DIRECTORY/19"
2617
+ test_repo 19 "$here/19/.git" "$here/19"
2618
'
2619
2620
test_expect_success '#19: GIT_DIR, GIT_WORK_TREE=root(rel) at root' '
2621
cat >19/expected <<EOF &&
2621
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2622
-setup: worktree: $TRASH_DIRECTORY/19
2623
-setup: cwd: $TRASH_DIRECTORY/19
2622
+setup: git_dir: $here/19/.git
2623
+setup: worktree: $here/19
2624
+setup: cwd: $here/19
2625
setup: prefix: (null)
2626
EOF
2626
- test_repo 19 "$TRASH_DIRECTORY/19/.git" .
2627
+ test_repo 19 "$here/19/.git" .
2628
'
2629
2630
test_expect_success '#19: GIT_DIR(rel), GIT_WORKTREE=root in subdir' '
2631
cat >19/sub/sub/expected <<EOF &&
2631
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2632
-setup: worktree: $TRASH_DIRECTORY/19
2633
-setup: cwd: $TRASH_DIRECTORY/19
2632
+setup: git_dir: $here/19/.git
2633
+setup: worktree: $here/19
2634
+setup: cwd: $here/19
2635
setup: prefix: sub/sub/
2636
EOF
2636
- test_repo 19/sub/sub ../../.git "$TRASH_DIRECTORY/19"
2637
+ test_repo 19/sub/sub ../../.git "$here/19"
2638
'
2639
2640
test_expect_success '#19: GIT_DIR(rel), GIT_WORKTREE=root(rel) in subdir' '
2641
cat >19/sub/sub/expected <<EOF &&
2641
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2642
-setup: worktree: $TRASH_DIRECTORY/19
2643
-setup: cwd: $TRASH_DIRECTORY/19
2642
+setup: git_dir: $here/19/.git
2643
+setup: worktree: $here/19
2644
+setup: cwd: $here/19
2645
setup: prefix: sub/sub/
2646
EOF
2647
test_repo 19/sub/sub ../../.git ../..
@@ -2648,39 +2649,39 @@ EOF
2649
2650
test_expect_success '#19: GIT_DIR, GIT_WORKTREE=root in subdir' '
2651
cat >19/sub/expected <<EOF &&
2651
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2652
-setup: worktree: $TRASH_DIRECTORY/19
2653
-setup: cwd: $TRASH_DIRECTORY/19
2652
+setup: git_dir: $here/19/.git
2653
+setup: worktree: $here/19
2654
+setup: cwd: $here/19
2655
setup: prefix: sub/
2656
EOF
2656
- test_repo 19/sub "$TRASH_DIRECTORY/19/.git" "$TRASH_DIRECTORY/19"
2657
+ test_repo 19/sub "$here/19/.git" "$here/19"
2658
'
2659
2660
test_expect_success '#19: GIT_DIR, GIT_WORKTREE=root(rel) in subdir' '
2661
cat >19/sub/sub/expected <<EOF &&
2661
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2662
-setup: worktree: $TRASH_DIRECTORY/19
2663
-setup: cwd: $TRASH_DIRECTORY/19
2662
+setup: git_dir: $here/19/.git
2663
+setup: worktree: $here/19
2664
+setup: cwd: $here/19
2665
setup: prefix: sub/sub/
2666
EOF
2666
- test_repo 19/sub/sub "$TRASH_DIRECTORY/19/.git" ../..
2667
+ test_repo 19/sub/sub "$here/19/.git" ../..
2668
'
2669
2670
test_expect_success '#19: GIT_DIR(rel), GIT_WORK_TREE=wt at root' '
2671
cat >19/expected <<EOF &&
2672
setup: git_dir: .git
2672
-setup: worktree: $TRASH_DIRECTORY/19/wt
2673
-setup: cwd: $TRASH_DIRECTORY/19
2673
+setup: worktree: $here/19/wt
2674
+setup: cwd: $here/19
2675
setup: prefix: (null)
2676
EOF
2676
- test_repo 19 .git "$TRASH_DIRECTORY/19/wt"
2677
+ test_repo 19 .git "$here/19/wt"
2678
'
2679
2680
test_expect_success '#19: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) at root' '
2681
cat >19/expected <<EOF &&
2682
setup: git_dir: .git
2682
-setup: worktree: $TRASH_DIRECTORY/19/wt
2683
-setup: cwd: $TRASH_DIRECTORY/19
2683
+setup: worktree: $here/19/wt
2684
+setup: cwd: $here/19
2685
setup: prefix: (null)
2686
EOF
2687
test_repo 19 .git wt
@@ -2688,39 +2689,39 @@ EOF
2689
2690
test_expect_success '#19: GIT_DIR, GIT_WORK_TREE=wt(rel) at root' '
2691
cat >19/expected <<EOF &&
2691
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2692
-setup: worktree: $TRASH_DIRECTORY/19/wt
2693
-setup: cwd: $TRASH_DIRECTORY/19
2692
+setup: git_dir: $here/19/.git
2693
+setup: worktree: $here/19/wt
2694
+setup: cwd: $here/19
2695
setup: prefix: (null)
2696
EOF
2696
- test_repo 19 "$TRASH_DIRECTORY/19/.git" wt
2697
+ test_repo 19 "$here/19/.git" wt
2698
'
2699
2700
test_expect_success '#19: GIT_DIR, GIT_WORK_TREE=wt at root' '
2701
cat >19/expected <<EOF &&
2701
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2702
-setup: worktree: $TRASH_DIRECTORY/19/wt
2703
-setup: cwd: $TRASH_DIRECTORY/19
2702
+setup: git_dir: $here/19/.git
2703
+setup: worktree: $here/19/wt
2704
+setup: cwd: $here/19
2705
setup: prefix: (null)
2706
EOF
2706
- test_repo 19 "$TRASH_DIRECTORY/19/.git" "$TRASH_DIRECTORY/19/wt"
2707
+ test_repo 19 "$here/19/.git" "$here/19/wt"
2708
'
2709
2710
test_expect_success '#19: GIT_DIR(rel), GIT_WORK_TREE=wt in subdir' '
2711
cat >19/sub/sub/expected <<EOF &&
2712
setup: git_dir: ../../.git
2712
-setup: worktree: $TRASH_DIRECTORY/19/wt
2713
-setup: cwd: $TRASH_DIRECTORY/19/sub/sub
2713
+setup: worktree: $here/19/wt
2714
+setup: cwd: $here/19/sub/sub
2715
setup: prefix: (null)
2716
EOF
2716
- test_repo 19/sub/sub ../../.git "$TRASH_DIRECTORY/19/wt"
2717
+ test_repo 19/sub/sub ../../.git "$here/19/wt"
2718
'
2719
2720
test_expect_success '#19: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) in subdir' '
2721
cat >19/sub/sub/expected <<EOF &&
2722
setup: git_dir: ../../.git
2722
-setup: worktree: $TRASH_DIRECTORY/19/wt
2723
-setup: cwd: $TRASH_DIRECTORY/19/sub/sub
2723
+setup: worktree: $here/19/wt
2724
+setup: cwd: $here/19/sub/sub
2725
setup: prefix: (null)
2726
EOF
2727
test_repo 19/sub/sub ../../.git ../../wt
@@ -2728,39 +2729,39 @@ EOF
2729
2730
test_expect_success '#19: GIT_DIR, GIT_WORK_TREE=wt(rel) in subdir' '
2731
cat >19/sub/sub/expected <<EOF &&
2731
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2732
-setup: worktree: $TRASH_DIRECTORY/19/wt
2733
-setup: cwd: $TRASH_DIRECTORY/19/sub/sub
2732
+setup: git_dir: $here/19/.git
2733
+setup: worktree: $here/19/wt
2734
+setup: cwd: $here/19/sub/sub
2735
setup: prefix: (null)
2736
EOF
2736
- test_repo 19/sub/sub "$TRASH_DIRECTORY/19/.git" ../../wt
2737
+ test_repo 19/sub/sub "$here/19/.git" ../../wt
2738
'
2739
2740
test_expect_success '#19: GIT_DIR, GIT_WORK_TREE=wt in subdir' '
2741
cat >19/sub/sub/expected <<EOF &&
2741
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2742
-setup: worktree: $TRASH_DIRECTORY/19/wt
2743
-setup: cwd: $TRASH_DIRECTORY/19/sub/sub
2742
+setup: git_dir: $here/19/.git
2743
+setup: worktree: $here/19/wt
2744
+setup: cwd: $here/19/sub/sub
2745
setup: prefix: (null)
2746
EOF
2746
- test_repo 19/sub/sub "$TRASH_DIRECTORY/19/.git" "$TRASH_DIRECTORY/19/wt"
2747
+ test_repo 19/sub/sub "$here/19/.git" "$here/19/wt"
2748
'
2749
2750
test_expect_success '#19: GIT_DIR(rel), GIT_WORK_TREE=.. at root' '
2751
cat >19/expected <<EOF &&
2751
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2752
-setup: worktree: $TRASH_DIRECTORY
2753
-setup: cwd: $TRASH_DIRECTORY
2752
+setup: git_dir: $here/19/.git
2753
+setup: worktree: $here
2754
+setup: cwd: $here
2755
setup: prefix: 19/
2756
EOF
2756
- test_repo 19 .git "$TRASH_DIRECTORY"
2757
+ test_repo 19 .git "$here"
2758
'
2759
2760
test_expect_success '#19: GIT_DIR(rel), GIT_WORK_TREE=..(rel) at root' '
2761
cat >19/expected <<EOF &&
2761
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2762
-setup: worktree: $TRASH_DIRECTORY
2763
-setup: cwd: $TRASH_DIRECTORY
2762
+setup: git_dir: $here/19/.git
2763
+setup: worktree: $here
2764
+setup: cwd: $here
2765
setup: prefix: 19/
2766
EOF
2767
test_repo 19 .git ..
@@ -2768,39 +2769,39 @@ EOF
2769
2770
test_expect_success '#19: GIT_DIR, GIT_WORK_TREE=..(rel) at root' '
2771
cat >19/expected <<EOF &&
2771
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2772
-setup: worktree: $TRASH_DIRECTORY
2773
-setup: cwd: $TRASH_DIRECTORY
2772
+setup: git_dir: $here/19/.git
2773
+setup: worktree: $here
2774
+setup: cwd: $here
2775
setup: prefix: 19/
2776
EOF
2776
- test_repo 19 "$TRASH_DIRECTORY/19/.git" ..
2777
+ test_repo 19 "$here/19/.git" ..
2778
'
2779
2780
test_expect_success '#19: GIT_DIR, GIT_WORK_TREE=.. at root' '
2781
cat >19/expected <<EOF &&
2781
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2782
-setup: worktree: $TRASH_DIRECTORY
2783
-setup: cwd: $TRASH_DIRECTORY
2782
+setup: git_dir: $here/19/.git
2783
+setup: worktree: $here
2784
+setup: cwd: $here
2785
setup: prefix: 19/
2786
EOF
2786
- test_repo 19 "$TRASH_DIRECTORY/19/.git" "$TRASH_DIRECTORY"
2787
+ test_repo 19 "$here/19/.git" "$here"
2788
'
2789
2790
test_expect_success '#19: GIT_DIR(rel), GIT_WORK_TREE=.. in subdir' '
2791
cat >19/sub/sub/expected <<EOF &&
2791
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2792
-setup: worktree: $TRASH_DIRECTORY
2793
-setup: cwd: $TRASH_DIRECTORY
2792
+setup: git_dir: $here/19/.git
2793
+setup: worktree: $here
2794
+setup: cwd: $here
2795
setup: prefix: 19/sub/sub/
2796
EOF
2796
- test_repo 19/sub/sub ../../.git "$TRASH_DIRECTORY"
2797
+ test_repo 19/sub/sub ../../.git "$here"
2798
'
2799
2800
test_expect_success '#19: GIT_DIR(rel), GIT_WORK_TREE=..(rel) in subdir' '
2801
cat >19/sub/sub/expected <<EOF &&
2801
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2802
-setup: worktree: $TRASH_DIRECTORY
2803
-setup: cwd: $TRASH_DIRECTORY
2802
+setup: git_dir: $here/19/.git
2803
+setup: worktree: $here
2804
+setup: cwd: $here
2805
setup: prefix: 19/sub/sub/
2806
EOF
2807
test_repo 19/sub/sub ../../.git ../../..
@@ -2808,22 +2809,22 @@ EOF
2809
2810
test_expect_success '#19: GIT_DIR, GIT_WORK_TREE=..(rel) in subdir' '
2811
cat >19/sub/sub/expected <<EOF &&
2811
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2812
-setup: worktree: $TRASH_DIRECTORY
2813
-setup: cwd: $TRASH_DIRECTORY
2812
+setup: git_dir: $here/19/.git
2813
+setup: worktree: $here
2814
+setup: cwd: $here
2815
setup: prefix: 19/sub/sub/
2816
EOF
2816
- test_repo 19/sub/sub "$TRASH_DIRECTORY/19/.git" ../../../
2817
+ test_repo 19/sub/sub "$here/19/.git" ../../../
2818
'
2819
2820
test_expect_success '#19: GIT_DIR, GIT_WORK_TREE=.. in subdir' '
2821
cat >19/sub/sub/expected <<EOF &&
2821
-setup: git_dir: $TRASH_DIRECTORY/19/.git
2822
-setup: worktree: $TRASH_DIRECTORY
2823
-setup: cwd: $TRASH_DIRECTORY
2822
+setup: git_dir: $here/19/.git
2823
+setup: worktree: $here
2824
+setup: cwd: $here
2825
setup: prefix: 19/sub/sub/
2826
EOF
2826
- test_repo 19/sub/sub "$TRASH_DIRECTORY/19/.git" "$TRASH_DIRECTORY"
2827
+ test_repo 19/sub/sub "$here/19/.git" "$here"
2828
'
2829
2830
#
@@ -2857,7 +2858,7 @@ test_expect_success '#20.1: at .git' '
2858
cat >20/.git/expected <<EOF &&
2859
setup: git_dir: .
2860
setup: worktree: (null)
2860
-setup: cwd: $TRASH_DIRECTORY/20/.git
2861
+setup: cwd: $here/20/.git
2862
setup: prefix: (null)
2863
EOF
2864
test_repo 20/.git
@@ -2865,9 +2866,9 @@ EOF
2866
2867
test_expect_success '#20.1: in .git/wt' '
2868
cat >20/.git/wt/expected <<EOF &&
2868
-setup: git_dir: $TRASH_DIRECTORY/20/.git
2869
+setup: git_dir: $here/20/.git
2870
setup: worktree: (null)
2870
-setup: cwd: $TRASH_DIRECTORY/20/.git/wt
2871
+setup: cwd: $here/20/.git/wt
2872
setup: prefix: (null)
2873
EOF
2874
test_repo 20/.git/wt
@@ -2875,9 +2876,9 @@ EOF
2876
2877
test_expect_success '#20.1: in .git/wt/sub' '
2878
cat >20/.git/wt/sub/expected <<EOF &&
2878
-setup: git_dir: $TRASH_DIRECTORY/20/.git
2879
+setup: git_dir: $here/20/.git
2880
setup: worktree: (null)
2880
-setup: cwd: $TRASH_DIRECTORY/20/.git/wt/sub
2881
+setup: cwd: $here/20/.git/wt/sub
2882
setup: prefix: (null)
2883
EOF
2884
test_repo 20/.git/wt/sub
@@ -2901,14 +2902,14 @@ EOF
2902
# core.worktree is ignored -> #16.2
2903
2904
test_expect_success '#20.2: setup' '
2904
- git config --file="$TRASH_DIRECTORY/20/.git/config" core.bare true
2905
+ git config --file="$here/20/.git/config" core.bare true
2906
'
2907
2908
test_expect_success '#20.2: at .git' '
2909
cat >20/.git/expected <<EOF &&
2910
setup: git_dir: .
2911
setup: worktree: (null)
2911
-setup: cwd: $TRASH_DIRECTORY/20/.git
2912
+setup: cwd: $here/20/.git
2913
setup: prefix: (null)
2914
EOF
2915
test_repo 20/.git
@@ -2916,9 +2917,9 @@ EOF
2917
2918
test_expect_success '#20.2: in .git/wt' '
2919
cat >20/.git/wt/expected <<EOF &&
2919
-setup: git_dir: $TRASH_DIRECTORY/20/.git
2920
+setup: git_dir: $here/20/.git
2921
setup: worktree: (null)
2921
-setup: cwd: $TRASH_DIRECTORY/20/.git/wt
2922
+setup: cwd: $here/20/.git/wt
2923
setup: prefix: (null)
2924
EOF
2925
test_repo 20/.git/wt
@@ -2926,9 +2927,9 @@ EOF
2927
2928
test_expect_success '#20.2: in .git/wt/sub' '
2929
cat >20/.git/wt/sub/expected <<EOF &&
2929
-setup: git_dir: $TRASH_DIRECTORY/20/.git
2930
+setup: git_dir: $here/20/.git
2931
setup: worktree: (null)
2931
-setup: cwd: $TRASH_DIRECTORY/20/.git/wt/sub
2932
+setup: cwd: $here/20/.git/wt/sub
2933
setup: prefix: (null)
2934
EOF
2935
test_repo 20/.git/wt/sub
@@ -2938,7 +2939,7 @@ test_expect_success '#20.2: at root' '
2939
cat >20/expected <<EOF &&
2940
setup: git_dir: .git
2941
setup: worktree: (null)
2941
-setup: cwd: $TRASH_DIRECTORY/20
2942
+setup: cwd: $here/20
2943
setup: prefix: (null)
2944
EOF
2945
test_repo 20
@@ -2946,9 +2947,9 @@ EOF
2947
2948
test_expect_success '#20.2: in subdir' '
2949
cat >20/sub/expected <<EOF &&
2949
-setup: git_dir: $TRASH_DIRECTORY/20/.git
2950
+setup: git_dir: $here/20/.git
2951
setup: worktree: (null)
2951
-setup: cwd: $TRASH_DIRECTORY/20/sub
2952
+setup: cwd: $here/20/sub
2953
setup: prefix: (null)
2954
EOF
2955
test_repo 20/sub
@@ -2987,7 +2988,7 @@ test_expect_success '#21.1: at .git' '
2988
cat >21/.git/expected <<EOF &&
2989
setup: git_dir: .
2990
setup: worktree: (null)
2990
-setup: cwd: $TRASH_DIRECTORY/21/.git
2991
+setup: cwd: $here/21/.git
2992
setup: prefix: (null)
2993
EOF
2994
test_repo 21/.git
@@ -2995,9 +2996,9 @@ EOF
2996
2997
test_expect_success '#21.1: in .git/wt' '
2998
cat >21/.git/wt/expected <<EOF &&
2998
-setup: git_dir: $TRASH_DIRECTORY/21/.git
2999
+setup: git_dir: $here/21/.git
3000
setup: worktree: (null)
3000
-setup: cwd: $TRASH_DIRECTORY/21/.git/wt
3001
+setup: cwd: $here/21/.git/wt
3002
setup: prefix: (null)
3003
EOF
3004
test_repo 21/.git/wt
@@ -3005,9 +3006,9 @@ EOF
3006
3007
test_expect_success '#21.1: in .git/wt/sub' '
3008
cat >21/.git/wt/sub/expected <<EOF &&
3008
-setup: git_dir: $TRASH_DIRECTORY/21/.git
3009
+setup: git_dir: $here/21/.git
3010
setup: worktree: (null)
3010
-setup: cwd: $TRASH_DIRECTORY/21/.git/wt/sub
3011
+setup: cwd: $here/21/.git/wt/sub
3012
setup: prefix: (null)
3013
EOF
3014
test_repo 21/.git/wt/sub
@@ -3031,14 +3032,14 @@ EOF
3032
# GIT_WORK_TREE/core.worktree are ignored -> #20.2
3033
3034
test_expect_success '#21.2: setup' '
3034
- git config --file="$TRASH_DIRECTORY/21/.git/config" core.bare true
3035
+ git config --file="$here/21/.git/config" core.bare true
3036
'
3037
3038
test_expect_success '#21.2: at .git' '
3039
cat >21/.git/expected <<EOF &&
3040
setup: git_dir: .
3041
setup: worktree: (null)
3041
-setup: cwd: $TRASH_DIRECTORY/21/.git
3042
+setup: cwd: $here/21/.git
3043
setup: prefix: (null)
3044
EOF
3045
test_repo 21/.git
@@ -3046,9 +3047,9 @@ EOF
3047
3048
test_expect_success '#21.2: in .git/wt' '
3049
cat >21/.git/wt/expected <<EOF &&
3049
-setup: git_dir: $TRASH_DIRECTORY/21/.git
3050
+setup: git_dir: $here/21/.git
3051
setup: worktree: (null)
3051
-setup: cwd: $TRASH_DIRECTORY/21/.git/wt
3052
+setup: cwd: $here/21/.git/wt
3053
setup: prefix: (null)
3054
EOF
3055
test_repo 21/.git/wt
@@ -3056,9 +3057,9 @@ EOF
3057
3058
test_expect_success '#21.2: in .git/wt/sub' '
3059
cat >21/.git/wt/sub/expected <<EOF &&
3059
-setup: git_dir: $TRASH_DIRECTORY/21/.git
3060
+setup: git_dir: $here/21/.git
3061
setup: worktree: (null)
3061
-setup: cwd: $TRASH_DIRECTORY/21/.git/wt/sub
3062
+setup: cwd: $here/21/.git/wt/sub
3063
setup: prefix: (null)
3064
EOF
3065
test_repo 21/.git/wt/sub
@@ -3068,7 +3069,7 @@ test_expect_success '#21.2: at root' '
3069
cat >21/expected <<EOF &&
3070
setup: git_dir: .git
3071
setup: worktree: (null)
3071
-setup: cwd: $TRASH_DIRECTORY/21
3072
+setup: cwd: $here/21
3073
setup: prefix: (null)
3074
EOF
3075
test_repo 21
@@ -3076,9 +3077,9 @@ EOF
3077
3078
test_expect_success '#21.2: in subdir' '
3079
cat >21/sub/expected <<EOF &&
3079
-setup: git_dir: $TRASH_DIRECTORY/21/.git
3080
+setup: git_dir: $here/21/.git
3081
setup: worktree: (null)
3081
-setup: cwd: $TRASH_DIRECTORY/21/sub
3082
+setup: cwd: $here/21/sub
3083
setup: prefix: (null)
3084
EOF
3085
test_repo 21/sub
@@ -3119,265 +3120,265 @@ test_expect_success '#22.1: setup' '
3120
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=. at .git' '
3121
cat >22/.git/expected <<EOF &&
3122
setup: git_dir: .
3122
-setup: worktree: $TRASH_DIRECTORY/22/.git
3123
-setup: cwd: $TRASH_DIRECTORY/22/.git
3123
+setup: worktree: $here/22/.git
3124
+setup: cwd: $here/22/.git
3125
setup: prefix: (null)
3126
EOF
3126
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22/.git" &&
3127
+ git config --file="$here/22/.git/config" core.worktree "$here/22/.git" &&
3128
test_repo 22/.git .
3129
'
3130
3131
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=.(rel) at .git' '
3132
cat >22/.git/expected <<EOF &&
3133
setup: git_dir: .
3133
-setup: worktree: $TRASH_DIRECTORY/22/.git
3134
-setup: cwd: $TRASH_DIRECTORY/22/.git
3134
+setup: worktree: $here/22/.git
3135
+setup: cwd: $here/22/.git
3136
setup: prefix: (null)
3137
EOF
3137
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree . &&
3138
+ git config --file="$here/22/.git/config" core.worktree . &&
3139
test_repo 22/.git .
3140
'
3141
3142
test_expect_success '#22.1: GIT_DIR, core.worktree=. at .git' '
3143
cat >22/.git/expected <<EOF &&
3143
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3144
-setup: worktree: $TRASH_DIRECTORY/22/.git
3145
-setup: cwd: $TRASH_DIRECTORY/22/.git
3144
+setup: git_dir: $here/22/.git
3145
+setup: worktree: $here/22/.git
3146
+setup: cwd: $here/22/.git
3147
setup: prefix: (null)
3148
EOF
3148
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22/.git" &&
3149
- test_repo 22/.git "$TRASH_DIRECTORY/22/.git"
3149
+ git config --file="$here/22/.git/config" core.worktree "$here/22/.git" &&
3150
+ test_repo 22/.git "$here/22/.git"
3151
'
3152
3153
test_expect_success '#22.1: GIT_DIR, core.worktree=.(rel) at root' '
3154
cat >22/.git/expected <<EOF &&
3154
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3155
-setup: worktree: $TRASH_DIRECTORY/22/.git
3156
-setup: cwd: $TRASH_DIRECTORY/22/.git
3155
+setup: git_dir: $here/22/.git
3156
+setup: worktree: $here/22/.git
3157
+setup: cwd: $here/22/.git
3158
setup: prefix: (null)
3159
EOF
3159
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree . &&
3160
- test_repo 22/.git "$TRASH_DIRECTORY/22/.git"
3160
+ git config --file="$here/22/.git/config" core.worktree . &&
3161
+ test_repo 22/.git "$here/22/.git"
3162
'
3163
3164
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=. in .git/sub' '
3165
cat >22/.git/sub/expected <<EOF &&
3165
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3166
-setup: worktree: $TRASH_DIRECTORY/22/.git
3167
-setup: cwd: $TRASH_DIRECTORY/22/.git
3166
+setup: git_dir: $here/22/.git
3167
+setup: worktree: $here/22/.git
3168
+setup: cwd: $here/22/.git
3169
setup: prefix: sub/
3170
EOF
3170
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22/.git" &&
3171
+ git config --file="$here/22/.git/config" core.worktree "$here/22/.git" &&
3172
test_repo 22/.git/sub ..
3173
'
3174
3175
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=.(rel) in .git/sub' '
3176
cat >22/.git/sub/expected <<EOF &&
3176
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3177
-setup: worktree: $TRASH_DIRECTORY/22/.git
3178
-setup: cwd: $TRASH_DIRECTORY/22/.git
3177
+setup: git_dir: $here/22/.git
3178
+setup: worktree: $here/22/.git
3179
+setup: cwd: $here/22/.git
3180
setup: prefix: sub/
3181
EOF
3181
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree . &&
3182
+ git config --file="$here/22/.git/config" core.worktree . &&
3183
test_repo 22/.git/sub/ ..
3184
'
3185
3186
test_expect_success '#22.1: GIT_DIR, core.worktree=. in .git/sub' '
3187
cat >22/.git/sub/expected <<EOF &&
3187
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3188
-setup: worktree: $TRASH_DIRECTORY/22/.git
3189
-setup: cwd: $TRASH_DIRECTORY/22/.git
3188
+setup: git_dir: $here/22/.git
3189
+setup: worktree: $here/22/.git
3190
+setup: cwd: $here/22/.git
3191
setup: prefix: sub/
3192
EOF
3192
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22/.git" &&
3193
- test_repo 22/.git/sub "$TRASH_DIRECTORY/22/.git"
3193
+ git config --file="$here/22/.git/config" core.worktree "$here/22/.git" &&
3194
+ test_repo 22/.git/sub "$here/22/.git"
3195
'
3196
3197
test_expect_success '#22.1: GIT_DIR, core.worktree=.(rel) in .git/sub' '
3198
cat >22/.git/sub/expected <<EOF &&
3198
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3199
-setup: worktree: $TRASH_DIRECTORY/22/.git
3200
-setup: cwd: $TRASH_DIRECTORY/22/.git
3199
+setup: git_dir: $here/22/.git
3200
+setup: worktree: $here/22/.git
3201
+setup: cwd: $here/22/.git
3202
setup: prefix: sub/
3203
EOF
3203
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree . &&
3204
- test_repo 22/.git/sub "$TRASH_DIRECTORY/22/.git"
3204
+ git config --file="$here/22/.git/config" core.worktree . &&
3205
+ test_repo 22/.git/sub "$here/22/.git"
3206
'
3207
3208
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=wt at .git' '
3209
cat >22/.git/expected <<EOF &&
3210
setup: git_dir: .
3210
-setup: worktree: $TRASH_DIRECTORY/22/.git/wt
3211
-setup: cwd: $TRASH_DIRECTORY/22/.git
3211
+setup: worktree: $here/22/.git/wt
3212
+setup: cwd: $here/22/.git
3213
setup: prefix: (null)
3214
EOF
3214
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22/.git/wt" &&
3215
+ git config --file="$here/22/.git/config" core.worktree "$here/22/.git/wt" &&
3216
test_repo 22/.git .
3217
'
3218
3219
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=wt(rel) at .git' '
3220
cat >22/.git/expected <<EOF &&
3221
setup: git_dir: .
3221
-setup: worktree: $TRASH_DIRECTORY/22/.git/wt
3222
-setup: cwd: $TRASH_DIRECTORY/22/.git
3222
+setup: worktree: $here/22/.git/wt
3223
+setup: cwd: $here/22/.git
3224
setup: prefix: (null)
3225
EOF
3225
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree wt &&
3226
+ git config --file="$here/22/.git/config" core.worktree wt &&
3227
test_repo 22/.git .
3228
'
3229
3230
test_expect_success '#22.1: GIT_DIR, core.worktree=wt(rel) at .git' '
3231
cat >22/.git/expected <<EOF &&
3231
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3232
-setup: worktree: $TRASH_DIRECTORY/22/.git/wt
3233
-setup: cwd: $TRASH_DIRECTORY/22/.git
3232
+setup: git_dir: $here/22/.git
3233
+setup: worktree: $here/22/.git/wt
3234
+setup: cwd: $here/22/.git
3235
setup: prefix: (null)
3236
EOF
3236
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree wt &&
3237
- test_repo 22/.git "$TRASH_DIRECTORY/22/.git"
3237
+ git config --file="$here/22/.git/config" core.worktree wt &&
3238
+ test_repo 22/.git "$here/22/.git"
3239
'
3240
3241
test_expect_success '#22.1: GIT_DIR, core.worktree=wt at .git' '
3242
cat >22/.git/expected <<EOF &&
3242
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3243
-setup: worktree: $TRASH_DIRECTORY/22/.git/wt
3244
-setup: cwd: $TRASH_DIRECTORY/22/.git
3243
+setup: git_dir: $here/22/.git
3244
+setup: worktree: $here/22/.git/wt
3245
+setup: cwd: $here/22/.git
3246
setup: prefix: (null)
3247
EOF
3247
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22/.git/wt" &&
3248
- test_repo 22/.git "$TRASH_DIRECTORY/22/.git"
3248
+ git config --file="$here/22/.git/config" core.worktree "$here/22/.git/wt" &&
3249
+ test_repo 22/.git "$here/22/.git"
3250
'
3251
3252
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=wt in .git/sub' '
3253
cat >22/.git/sub/expected <<EOF &&
3254
setup: git_dir: ..
3254
-setup: worktree: $TRASH_DIRECTORY/22/.git/wt
3255
-setup: cwd: $TRASH_DIRECTORY/22/.git/sub
3255
+setup: worktree: $here/22/.git/wt
3256
+setup: cwd: $here/22/.git/sub
3257
setup: prefix: (null)
3258
EOF
3258
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22/.git/wt" &&
3259
+ git config --file="$here/22/.git/config" core.worktree "$here/22/.git/wt" &&
3260
test_repo 22/.git/sub ..
3261
'
3262
3263
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=wt(rel) in .git/sub' '
3264
cat >22/.git/sub/expected <<EOF &&
3265
setup: git_dir: ..
3265
-setup: worktree: $TRASH_DIRECTORY/22/.git/wt
3266
-setup: cwd: $TRASH_DIRECTORY/22/.git/sub
3266
+setup: worktree: $here/22/.git/wt
3267
+setup: cwd: $here/22/.git/sub
3268
setup: prefix: (null)
3269
EOF
3269
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree wt &&
3270
+ git config --file="$here/22/.git/config" core.worktree wt &&
3271
test_repo 22/.git/sub ..
3272
'
3273
3274
test_expect_success '#22.1: GIT_DIR, core.worktree=wt(rel) in .git/sub' '
3275
cat >22/.git/sub/expected <<EOF &&
3275
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3276
-setup: worktree: $TRASH_DIRECTORY/22/.git/wt
3277
-setup: cwd: $TRASH_DIRECTORY/22/.git/sub
3276
+setup: git_dir: $here/22/.git
3277
+setup: worktree: $here/22/.git/wt
3278
+setup: cwd: $here/22/.git/sub
3279
setup: prefix: (null)
3280
EOF
3280
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree wt &&
3281
- test_repo 22/.git/sub "$TRASH_DIRECTORY/22/.git"
3281
+ git config --file="$here/22/.git/config" core.worktree wt &&
3282
+ test_repo 22/.git/sub "$here/22/.git"
3283
'
3284
3285
test_expect_success '#22.1: GIT_DIR, core.worktree=wt in .git/sub' '
3286
cat >22/.git/sub/expected <<EOF &&
3286
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3287
-setup: worktree: $TRASH_DIRECTORY/22/.git/wt
3288
-setup: cwd: $TRASH_DIRECTORY/22/.git/sub
3287
+setup: git_dir: $here/22/.git
3288
+setup: worktree: $here/22/.git/wt
3289
+setup: cwd: $here/22/.git/sub
3290
setup: prefix: (null)
3291
EOF
3291
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22/.git/wt" &&
3292
- test_repo 22/.git/sub "$TRASH_DIRECTORY/22/.git"
3292
+ git config --file="$here/22/.git/config" core.worktree "$here/22/.git/wt" &&
3293
+ test_repo 22/.git/sub "$here/22/.git"
3294
'
3295
3296
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=.. at .git' '
3297
cat >22/.git/expected <<EOF &&
3297
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3298
-setup: worktree: $TRASH_DIRECTORY/22
3299
-setup: cwd: $TRASH_DIRECTORY/22
3298
+setup: git_dir: $here/22/.git
3299
+setup: worktree: $here/22
3300
+setup: cwd: $here/22
3301
setup: prefix: .git/
3302
EOF
3302
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22" &&
3303
+ git config --file="$here/22/.git/config" core.worktree "$here/22" &&
3304
test_repo 22/.git .
3305
'
3306
3307
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=..(rel) at .git' '
3308
cat >22/.git/expected <<EOF &&
3308
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3309
-setup: worktree: $TRASH_DIRECTORY/22
3310
-setup: cwd: $TRASH_DIRECTORY/22
3309
+setup: git_dir: $here/22/.git
3310
+setup: worktree: $here/22
3311
+setup: cwd: $here/22
3312
setup: prefix: .git/
3313
EOF
3313
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree .. &&
3314
+ git config --file="$here/22/.git/config" core.worktree .. &&
3315
test_repo 22/.git .
3316
'
3317
3318
test_expect_success '#22.1: GIT_DIR, core.worktree=..(rel) at .git' '
3319
cat >22/.git/expected <<EOF &&
3319
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3320
-setup: worktree: $TRASH_DIRECTORY/22
3321
-setup: cwd: $TRASH_DIRECTORY/22
3320
+setup: git_dir: $here/22/.git
3321
+setup: worktree: $here/22
3322
+setup: cwd: $here/22
3323
setup: prefix: .git/
3324
EOF
3324
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree .. &&
3325
- test_repo 22/.git "$TRASH_DIRECTORY/22/.git"
3325
+ git config --file="$here/22/.git/config" core.worktree .. &&
3326
+ test_repo 22/.git "$here/22/.git"
3327
'
3328
3329
test_expect_success '#22.1: GIT_DIR, core.worktree=.. at .git' '
3330
cat >22/.git/expected <<EOF &&
3330
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3331
-setup: worktree: $TRASH_DIRECTORY/22
3332
-setup: cwd: $TRASH_DIRECTORY/22
3331
+setup: git_dir: $here/22/.git
3332
+setup: worktree: $here/22
3333
+setup: cwd: $here/22
3334
setup: prefix: .git/
3335
EOF
3335
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22" &&
3336
- test_repo 22/.git "$TRASH_DIRECTORY/22/.git"
3336
+ git config --file="$here/22/.git/config" core.worktree "$here/22" &&
3337
+ test_repo 22/.git "$here/22/.git"
3338
'
3339
3340
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=.. in .git/sub' '
3341
cat >22/.git/sub/expected <<EOF &&
3341
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3342
-setup: worktree: $TRASH_DIRECTORY/22
3343
-setup: cwd: $TRASH_DIRECTORY/22
3342
+setup: git_dir: $here/22/.git
3343
+setup: worktree: $here/22
3344
+setup: cwd: $here/22
3345
setup: prefix: .git/sub/
3346
EOF
3346
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22" &&
3347
+ git config --file="$here/22/.git/config" core.worktree "$here/22" &&
3348
test_repo 22/.git/sub ..
3349
'
3350
3351
test_expect_success '#22.1: GIT_DIR(rel), core.worktree=..(rel) in .git/sub' '
3352
cat >22/.git/sub/expected <<EOF &&
3352
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3353
-setup: worktree: $TRASH_DIRECTORY/22
3354
-setup: cwd: $TRASH_DIRECTORY/22
3353
+setup: git_dir: $here/22/.git
3354
+setup: worktree: $here/22
3355
+setup: cwd: $here/22
3356
setup: prefix: .git/sub/
3357
EOF
3357
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree .. &&
3358
+ git config --file="$here/22/.git/config" core.worktree .. &&
3359
test_repo 22/.git/sub ..
3360
'
3361
3362
test_expect_success '#22.1: GIT_DIR, core.worktree=..(rel) in .git/sub' '
3363
cat >22/.git/sub/expected <<EOF &&
3363
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3364
-setup: worktree: $TRASH_DIRECTORY/22
3365
-setup: cwd: $TRASH_DIRECTORY/22
3364
+setup: git_dir: $here/22/.git
3365
+setup: worktree: $here/22
3366
+setup: cwd: $here/22
3367
setup: prefix: .git/sub/
3368
EOF
3368
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree .. &&
3369
- test_repo 22/.git/sub "$TRASH_DIRECTORY/22/.git"
3369
+ git config --file="$here/22/.git/config" core.worktree .. &&
3370
+ test_repo 22/.git/sub "$here/22/.git"
3371
'
3372
3373
test_expect_success '#22.1: GIT_DIR, core.worktree=.. in .git/sub' '
3374
cat >22/.git/sub/expected <<EOF &&
3374
-setup: git_dir: $TRASH_DIRECTORY/22/.git
3375
-setup: worktree: $TRASH_DIRECTORY/22
3376
-setup: cwd: $TRASH_DIRECTORY/22
3375
+setup: git_dir: $here/22/.git
3376
+setup: worktree: $here/22
3377
+setup: cwd: $here/22
3378
setup: prefix: .git/sub/
3379
EOF
3379
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.worktree "$TRASH_DIRECTORY/22" &&
3380
- test_repo 22/.git/sub "$TRASH_DIRECTORY/22/.git"
3380
+ git config --file="$here/22/.git/config" core.worktree "$here/22" &&
3381
+ test_repo 22/.git/sub "$here/22/.git"
3382
'
3383
3384
#
@@ -3398,7 +3399,7 @@ EOF
3399
# core.worktree and core.bare conflict, won't fly.
3400
3401
test_expect_success '#22.2: setup' '
3401
- git config --file="$TRASH_DIRECTORY/22/.git/config" core.bare true
3402
+ git config --file="$here/22/.git/config" core.bare true
3403
'
3404
3405
test_expect_success '#22.2: at .git' '
@@ -3451,18 +3452,18 @@ test_expect_success '#23: setup' '
3452
test_expect_success '#23: GIT_DIR(rel), GIT_WORK_TREE=root at root' '
3453
cat >23/expected <<EOF &&
3454
setup: git_dir: .git
3454
-setup: worktree: $TRASH_DIRECTORY/23
3455
-setup: cwd: $TRASH_DIRECTORY/23
3455
+setup: worktree: $here/23
3456
+setup: cwd: $here/23
3457
setup: prefix: (null)
3458
EOF
3458
- test_repo 23 .git "$TRASH_DIRECTORY/23"
3459
+ test_repo 23 .git "$here/23"
3460
'
3461
3462
test_expect_success '#23: GIT_DIR(rel), GIT_WORK_TREE=root(rel) at root' '
3463
cat >23/expected <<EOF &&
3464
setup: git_dir: .git
3464
-setup: worktree: $TRASH_DIRECTORY/23
3465
-setup: cwd: $TRASH_DIRECTORY/23
3465
+setup: worktree: $here/23
3466
+setup: cwd: $here/23
3467
setup: prefix: (null)
3468
EOF
3469
test_repo 23 .git .
@@ -3470,39 +3471,39 @@ EOF
3471
3472
test_expect_success '#23: GIT_DIR, GIT_WORK_TREE=root at root' '
3473
cat >23/expected <<EOF &&
3473
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3474
-setup: worktree: $TRASH_DIRECTORY/23
3475
-setup: cwd: $TRASH_DIRECTORY/23
3474
+setup: git_dir: $here/23/.git
3475
+setup: worktree: $here/23
3476
+setup: cwd: $here/23
3477
setup: prefix: (null)
3478
EOF
3478
- test_repo 23 "$TRASH_DIRECTORY/23/.git" "$TRASH_DIRECTORY/23"
3479
+ test_repo 23 "$here/23/.git" "$here/23"
3480
'
3481
3482
test_expect_success '#23: GIT_DIR, GIT_WORK_TREE=root(rel) at root' '
3483
cat >23/expected <<EOF &&
3483
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3484
-setup: worktree: $TRASH_DIRECTORY/23
3485
-setup: cwd: $TRASH_DIRECTORY/23
3484
+setup: git_dir: $here/23/.git
3485
+setup: worktree: $here/23
3486
+setup: cwd: $here/23
3487
setup: prefix: (null)
3488
EOF
3488
- test_repo 23 "$TRASH_DIRECTORY/23/.git" .
3489
+ test_repo 23 "$here/23/.git" .
3490
'
3491
3492
test_expect_success '#23: GIT_DIR(rel), GIT_WORKTREE=root in subdir' '
3493
cat >23/sub/sub/expected <<EOF &&
3493
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3494
-setup: worktree: $TRASH_DIRECTORY/23
3495
-setup: cwd: $TRASH_DIRECTORY/23
3494
+setup: git_dir: $here/23/.git
3495
+setup: worktree: $here/23
3496
+setup: cwd: $here/23
3497
setup: prefix: sub/sub/
3498
EOF
3498
- test_repo 23/sub/sub ../../.git "$TRASH_DIRECTORY/23"
3499
+ test_repo 23/sub/sub ../../.git "$here/23"
3500
'
3501
3502
test_expect_success '#23: GIT_DIR(rel), GIT_WORKTREE=root(rel) in subdir' '
3503
cat >23/sub/sub/expected <<EOF &&
3503
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3504
-setup: worktree: $TRASH_DIRECTORY/23
3505
-setup: cwd: $TRASH_DIRECTORY/23
3504
+setup: git_dir: $here/23/.git
3505
+setup: worktree: $here/23
3506
+setup: cwd: $here/23
3507
setup: prefix: sub/sub/
3508
EOF
3509
test_repo 23/sub/sub ../../.git ../..
@@ -3510,39 +3511,39 @@ EOF
3511
3512
test_expect_success '#23: GIT_DIR, GIT_WORKTREE=root in subdir' '
3513
cat >23/sub/expected <<EOF &&
3513
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3514
-setup: worktree: $TRASH_DIRECTORY/23
3515
-setup: cwd: $TRASH_DIRECTORY/23
3514
+setup: git_dir: $here/23/.git
3515
+setup: worktree: $here/23
3516
+setup: cwd: $here/23
3517
setup: prefix: sub/
3518
EOF
3518
- test_repo 23/sub "$TRASH_DIRECTORY/23/.git" "$TRASH_DIRECTORY/23"
3519
+ test_repo 23/sub "$here/23/.git" "$here/23"
3520
'
3521
3522
test_expect_success '#23: GIT_DIR, GIT_WORKTREE=root(rel) in subdir' '
3523
cat >23/sub/sub/expected <<EOF &&
3523
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3524
-setup: worktree: $TRASH_DIRECTORY/23
3525
-setup: cwd: $TRASH_DIRECTORY/23
3524
+setup: git_dir: $here/23/.git
3525
+setup: worktree: $here/23
3526
+setup: cwd: $here/23
3527
setup: prefix: sub/sub/
3528
EOF
3528
- test_repo 23/sub/sub "$TRASH_DIRECTORY/23/.git" ../..
3529
+ test_repo 23/sub/sub "$here/23/.git" ../..
3530
'
3531
3532
test_expect_success '#23: GIT_DIR(rel), GIT_WORK_TREE=wt at root' '
3533
cat >23/expected <<EOF &&
3534
setup: git_dir: .git
3534
-setup: worktree: $TRASH_DIRECTORY/23/wt
3535
-setup: cwd: $TRASH_DIRECTORY/23
3535
+setup: worktree: $here/23/wt
3536
+setup: cwd: $here/23
3537
setup: prefix: (null)
3538
EOF
3538
- test_repo 23 .git "$TRASH_DIRECTORY/23/wt"
3539
+ test_repo 23 .git "$here/23/wt"
3540
'
3541
3542
test_expect_success '#23: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) at root' '
3543
cat >23/expected <<EOF &&
3544
setup: git_dir: .git
3544
-setup: worktree: $TRASH_DIRECTORY/23/wt
3545
-setup: cwd: $TRASH_DIRECTORY/23
3545
+setup: worktree: $here/23/wt
3546
+setup: cwd: $here/23
3547
setup: prefix: (null)
3548
EOF
3549
test_repo 23 .git wt
@@ -3550,39 +3551,39 @@ EOF
3551
3552
test_expect_success '#23: GIT_DIR, GIT_WORK_TREE=wt(rel) at root' '
3553
cat >23/expected <<EOF &&
3553
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3554
-setup: worktree: $TRASH_DIRECTORY/23/wt
3555
-setup: cwd: $TRASH_DIRECTORY/23
3554
+setup: git_dir: $here/23/.git
3555
+setup: worktree: $here/23/wt
3556
+setup: cwd: $here/23
3557
setup: prefix: (null)
3558
EOF
3558
- test_repo 23 "$TRASH_DIRECTORY/23/.git" wt
3559
+ test_repo 23 "$here/23/.git" wt
3560
'
3561
3562
test_expect_success '#23: GIT_DIR, GIT_WORK_TREE=wt at root' '
3563
cat >23/expected <<EOF &&
3563
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3564
-setup: worktree: $TRASH_DIRECTORY/23/wt
3565
-setup: cwd: $TRASH_DIRECTORY/23
3564
+setup: git_dir: $here/23/.git
3565
+setup: worktree: $here/23/wt
3566
+setup: cwd: $here/23
3567
setup: prefix: (null)
3568
EOF
3568
- test_repo 23 "$TRASH_DIRECTORY/23/.git" "$TRASH_DIRECTORY/23/wt"
3569
+ test_repo 23 "$here/23/.git" "$here/23/wt"
3570
'
3571
3572
test_expect_success '#23: GIT_DIR(rel), GIT_WORK_TREE=wt in subdir' '
3573
cat >23/sub/sub/expected <<EOF &&
3574
setup: git_dir: ../../.git
3574
-setup: worktree: $TRASH_DIRECTORY/23/wt
3575
-setup: cwd: $TRASH_DIRECTORY/23/sub/sub
3575
+setup: worktree: $here/23/wt
3576
+setup: cwd: $here/23/sub/sub
3577
setup: prefix: (null)
3578
EOF
3578
- test_repo 23/sub/sub ../../.git "$TRASH_DIRECTORY/23/wt"
3579
+ test_repo 23/sub/sub ../../.git "$here/23/wt"
3580
'
3581
3582
test_expect_success '#23: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) in subdir' '
3583
cat >23/sub/sub/expected <<EOF &&
3584
setup: git_dir: ../../.git
3584
-setup: worktree: $TRASH_DIRECTORY/23/wt
3585
-setup: cwd: $TRASH_DIRECTORY/23/sub/sub
3585
+setup: worktree: $here/23/wt
3586
+setup: cwd: $here/23/sub/sub
3587
setup: prefix: (null)
3588
EOF
3589
test_repo 23/sub/sub ../../.git ../../wt
@@ -3590,39 +3591,39 @@ EOF
3591
3592
test_expect_success '#23: GIT_DIR, GIT_WORK_TREE=wt(rel) in subdir' '
3593
cat >23/sub/sub/expected <<EOF &&
3593
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3594
-setup: worktree: $TRASH_DIRECTORY/23/wt
3595
-setup: cwd: $TRASH_DIRECTORY/23/sub/sub
3594
+setup: git_dir: $here/23/.git
3595
+setup: worktree: $here/23/wt
3596
+setup: cwd: $here/23/sub/sub
3597
setup: prefix: (null)
3598
EOF
3598
- test_repo 23/sub/sub "$TRASH_DIRECTORY/23/.git" ../../wt
3599
+ test_repo 23/sub/sub "$here/23/.git" ../../wt
3600
'
3601
3602
test_expect_success '#23: GIT_DIR, GIT_WORK_TREE=wt in subdir' '
3603
cat >23/sub/sub/expected <<EOF &&
3603
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3604
-setup: worktree: $TRASH_DIRECTORY/23/wt
3605
-setup: cwd: $TRASH_DIRECTORY/23/sub/sub
3604
+setup: git_dir: $here/23/.git
3605
+setup: worktree: $here/23/wt
3606
+setup: cwd: $here/23/sub/sub
3607
setup: prefix: (null)
3608
EOF
3608
- test_repo 23/sub/sub "$TRASH_DIRECTORY/23/.git" "$TRASH_DIRECTORY/23/wt"
3609
+ test_repo 23/sub/sub "$here/23/.git" "$here/23/wt"
3610
'
3611
3612
test_expect_success '#23: GIT_DIR(rel), GIT_WORK_TREE=.. at root' '
3613
cat >23/expected <<EOF &&
3613
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3614
-setup: worktree: $TRASH_DIRECTORY
3615
-setup: cwd: $TRASH_DIRECTORY
3614
+setup: git_dir: $here/23/.git
3615
+setup: worktree: $here
3616
+setup: cwd: $here
3617
setup: prefix: 23/
3618
EOF
3618
- test_repo 23 .git "$TRASH_DIRECTORY"
3619
+ test_repo 23 .git "$here"
3620
'
3621
3622
test_expect_success '#23: GIT_DIR(rel), GIT_WORK_TREE=..(rel) at root' '
3623
cat >23/expected <<EOF &&
3623
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3624
-setup: worktree: $TRASH_DIRECTORY
3625
-setup: cwd: $TRASH_DIRECTORY
3624
+setup: git_dir: $here/23/.git
3625
+setup: worktree: $here
3626
+setup: cwd: $here
3627
setup: prefix: 23/
3628
EOF
3629
test_repo 23 .git ..
@@ -3630,39 +3631,39 @@ EOF
3631
3632
test_expect_success '#23: GIT_DIR, GIT_WORK_TREE=..(rel) at root' '
3633
cat >23/expected <<EOF &&
3633
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3634
-setup: worktree: $TRASH_DIRECTORY
3635
-setup: cwd: $TRASH_DIRECTORY
3634
+setup: git_dir: $here/23/.git
3635
+setup: worktree: $here
3636
+setup: cwd: $here
3637
setup: prefix: 23/
3638
EOF
3638
- test_repo 23 "$TRASH_DIRECTORY/23/.git" ..
3639
+ test_repo 23 "$here/23/.git" ..
3640
'
3641
3642
test_expect_success '#23: GIT_DIR, GIT_WORK_TREE=.. at root' '
3643
cat >23/expected <<EOF &&
3643
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3644
-setup: worktree: $TRASH_DIRECTORY
3645
-setup: cwd: $TRASH_DIRECTORY
3644
+setup: git_dir: $here/23/.git
3645
+setup: worktree: $here
3646
+setup: cwd: $here
3647
setup: prefix: 23/
3648
EOF
3648
- test_repo 23 "$TRASH_DIRECTORY/23/.git" "$TRASH_DIRECTORY"
3649
+ test_repo 23 "$here/23/.git" "$here"
3650
'
3651
3652
test_expect_success '#23: GIT_DIR(rel), GIT_WORK_TREE=.. in subdir' '
3653
cat >23/sub/sub/expected <<EOF &&
3653
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3654
-setup: worktree: $TRASH_DIRECTORY
3655
-setup: cwd: $TRASH_DIRECTORY
3654
+setup: git_dir: $here/23/.git
3655
+setup: worktree: $here
3656
+setup: cwd: $here
3657
setup: prefix: 23/sub/sub/
3658
EOF
3658
- test_repo 23/sub/sub ../../.git "$TRASH_DIRECTORY"
3659
+ test_repo 23/sub/sub ../../.git "$here"
3660
'
3661
3662
test_expect_success '#23: GIT_DIR(rel), GIT_WORK_TREE=..(rel) in subdir' '
3663
cat >23/sub/sub/expected <<EOF &&
3663
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3664
-setup: worktree: $TRASH_DIRECTORY
3665
-setup: cwd: $TRASH_DIRECTORY
3664
+setup: git_dir: $here/23/.git
3665
+setup: worktree: $here
3666
+setup: cwd: $here
3667
setup: prefix: 23/sub/sub/
3668
EOF
3669
test_repo 23/sub/sub ../../.git ../../..
@@ -3670,22 +3671,22 @@ EOF
3671
3672
test_expect_success '#23: GIT_DIR, GIT_WORK_TREE=..(rel) in subdir' '
3673
cat >23/sub/sub/expected <<EOF &&
3673
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3674
-setup: worktree: $TRASH_DIRECTORY
3675
-setup: cwd: $TRASH_DIRECTORY
3674
+setup: git_dir: $here/23/.git
3675
+setup: worktree: $here
3676
+setup: cwd: $here
3677
setup: prefix: 23/sub/sub/
3678
EOF
3678
- test_repo 23/sub/sub "$TRASH_DIRECTORY/23/.git" ../../../
3679
+ test_repo 23/sub/sub "$here/23/.git" ../../../
3680
'
3681
3682
test_expect_success '#23: GIT_DIR, GIT_WORK_TREE=.. in subdir' '
3683
cat >23/sub/sub/expected <<EOF &&
3683
-setup: git_dir: $TRASH_DIRECTORY/23/.git
3684
-setup: worktree: $TRASH_DIRECTORY
3685
-setup: cwd: $TRASH_DIRECTORY
3684
+setup: git_dir: $here/23/.git
3685
+setup: worktree: $here
3686
+setup: cwd: $here
3687
setup: prefix: 23/sub/sub/
3688
EOF
3688
- test_repo 23/sub/sub "$TRASH_DIRECTORY/23/.git" "$TRASH_DIRECTORY"
3689
+ test_repo 23/sub/sub "$here/23/.git" "$here"
3690
'
3691
3692
#
@@ -3718,9 +3719,9 @@ test_expect_success '#24: setup' '
3719
3720
test_expect_success '#24: at root' '
3721
cat >24/expected <<EOF &&
3721
-setup: git_dir: $TRASH_DIRECTORY/24.git
3722
+setup: git_dir: $here/24.git
3723
setup: worktree: (null)
3723
-setup: cwd: $TRASH_DIRECTORY/24
3724
+setup: cwd: $here/24
3725
setup: prefix: (null)
3726
EOF
3727
test_repo 24
@@ -3728,9 +3729,9 @@ EOF
3729
3730
test_expect_success '#24: in subdir' '
3731
cat >24/sub/expected <<EOF &&
3731
-setup: git_dir: $TRASH_DIRECTORY/24.git
3732
+setup: git_dir: $here/24.git
3733
setup: worktree: (null)
3733
-setup: cwd: $TRASH_DIRECTORY/24/sub
3734
+setup: cwd: $here/24/sub
3735
setup: prefix: (null)
3736
EOF
3737
test_repo 24/sub
@@ -3768,9 +3769,9 @@ test_expect_success '#25: setup' '
3769
3770
test_expect_success '#25: at root' '
3771
cat >25/expected <<EOF &&
3771
-setup: git_dir: $TRASH_DIRECTORY/25.git
3772
+setup: git_dir: $here/25.git
3773
setup: worktree: (null)
3773
-setup: cwd: $TRASH_DIRECTORY/25
3774
+setup: cwd: $here/25
3775
setup: prefix: (null)
3776
EOF
3777
test_repo 25
@@ -3778,9 +3779,9 @@ EOF
3779
3780
test_expect_success '#25: in subdir' '
3781
cat >25/sub/expected <<EOF &&
3781
-setup: git_dir: $TRASH_DIRECTORY/25.git
3782
+setup: git_dir: $here/25.git
3783
setup: worktree: (null)
3783
-setup: cwd: $TRASH_DIRECTORY/25/sub
3784
+setup: cwd: $here/25/sub
3785
setup: prefix: (null)
3786
EOF
3787
test_repo 25/sub
@@ -3816,9 +3817,9 @@ test_expect_success '#26: setup' '
3817
3818
test_expect_success '#26: (rel) at root' '
3819
cat >26/expected <<EOF &&
3819
-setup: git_dir: $TRASH_DIRECTORY/26.git
3820
+setup: git_dir: $here/26.git
3821
setup: worktree: (null)
3821
-setup: cwd: $TRASH_DIRECTORY/26
3822
+setup: cwd: $here/26
3823
setup: prefix: (null)
3824
EOF
3825
test_repo 26 .git
@@ -3826,19 +3827,19 @@ EOF
3827
3828
test_expect_success '#26: at root' '
3829
cat >26/expected <<EOF &&
3829
-setup: git_dir: $TRASH_DIRECTORY/26.git
3830
+setup: git_dir: $here/26.git
3831
setup: worktree: (null)
3831
-setup: cwd: $TRASH_DIRECTORY/26
3832
+setup: cwd: $here/26
3833
setup: prefix: (null)
3834
EOF
3834
- test_repo 26 "$TRASH_DIRECTORY/26/.git"
3835
+ test_repo 26 "$here/26/.git"
3836
'
3837
3838
test_expect_success '#26: (rel) in subdir' '
3839
cat >26/sub/expected <<EOF &&
3839
-setup: git_dir: $TRASH_DIRECTORY/26.git
3840
+setup: git_dir: $here/26.git
3841
setup: worktree: (null)
3841
-setup: cwd: $TRASH_DIRECTORY/26/sub
3842
+setup: cwd: $here/26/sub
3843
setup: prefix: (null)
3844
EOF
3845
test_repo 26/sub ../.git
@@ -3846,12 +3847,12 @@ EOF
3847
3848
test_expect_success '#26: in subdir' '
3849
cat >26/sub/expected <<EOF &&
3849
-setup: git_dir: $TRASH_DIRECTORY/26.git
3850
+setup: git_dir: $here/26.git
3851
setup: worktree: (null)
3851
-setup: cwd: $TRASH_DIRECTORY/26/sub
3852
+setup: cwd: $here/26/sub
3853
setup: prefix: (null)
3854
EOF
3854
- test_repo 26/sub "$TRASH_DIRECTORY/26/.git"
3855
+ test_repo 26/sub "$here/26/.git"
3856
'
3857
3858
#
@@ -3884,19 +3885,19 @@ test_expect_success '#27: setup' '
3885
3886
test_expect_success '#27: GIT_DIR(rel), GIT_WORK_TREE=root at root' '
3887
cat >27/expected <<EOF &&
3887
-setup: git_dir: $TRASH_DIRECTORY/27.git
3888
-setup: worktree: $TRASH_DIRECTORY/27
3889
-setup: cwd: $TRASH_DIRECTORY/27
3888
+setup: git_dir: $here/27.git
3889
+setup: worktree: $here/27
3890
+setup: cwd: $here/27
3891
setup: prefix: (null)
3892
EOF
3892
- test_repo 27 .git "$TRASH_DIRECTORY/27"
3893
+ test_repo 27 .git "$here/27"
3894
'
3895
3896
test_expect_success '#27: GIT_DIR(rel), GIT_WORK_TREE=root(rel) at root' '
3897
cat >27/expected <<EOF &&
3897
-setup: git_dir: $TRASH_DIRECTORY/27.git
3898
-setup: worktree: $TRASH_DIRECTORY/27
3899
-setup: cwd: $TRASH_DIRECTORY/27
3898
+setup: git_dir: $here/27.git
3899
+setup: worktree: $here/27
3900
+setup: cwd: $here/27
3901
setup: prefix: (null)
3902
EOF
3903
test_repo 27 .git .
@@ -3904,39 +3905,39 @@ EOF
3905
3906
test_expect_success '#27: GIT_DIR, GIT_WORK_TREE=root at root' '
3907
cat >27/expected <<EOF &&
3907
-setup: git_dir: $TRASH_DIRECTORY/27.git
3908
-setup: worktree: $TRASH_DIRECTORY/27
3909
-setup: cwd: $TRASH_DIRECTORY/27
3908
+setup: git_dir: $here/27.git
3909
+setup: worktree: $here/27
3910
+setup: cwd: $here/27
3911
setup: prefix: (null)
3912
EOF
3912
- test_repo 27 "$TRASH_DIRECTORY/27/.git" "$TRASH_DIRECTORY/27"
3913
+ test_repo 27 "$here/27/.git" "$here/27"
3914
'
3915
3916
test_expect_success '#27: GIT_DIR, GIT_WORK_TREE=root(rel) at root' '
3917
cat >27/expected <<EOF &&
3917
-setup: git_dir: $TRASH_DIRECTORY/27.git
3918
-setup: worktree: $TRASH_DIRECTORY/27
3919
-setup: cwd: $TRASH_DIRECTORY/27
3918
+setup: git_dir: $here/27.git
3919
+setup: worktree: $here/27
3920
+setup: cwd: $here/27
3921
setup: prefix: (null)
3922
EOF
3922
- test_repo 27 "$TRASH_DIRECTORY/27/.git" .
3923
+ test_repo 27 "$here/27/.git" .
3924
'
3925
3926
test_expect_success '#27: GIT_DIR(rel), GIT_WORKTREE=root in subdir' '
3927
cat >27/sub/sub/expected <<EOF &&
3927
-setup: git_dir: $TRASH_DIRECTORY/27.git
3928
-setup: worktree: $TRASH_DIRECTORY/27
3929
-setup: cwd: $TRASH_DIRECTORY/27
3928
+setup: git_dir: $here/27.git
3929
+setup: worktree: $here/27
3930
+setup: cwd: $here/27
3931
setup: prefix: sub/sub/
3932
EOF
3932
- test_repo 27/sub/sub ../../.git "$TRASH_DIRECTORY/27"
3933
+ test_repo 27/sub/sub ../../.git "$here/27"
3934
'
3935
3936
test_expect_success '#27: GIT_DIR(rel), GIT_WORKTREE=root(rel) in subdir' '
3937
cat >27/sub/sub/expected <<EOF &&
3937
-setup: git_dir: $TRASH_DIRECTORY/27.git
3938
-setup: worktree: $TRASH_DIRECTORY/27
3939
-setup: cwd: $TRASH_DIRECTORY/27
3938
+setup: git_dir: $here/27.git
3939
+setup: worktree: $here/27
3940
+setup: cwd: $here/27
3941
setup: prefix: sub/sub/
3942
EOF
3943
test_repo 27/sub/sub ../../.git ../..
@@ -3944,39 +3945,39 @@ EOF
3945
3946
test_expect_success '#27: GIT_DIR, GIT_WORKTREE=root in subdir' '
3947
cat >27/sub/expected <<EOF &&
3947
-setup: git_dir: $TRASH_DIRECTORY/27.git
3948
-setup: worktree: $TRASH_DIRECTORY/27
3949
-setup: cwd: $TRASH_DIRECTORY/27
3948
+setup: git_dir: $here/27.git
3949
+setup: worktree: $here/27
3950
+setup: cwd: $here/27
3951
setup: prefix: sub/
3952
EOF
3952
- test_repo 27/sub "$TRASH_DIRECTORY/27/.git" "$TRASH_DIRECTORY/27"
3953
+ test_repo 27/sub "$here/27/.git" "$here/27"
3954
'
3955
3956
test_expect_success '#27: GIT_DIR, GIT_WORKTREE=root(rel) in subdir' '
3957
cat >27/sub/sub/expected <<EOF &&
3957
-setup: git_dir: $TRASH_DIRECTORY/27.git
3958
-setup: worktree: $TRASH_DIRECTORY/27
3959
-setup: cwd: $TRASH_DIRECTORY/27
3958
+setup: git_dir: $here/27.git
3959
+setup: worktree: $here/27
3960
+setup: cwd: $here/27
3961
setup: prefix: sub/sub/
3962
EOF
3962
- test_repo 27/sub/sub "$TRASH_DIRECTORY/27/.git" ../..
3963
+ test_repo 27/sub/sub "$here/27/.git" ../..
3964
'
3965
3966
test_expect_success '#27: GIT_DIR(rel), GIT_WORK_TREE=wt at root' '
3967
cat >27/expected <<EOF &&
3967
-setup: git_dir: $TRASH_DIRECTORY/27.git
3968
-setup: worktree: $TRASH_DIRECTORY/27/wt
3969
-setup: cwd: $TRASH_DIRECTORY/27
3968
+setup: git_dir: $here/27.git
3969
+setup: worktree: $here/27/wt
3970
+setup: cwd: $here/27
3971
setup: prefix: (null)
3972
EOF
3972
- test_repo 27 .git "$TRASH_DIRECTORY/27/wt"
3973
+ test_repo 27 .git "$here/27/wt"
3974
'
3975
3976
test_expect_success '#27: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) at root' '
3977
cat >27/expected <<EOF &&
3977
-setup: git_dir: $TRASH_DIRECTORY/27.git
3978
-setup: worktree: $TRASH_DIRECTORY/27/wt
3979
-setup: cwd: $TRASH_DIRECTORY/27
3978
+setup: git_dir: $here/27.git
3979
+setup: worktree: $here/27/wt
3980
+setup: cwd: $here/27
3981
setup: prefix: (null)
3982
EOF
3983
test_repo 27 .git wt
@@ -3984,39 +3985,39 @@ EOF
3985
3986
test_expect_success '#27: GIT_DIR, GIT_WORK_TREE=wt(rel) at root' '
3987
cat >27/expected <<EOF &&
3987
-setup: git_dir: $TRASH_DIRECTORY/27.git
3988
-setup: worktree: $TRASH_DIRECTORY/27/wt
3989
-setup: cwd: $TRASH_DIRECTORY/27
3988
+setup: git_dir: $here/27.git
3989
+setup: worktree: $here/27/wt
3990
+setup: cwd: $here/27
3991
setup: prefix: (null)
3992
EOF
3992
- test_repo 27 "$TRASH_DIRECTORY/27/.git" wt
3993
+ test_repo 27 "$here/27/.git" wt
3994
'
3995
3996
test_expect_success '#27: GIT_DIR, GIT_WORK_TREE=wt at root' '
3997
cat >27/expected <<EOF &&
3997
-setup: git_dir: $TRASH_DIRECTORY/27.git
3998
-setup: worktree: $TRASH_DIRECTORY/27/wt
3999
-setup: cwd: $TRASH_DIRECTORY/27
3998
+setup: git_dir: $here/27.git
3999
+setup: worktree: $here/27/wt
4000
+setup: cwd: $here/27
4001
setup: prefix: (null)
4002
EOF
4002
- test_repo 27 "$TRASH_DIRECTORY/27/.git" "$TRASH_DIRECTORY/27/wt"
4003
+ test_repo 27 "$here/27/.git" "$here/27/wt"
4004
'
4005
4006
test_expect_success '#27: GIT_DIR(rel), GIT_WORK_TREE=wt in subdir' '
4007
cat >27/sub/sub/expected <<EOF &&
4007
-setup: git_dir: $TRASH_DIRECTORY/27.git
4008
-setup: worktree: $TRASH_DIRECTORY/27/wt
4009
-setup: cwd: $TRASH_DIRECTORY/27/sub/sub
4008
+setup: git_dir: $here/27.git
4009
+setup: worktree: $here/27/wt
4010
+setup: cwd: $here/27/sub/sub
4011
setup: prefix: (null)
4012
EOF
4012
- test_repo 27/sub/sub ../../.git "$TRASH_DIRECTORY/27/wt"
4013
+ test_repo 27/sub/sub ../../.git "$here/27/wt"
4014
'
4015
4016
test_expect_success '#27: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) in subdir' '
4017
cat >27/sub/sub/expected <<EOF &&
4017
-setup: git_dir: $TRASH_DIRECTORY/27.git
4018
-setup: worktree: $TRASH_DIRECTORY/27/wt
4019
-setup: cwd: $TRASH_DIRECTORY/27/sub/sub
4018
+setup: git_dir: $here/27.git
4019
+setup: worktree: $here/27/wt
4020
+setup: cwd: $here/27/sub/sub
4021
setup: prefix: (null)
4022
EOF
4023
test_repo 27/sub/sub ../../.git ../../wt
@@ -4024,39 +4025,39 @@ EOF
4025
4026
test_expect_success '#27: GIT_DIR, GIT_WORK_TREE=wt(rel) in subdir' '
4027
cat >27/sub/sub/expected <<EOF &&
4027
-setup: git_dir: $TRASH_DIRECTORY/27.git
4028
-setup: worktree: $TRASH_DIRECTORY/27/wt
4029
-setup: cwd: $TRASH_DIRECTORY/27/sub/sub
4028
+setup: git_dir: $here/27.git
4029
+setup: worktree: $here/27/wt
4030
+setup: cwd: $here/27/sub/sub
4031
setup: prefix: (null)
4032
EOF
4032
- test_repo 27/sub/sub "$TRASH_DIRECTORY/27/.git" ../../wt
4033
+ test_repo 27/sub/sub "$here/27/.git" ../../wt
4034
'
4035
4036
test_expect_success '#27: GIT_DIR, GIT_WORK_TREE=wt in subdir' '
4037
cat >27/sub/sub/expected <<EOF &&
4037
-setup: git_dir: $TRASH_DIRECTORY/27.git
4038
-setup: worktree: $TRASH_DIRECTORY/27/wt
4039
-setup: cwd: $TRASH_DIRECTORY/27/sub/sub
4038
+setup: git_dir: $here/27.git
4039
+setup: worktree: $here/27/wt
4040
+setup: cwd: $here/27/sub/sub
4041
setup: prefix: (null)
4042
EOF
4042
- test_repo 27/sub/sub "$TRASH_DIRECTORY/27/.git" "$TRASH_DIRECTORY/27/wt"
4043
+ test_repo 27/sub/sub "$here/27/.git" "$here/27/wt"
4044
'
4045
4046
test_expect_success '#27: GIT_DIR(rel), GIT_WORK_TREE=.. at root' '
4047
cat >27/expected <<EOF &&
4047
-setup: git_dir: $TRASH_DIRECTORY/27.git
4048
-setup: worktree: $TRASH_DIRECTORY
4049
-setup: cwd: $TRASH_DIRECTORY
4048
+setup: git_dir: $here/27.git
4049
+setup: worktree: $here
4050
+setup: cwd: $here
4051
setup: prefix: 27/
4052
EOF
4052
- test_repo 27 .git "$TRASH_DIRECTORY"
4053
+ test_repo 27 .git "$here"
4054
'
4055
4056
test_expect_success '#27: GIT_DIR(rel), GIT_WORK_TREE=..(rel) at root' '
4057
cat >27/expected <<EOF &&
4057
-setup: git_dir: $TRASH_DIRECTORY/27.git
4058
-setup: worktree: $TRASH_DIRECTORY
4059
-setup: cwd: $TRASH_DIRECTORY
4058
+setup: git_dir: $here/27.git
4059
+setup: worktree: $here
4060
+setup: cwd: $here
4061
setup: prefix: 27/
4062
EOF
4063
test_repo 27 .git ..
@@ -4064,39 +4065,39 @@ EOF
4065
4066
test_expect_success '#27: GIT_DIR, GIT_WORK_TREE=..(rel) at root' '
4067
cat >27/expected <<EOF &&
4067
-setup: git_dir: $TRASH_DIRECTORY/27.git
4068
-setup: worktree: $TRASH_DIRECTORY
4069
-setup: cwd: $TRASH_DIRECTORY
4068
+setup: git_dir: $here/27.git
4069
+setup: worktree: $here
4070
+setup: cwd: $here
4071
setup: prefix: 27/
4072
EOF
4072
- test_repo 27 "$TRASH_DIRECTORY/27/.git" ..
4073
+ test_repo 27 "$here/27/.git" ..
4074
'
4075
4076
test_expect_success '#27: GIT_DIR, GIT_WORK_TREE=.. at root' '
4077
cat >27/expected <<EOF &&
4077
-setup: git_dir: $TRASH_DIRECTORY/27.git
4078
-setup: worktree: $TRASH_DIRECTORY
4079
-setup: cwd: $TRASH_DIRECTORY
4078
+setup: git_dir: $here/27.git
4079
+setup: worktree: $here
4080
+setup: cwd: $here
4081
setup: prefix: 27/
4082
EOF
4082
- test_repo 27 "$TRASH_DIRECTORY/27/.git" "$TRASH_DIRECTORY"
4083
+ test_repo 27 "$here/27/.git" "$here"
4084
'
4085
4086
test_expect_success '#27: GIT_DIR(rel), GIT_WORK_TREE=.. in subdir' '
4087
cat >27/sub/sub/expected <<EOF &&
4087
-setup: git_dir: $TRASH_DIRECTORY/27.git
4088
-setup: worktree: $TRASH_DIRECTORY
4089
-setup: cwd: $TRASH_DIRECTORY
4088
+setup: git_dir: $here/27.git
4089
+setup: worktree: $here
4090
+setup: cwd: $here
4091
setup: prefix: 27/sub/sub/
4092
EOF
4092
- test_repo 27/sub/sub ../../.git "$TRASH_DIRECTORY"
4093
+ test_repo 27/sub/sub ../../.git "$here"
4094
'
4095
4096
test_expect_success '#27: GIT_DIR(rel), GIT_WORK_TREE=..(rel) in subdir' '
4097
cat >27/sub/sub/expected <<EOF &&
4097
-setup: git_dir: $TRASH_DIRECTORY/27.git
4098
-setup: worktree: $TRASH_DIRECTORY
4099
-setup: cwd: $TRASH_DIRECTORY
4098
+setup: git_dir: $here/27.git
4099
+setup: worktree: $here
4100
+setup: cwd: $here
4101
setup: prefix: 27/sub/sub/
4102
EOF
4103
test_repo 27/sub/sub ../../.git ../../..
@@ -4104,22 +4105,22 @@ EOF
4105
4106
test_expect_success '#27: GIT_DIR, GIT_WORK_TREE=..(rel) in subdir' '
4107
cat >27/sub/sub/expected <<EOF &&
4107
-setup: git_dir: $TRASH_DIRECTORY/27.git
4108
-setup: worktree: $TRASH_DIRECTORY
4109
-setup: cwd: $TRASH_DIRECTORY
4108
+setup: git_dir: $here/27.git
4109
+setup: worktree: $here
4110
+setup: cwd: $here
4111
setup: prefix: 27/sub/sub/
4112
EOF
4112
- test_repo 27/sub/sub "$TRASH_DIRECTORY/27/.git" ../../../
4113
+ test_repo 27/sub/sub "$here/27/.git" ../../../
4114
'
4115
4116
test_expect_success '#27: GIT_DIR, GIT_WORK_TREE=.. in subdir' '
4117
cat >27/sub/sub/expected <<EOF &&
4117
-setup: git_dir: $TRASH_DIRECTORY/27.git
4118
-setup: worktree: $TRASH_DIRECTORY
4119
-setup: cwd: $TRASH_DIRECTORY
4118
+setup: git_dir: $here/27.git
4119
+setup: worktree: $here
4120
+setup: cwd: $here
4121
setup: prefix: 27/sub/sub/
4122
EOF
4122
- test_repo 27/sub/sub "$TRASH_DIRECTORY/27/.git" "$TRASH_DIRECTORY"
4123
+ test_repo 27/sub/sub "$here/27/.git" "$here"
4124
'
4125
4126
#
@@ -4153,9 +4154,9 @@ test_expect_success '#28: setup' '
4154
4155
test_expect_success '#28: at root' '
4156
cat >28/expected <<EOF &&
4156
-setup: git_dir: $TRASH_DIRECTORY/28.git
4157
+setup: git_dir: $here/28.git
4158
setup: worktree: (null)
4158
-setup: cwd: $TRASH_DIRECTORY/28
4159
+setup: cwd: $here/28
4160
setup: prefix: (null)
4161
EOF
4162
test_repo 28
@@ -4163,9 +4164,9 @@ EOF
4164
4165
test_expect_success '#28: in subdir' '
4166
cat >28/sub/expected <<EOF &&
4166
-setup: git_dir: $TRASH_DIRECTORY/28.git
4167
+setup: git_dir: $here/28.git
4168
setup: worktree: (null)
4168
-setup: cwd: $TRASH_DIRECTORY/28/sub
4169
+setup: cwd: $here/28/sub
4170
setup: prefix: (null)
4171
EOF
4172
test_repo 28/sub
@@ -4203,9 +4204,9 @@ test_expect_success '#29: setup' '
4204
4205
test_expect_success '#29: at root' '
4206
cat >29/expected <<EOF &&
4206
-setup: git_dir: $TRASH_DIRECTORY/29.git
4207
+setup: git_dir: $here/29.git
4208
setup: worktree: (null)
4208
-setup: cwd: $TRASH_DIRECTORY/29
4209
+setup: cwd: $here/29
4210
setup: prefix: (null)
4211
EOF
4212
test_repo 29
@@ -4213,9 +4214,9 @@ EOF
4214
4215
test_expect_success '#29: in subdir' '
4216
cat >29/sub/expected <<EOF &&
4216
-setup: git_dir: $TRASH_DIRECTORY/29.git
4217
+setup: git_dir: $here/29.git
4218
setup: worktree: (null)
4218
-setup: cwd: $TRASH_DIRECTORY/29/sub
4219
+setup: cwd: $here/29/sub
4220
setup: prefix: (null)
4221
EOF
4222
test_repo 29/sub
@@ -4291,19 +4292,19 @@ test_expect_success '#31: setup' '
4292
4293
test_expect_success '#31: GIT_DIR(rel), GIT_WORK_TREE=root at root' '
4294
cat >31/expected <<EOF &&
4294
-setup: git_dir: $TRASH_DIRECTORY/31.git
4295
-setup: worktree: $TRASH_DIRECTORY/31
4296
-setup: cwd: $TRASH_DIRECTORY/31
4295
+setup: git_dir: $here/31.git
4296
+setup: worktree: $here/31
4297
+setup: cwd: $here/31
4298
setup: prefix: (null)
4299
EOF
4299
- test_repo 31 .git "$TRASH_DIRECTORY/31"
4300
+ test_repo 31 .git "$here/31"
4301
'
4302
4303
test_expect_success '#31: GIT_DIR(rel), GIT_WORK_TREE=root(rel) at root' '
4304
cat >31/expected <<EOF &&
4304
-setup: git_dir: $TRASH_DIRECTORY/31.git
4305
-setup: worktree: $TRASH_DIRECTORY/31
4306
-setup: cwd: $TRASH_DIRECTORY/31
4305
+setup: git_dir: $here/31.git
4306
+setup: worktree: $here/31
4307
+setup: cwd: $here/31
4308
setup: prefix: (null)
4309
EOF
4310
test_repo 31 .git .
@@ -4311,39 +4312,39 @@ EOF
4312
4313
test_expect_success '#31: GIT_DIR, GIT_WORK_TREE=root at root' '
4314
cat >31/expected <<EOF &&
4314
-setup: git_dir: $TRASH_DIRECTORY/31.git
4315
-setup: worktree: $TRASH_DIRECTORY/31
4316
-setup: cwd: $TRASH_DIRECTORY/31
4315
+setup: git_dir: $here/31.git
4316
+setup: worktree: $here/31
4317
+setup: cwd: $here/31
4318
setup: prefix: (null)
4319
EOF
4319
- test_repo 31 "$TRASH_DIRECTORY/31/.git" "$TRASH_DIRECTORY/31"
4320
+ test_repo 31 "$here/31/.git" "$here/31"
4321
'
4322
4323
test_expect_success '#31: GIT_DIR, GIT_WORK_TREE=root(rel) at root' '
4324
cat >31/expected <<EOF &&
4324
-setup: git_dir: $TRASH_DIRECTORY/31.git
4325
-setup: worktree: $TRASH_DIRECTORY/31
4326
-setup: cwd: $TRASH_DIRECTORY/31
4325
+setup: git_dir: $here/31.git
4326
+setup: worktree: $here/31
4327
+setup: cwd: $here/31
4328
setup: prefix: (null)
4329
EOF
4329
- test_repo 31 "$TRASH_DIRECTORY/31/.git" .
4330
+ test_repo 31 "$here/31/.git" .
4331
'
4332
4333
test_expect_success '#31: GIT_DIR(rel), GIT_WORKTREE=root in subdir' '
4334
cat >31/sub/sub/expected <<EOF &&
4334
-setup: git_dir: $TRASH_DIRECTORY/31.git
4335
-setup: worktree: $TRASH_DIRECTORY/31
4336
-setup: cwd: $TRASH_DIRECTORY/31
4335
+setup: git_dir: $here/31.git
4336
+setup: worktree: $here/31
4337
+setup: cwd: $here/31
4338
setup: prefix: sub/sub/
4339
EOF
4339
- test_repo 31/sub/sub ../../.git "$TRASH_DIRECTORY/31"
4340
+ test_repo 31/sub/sub ../../.git "$here/31"
4341
'
4342
4343
test_expect_success '#31: GIT_DIR(rel), GIT_WORKTREE=root(rel) in subdir' '
4344
cat >31/sub/sub/expected <<EOF &&
4344
-setup: git_dir: $TRASH_DIRECTORY/31.git
4345
-setup: worktree: $TRASH_DIRECTORY/31
4346
-setup: cwd: $TRASH_DIRECTORY/31
4345
+setup: git_dir: $here/31.git
4346
+setup: worktree: $here/31
4347
+setup: cwd: $here/31
4348
setup: prefix: sub/sub/
4349
EOF
4350
test_repo 31/sub/sub ../../.git ../..
@@ -4351,39 +4352,39 @@ EOF
4352
4353
test_expect_success '#31: GIT_DIR, GIT_WORKTREE=root in subdir' '
4354
cat >31/sub/expected <<EOF &&
4354
-setup: git_dir: $TRASH_DIRECTORY/31.git
4355
-setup: worktree: $TRASH_DIRECTORY/31
4356
-setup: cwd: $TRASH_DIRECTORY/31
4355
+setup: git_dir: $here/31.git
4356
+setup: worktree: $here/31
4357
+setup: cwd: $here/31
4358
setup: prefix: sub/
4359
EOF
4359
- test_repo 31/sub "$TRASH_DIRECTORY/31/.git" "$TRASH_DIRECTORY/31"
4360
+ test_repo 31/sub "$here/31/.git" "$here/31"
4361
'
4362
4363
test_expect_success '#31: GIT_DIR, GIT_WORKTREE=root(rel) in subdir' '
4364
cat >31/sub/sub/expected <<EOF &&
4364
-setup: git_dir: $TRASH_DIRECTORY/31.git
4365
-setup: worktree: $TRASH_DIRECTORY/31
4366
-setup: cwd: $TRASH_DIRECTORY/31
4365
+setup: git_dir: $here/31.git
4366
+setup: worktree: $here/31
4367
+setup: cwd: $here/31
4368
setup: prefix: sub/sub/
4369
EOF
4369
- test_repo 31/sub/sub "$TRASH_DIRECTORY/31/.git" ../..
4370
+ test_repo 31/sub/sub "$here/31/.git" ../..
4371
'
4372
4373
test_expect_success '#31: GIT_DIR(rel), GIT_WORK_TREE=wt at root' '
4374
cat >31/expected <<EOF &&
4374
-setup: git_dir: $TRASH_DIRECTORY/31.git
4375
-setup: worktree: $TRASH_DIRECTORY/31/wt
4376
-setup: cwd: $TRASH_DIRECTORY/31
4375
+setup: git_dir: $here/31.git
4376
+setup: worktree: $here/31/wt
4377
+setup: cwd: $here/31
4378
setup: prefix: (null)
4379
EOF
4379
- test_repo 31 .git "$TRASH_DIRECTORY/31/wt"
4380
+ test_repo 31 .git "$here/31/wt"
4381
'
4382
4383
test_expect_success '#31: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) at root' '
4384
cat >31/expected <<EOF &&
4384
-setup: git_dir: $TRASH_DIRECTORY/31.git
4385
-setup: worktree: $TRASH_DIRECTORY/31/wt
4386
-setup: cwd: $TRASH_DIRECTORY/31
4385
+setup: git_dir: $here/31.git
4386
+setup: worktree: $here/31/wt
4387
+setup: cwd: $here/31
4388
setup: prefix: (null)
4389
EOF
4390
test_repo 31 .git wt
@@ -4391,39 +4392,39 @@ EOF
4392
4393
test_expect_success '#31: GIT_DIR, GIT_WORK_TREE=wt(rel) at root' '
4394
cat >31/expected <<EOF &&
4394
-setup: git_dir: $TRASH_DIRECTORY/31.git
4395
-setup: worktree: $TRASH_DIRECTORY/31/wt
4396
-setup: cwd: $TRASH_DIRECTORY/31
4395
+setup: git_dir: $here/31.git
4396
+setup: worktree: $here/31/wt
4397
+setup: cwd: $here/31
4398
setup: prefix: (null)
4399
EOF
4399
- test_repo 31 "$TRASH_DIRECTORY/31/.git" wt
4400
+ test_repo 31 "$here/31/.git" wt
4401
'
4402
4403
test_expect_success '#31: GIT_DIR, GIT_WORK_TREE=wt at root' '
4404
cat >31/expected <<EOF &&
4404
-setup: git_dir: $TRASH_DIRECTORY/31.git
4405
-setup: worktree: $TRASH_DIRECTORY/31/wt
4406
-setup: cwd: $TRASH_DIRECTORY/31
4405
+setup: git_dir: $here/31.git
4406
+setup: worktree: $here/31/wt
4407
+setup: cwd: $here/31
4408
setup: prefix: (null)
4409
EOF
4409
- test_repo 31 "$TRASH_DIRECTORY/31/.git" "$TRASH_DIRECTORY/31/wt"
4410
+ test_repo 31 "$here/31/.git" "$here/31/wt"
4411
'
4412
4413
test_expect_success '#31: GIT_DIR(rel), GIT_WORK_TREE=wt in subdir' '
4414
cat >31/sub/sub/expected <<EOF &&
4414
-setup: git_dir: $TRASH_DIRECTORY/31.git
4415
-setup: worktree: $TRASH_DIRECTORY/31/wt
4416
-setup: cwd: $TRASH_DIRECTORY/31/sub/sub
4415
+setup: git_dir: $here/31.git
4416
+setup: worktree: $here/31/wt
4417
+setup: cwd: $here/31/sub/sub
4418
setup: prefix: (null)
4419
EOF
4419
- test_repo 31/sub/sub ../../.git "$TRASH_DIRECTORY/31/wt"
4420
+ test_repo 31/sub/sub ../../.git "$here/31/wt"
4421
'
4422
4423
test_expect_success '#31: GIT_DIR(rel), GIT_WORK_TREE=wt(rel) in subdir' '
4424
cat >31/sub/sub/expected <<EOF &&
4424
-setup: git_dir: $TRASH_DIRECTORY/31.git
4425
-setup: worktree: $TRASH_DIRECTORY/31/wt
4426
-setup: cwd: $TRASH_DIRECTORY/31/sub/sub
4425
+setup: git_dir: $here/31.git
4426
+setup: worktree: $here/31/wt
4427
+setup: cwd: $here/31/sub/sub
4428
setup: prefix: (null)
4429
EOF
4430
test_repo 31/sub/sub ../../.git ../../wt
@@ -4431,39 +4432,39 @@ EOF
4432
4433
test_expect_success '#31: GIT_DIR, GIT_WORK_TREE=wt(rel) in subdir' '
4434
cat >31/sub/sub/expected <<EOF &&
4434
-setup: git_dir: $TRASH_DIRECTORY/31.git
4435
-setup: worktree: $TRASH_DIRECTORY/31/wt
4436
-setup: cwd: $TRASH_DIRECTORY/31/sub/sub
4435
+setup: git_dir: $here/31.git
4436
+setup: worktree: $here/31/wt
4437
+setup: cwd: $here/31/sub/sub
4438
setup: prefix: (null)
4439
EOF
4439
- test_repo 31/sub/sub "$TRASH_DIRECTORY/31/.git" ../../wt
4440
+ test_repo 31/sub/sub "$here/31/.git" ../../wt
4441
'
4442
4443
test_expect_success '#31: GIT_DIR, GIT_WORK_TREE=wt in subdir' '
4444
cat >31/sub/sub/expected <<EOF &&
4444
-setup: git_dir: $TRASH_DIRECTORY/31.git
4445
-setup: worktree: $TRASH_DIRECTORY/31/wt
4446
-setup: cwd: $TRASH_DIRECTORY/31/sub/sub
4445
+setup: git_dir: $here/31.git
4446
+setup: worktree: $here/31/wt
4447
+setup: cwd: $here/31/sub/sub
4448
setup: prefix: (null)
4449
EOF
4449
- test_repo 31/sub/sub "$TRASH_DIRECTORY/31/.git" "$TRASH_DIRECTORY/31/wt"
4450
+ test_repo 31/sub/sub "$here/31/.git" "$here/31/wt"
4451
'
4452
4453
test_expect_success '#31: GIT_DIR(rel), GIT_WORK_TREE=.. at root' '
4454
cat >31/expected <<EOF &&
4454
-setup: git_dir: $TRASH_DIRECTORY/31.git
4455
-setup: worktree: $TRASH_DIRECTORY
4456
-setup: cwd: $TRASH_DIRECTORY
4455
+setup: git_dir: $here/31.git
4456
+setup: worktree: $here
4457
+setup: cwd: $here
4458
setup: prefix: 31/
4459
EOF
4459
- test_repo 31 .git "$TRASH_DIRECTORY"
4460
+ test_repo 31 .git "$here"
4461
'
4462
4463
test_expect_success '#31: GIT_DIR(rel), GIT_WORK_TREE=..(rel) at root' '
4464
cat >31/expected <<EOF &&
4464
-setup: git_dir: $TRASH_DIRECTORY/31.git
4465
-setup: worktree: $TRASH_DIRECTORY
4466
-setup: cwd: $TRASH_DIRECTORY
4465
+setup: git_dir: $here/31.git
4466
+setup: worktree: $here
4467
+setup: cwd: $here
4468
setup: prefix: 31/
4469
EOF
4470
test_repo 31 .git ..
@@ -4471,39 +4472,39 @@ EOF
4472
4473
test_expect_success '#31: GIT_DIR, GIT_WORK_TREE=..(rel) at root' '
4474
cat >31/expected <<EOF &&
4474
-setup: git_dir: $TRASH_DIRECTORY/31.git
4475
-setup: worktree: $TRASH_DIRECTORY
4476
-setup: cwd: $TRASH_DIRECTORY
4475
+setup: git_dir: $here/31.git
4476
+setup: worktree: $here
4477
+setup: cwd: $here
4478
setup: prefix: 31/
4479
EOF
4479
- test_repo 31 "$TRASH_DIRECTORY/31/.git" ..
4480
+ test_repo 31 "$here/31/.git" ..
4481
'
4482
4483
test_expect_success '#31: GIT_DIR, GIT_WORK_TREE=.. at root' '
4484
cat >31/expected <<EOF &&
4484
-setup: git_dir: $TRASH_DIRECTORY/31.git
4485
-setup: worktree: $TRASH_DIRECTORY
4486
-setup: cwd: $TRASH_DIRECTORY
4485
+setup: git_dir: $here/31.git
4486
+setup: worktree: $here
4487
+setup: cwd: $here
4488
setup: prefix: 31/
4489
EOF
4489
- test_repo 31 "$TRASH_DIRECTORY/31/.git" "$TRASH_DIRECTORY"
4490
+ test_repo 31 "$here/31/.git" "$here"
4491
'
4492
4493
test_expect_success '#31: GIT_DIR(rel), GIT_WORK_TREE=.. in subdir' '
4494
cat >31/sub/sub/expected <<EOF &&
4494
-setup: git_dir: $TRASH_DIRECTORY/31.git
4495
-setup: worktree: $TRASH_DIRECTORY
4496
-setup: cwd: $TRASH_DIRECTORY
4495
+setup: git_dir: $here/31.git
4496
+setup: worktree: $here
4497
+setup: cwd: $here
4498
setup: prefix: 31/sub/sub/
4499
EOF
4499
- test_repo 31/sub/sub ../../.git "$TRASH_DIRECTORY"
4500
+ test_repo 31/sub/sub ../../.git "$here"
4501
'
4502
4503
test_expect_success '#31: GIT_DIR(rel), GIT_WORK_TREE=..(rel) in subdir' '
4504
cat >31/sub/sub/expected <<EOF &&
4504
-setup: git_dir: $TRASH_DIRECTORY/31.git
4505
-setup: worktree: $TRASH_DIRECTORY
4506
-setup: cwd: $TRASH_DIRECTORY
4505
+setup: git_dir: $here/31.git
4506
+setup: worktree: $here
4507
+setup: cwd: $here
4508
setup: prefix: 31/sub/sub/
4509
EOF
4510
test_repo 31/sub/sub ../../.git ../../..
@@ -4511,22 +4512,22 @@ EOF
4512
4513
test_expect_success '#31: GIT_DIR, GIT_WORK_TREE=..(rel) in subdir' '
4514
cat >31/sub/sub/expected <<EOF &&
4514
-setup: git_dir: $TRASH_DIRECTORY/31.git
4515
-setup: worktree: $TRASH_DIRECTORY
4516
-setup: cwd: $TRASH_DIRECTORY
4515
+setup: git_dir: $here/31.git
4516
+setup: worktree: $here
4517
+setup: cwd: $here
4518
setup: prefix: 31/sub/sub/
4519
EOF
4519
- test_repo 31/sub/sub "$TRASH_DIRECTORY/31/.git" ../../../
4520
+ test_repo 31/sub/sub "$here/31/.git" ../../../
4521
'
4522
4523
test_expect_success '#31: GIT_DIR, GIT_WORK_TREE=.. in subdir' '
4524
cat >31/sub/sub/expected <<EOF &&
4524
-setup: git_dir: $TRASH_DIRECTORY/31.git
4525
-setup: worktree: $TRASH_DIRECTORY
4526
-setup: cwd: $TRASH_DIRECTORY
4525
+setup: git_dir: $here/31.git
4526
+setup: worktree: $here
4527
+setup: cwd: $here
4528
setup: prefix: 31/sub/sub/
4529
EOF
4529
- test_repo 31/sub/sub "$TRASH_DIRECTORY/31/.git" "$TRASH_DIRECTORY"
4530
+ test_repo 31/sub/sub "$here/31/.git" "$here"
4531
'
4532
4533
test_done