@matheusbsbs / matheus-bagliano / commits / 70789843bd
Fork 0

t6025: modernize style

The tests in `t6025-merge-symlinks.sh` were written a long time ago, and has a lot of style violations, including the mixed-use of tabs and spaces, missing indentations, and other shell script style violations. Update it to match the CodingGuidelines. Signed-off-by: Shourya Shukla <shouryashukla.oo@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Shourya Shukla committed Jan 18, 2020 at 14:03 UTC 70789843bd8f48a15e68619ca33c548969dc90b6
1 file changed +48 -47
t/t6025-merge-symlinks.sh
+48 -47
@@ -10,52 +10,53 @@ if core.symlinks is false.'
10
11 . ./test-lib.sh
12
13 -test_expect_success \
14 -'setup' '
15 -git config core.symlinks false &&
16 -> file &&
17 -git add file &&
18 -git commit -m initial &&
19 -git branch b-symlink &&
20 -git branch b-file &&
21 -l=$(printf file | git hash-object -t blob -w --stdin) &&
22 -echo "120000 $l symlink" | git update-index --index-info &&
23 -git commit -m master &&
24 -git checkout b-symlink &&
25 -l=$(printf file-different | git hash-object -t blob -w --stdin) &&
26 -echo "120000 $l symlink" | git update-index --index-info &&
27 -git commit -m b-symlink &&
28 -git checkout b-file &&
29 -echo plain-file > symlink &&
30 -git add symlink &&
31 -git commit -m b-file'
32 -
33 -test_expect_success \
34 -'merge master into b-symlink, which has a different symbolic link' '
35 -git checkout b-symlink &&
36 -test_must_fail git merge master'
37 -
38 -test_expect_success \
39 -'the merge result must be a file' '
40 -test -f symlink'
41 -
42 -test_expect_success \
43 -'merge master into b-file, which has a file instead of a symbolic link' '
44 -git reset --hard && git checkout b-file &&
45 -test_must_fail git merge master'
46 -
47 -test_expect_success \
48 -'the merge result must be a file' '
49 -test -f symlink'
50 -
51 -test_expect_success \
52 -'merge b-file, which has a file instead of a symbolic link, into master' '
53 -git reset --hard &&
54 -git checkout master &&
55 -test_must_fail git merge b-file'
56 -
57 -test_expect_success \
58 -'the merge result must be a file' '
59 -test -f symlink'
13 +test_expect_success 'setup' '
14 + git config core.symlinks false &&
15 + >file &&
16 + git add file &&
17 + git commit -m initial &&
18 + git branch b-symlink &&
19 + git branch b-file &&
20 + l=$(printf file | git hash-object -t blob -w --stdin) &&
21 + echo "120000 $l symlink" | git update-index --index-info &&
22 + git commit -m master &&
23 + git checkout b-symlink &&
24 + l=$(printf file-different | git hash-object -t blob -w --stdin) &&
25 + echo "120000 $l symlink" | git update-index --index-info &&
26 + git commit -m b-symlink &&
27 + git checkout b-file &&
28 + echo plain-file >symlink &&
29 + git add symlink &&
30 + git commit -m b-file
31 +'
32 +
33 +test_expect_success 'merge master into b-symlink, which has a different symbolic link' '
34 + git checkout b-symlink &&
35 + test_must_fail git merge master
36 +'
37 +
38 +test_expect_success 'the merge result must be a file' '
39 + test -f symlink
40 +'
41 +
42 +test_expect_success 'merge master into b-file, which has a file instead of a symbolic link' '
43 + git reset --hard &&
44 + git checkout b-file &&
45 + test_must_fail git merge master
46 +'
47 +
48 +test_expect_success 'the merge result must be a file' '
49 + test -f symlink
50 +'
51 +
52 +test_expect_success 'merge b-file, which has a file instead of a symbolic link, into master' '
53 + git reset --hard &&
54 + git checkout master &&
55 + test_must_fail git merge b-file
56 +'
57 +
58 +test_expect_success 'the merge result must be a file' '
59 + test -f symlink
60 +'
61
62 test_done