]> git.ipfire.org Git - thirdparty/git.git/blame - t/t3908-stash-in-worktree.sh
t2104: style fixes
[thirdparty/git.git] / t / t3908-stash-in-worktree.sh
CommitLineData
dfd557c9
JS
1#!/bin/sh
2#
3# Copyright (c) 2019 Johannes E Schindelin
4#
5
6test_description='Test git stash in a worktree'
7
d96fb140 8TEST_PASSES_SANITIZE_LEAK=true
dfd557c9
JS
9. ./test-lib.sh
10
11test_expect_success 'setup' '
12 test_commit initial &&
13 git worktree add wt &&
14 test_commit -C wt in-worktree
15'
16
17test_expect_success 'apply in subdirectory' '
18 mkdir wt/subdir &&
19 (
20 cd wt/subdir &&
21 echo modified >../initial.t &&
22 git stash &&
23 git stash apply >out
24 ) &&
25 grep "\.\.\/initial\.t" wt/subdir/out
26'
27
28test_done