blob 7d8467194165774868f6062fb9aa29c4cf7c7e1b 3215 bytes (raw)
name: t/t0041-usage.sh # note: path name is non-authoritative(*)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
| | #!/bin/sh
test_description='Test commands behavior when given invalid argument value'
. ./test-lib.sh
test_expect_success 'setup ' '
test_commit "v1.0"
'
test_expect_success 'tag --contains <existent_tag>' '
git tag --contains "v1.0" >actual 2>actual.err &&
grep "v1.0" actual &&
test_line_count = 0 actual.err
'
test_expect_success 'tag --contains <inexistent_tag>' '
test_must_fail git tag --contains "notag" >actual 2>actual.err &&
test_line_count = 0 actual &&
test_i18ngrep "error" actual.err &&
! grep "usage" actual.err
'
test_expect_success 'tag --no-contains <existent_tag>' '
git tag --no-contains "v1.0" >actual 2>actual.err &&
test_line_count = 0 actual &&
test_line_count = 0 actual.err
'
test_expect_success 'tag --no-contains <inexistent_tag>' '
test_must_fail git tag --no-contains "notag" >actual 2>actual.err &&
test_line_count = 0 actual &&
test_i18ngrep "error" actual.err &&
! grep "usage" actual.err
'
test_expect_success 'tag usage error' '
test_must_fail git tag --noopt >actual 2>actual.err &&
test_line_count = 0 actual &&
test_i18ngrep "usage" actual.err
'
test_expect_success 'branch --contains <existent_commit>' '
git branch --contains "master" >actual 2>actual.err &&
test_i18ngrep "master" actual &&
test_line_count = 0 actual.err
'
test_expect_success 'branch --contains <inexistent_commit>' '
test_must_fail git branch --no-contains "nocommit" >actual 2>actual.err &&
test_line_count = 0 actual &&
test_i18ngrep "error" actual.err &&
! grep "usage" actual.err
'
test_expect_success 'branch --no-contains <existent_commit>' '
git branch --no-contains "master" >actual 2>actual.err &&
test_line_count = 0 actual &&
test_line_count = 0 actual.err
'
test_expect_success 'branch --no-contains <inexistent_commit>' '
test_must_fail git branch --no-contains "nocommit" >actual 2>actual.err &&
test_line_count = 0 actual &&
test_i18ngrep "error" actual.err &&
! grep "usage" actual.err
'
test_expect_success 'branch usage error' '
test_must_fail git branch --noopt >actual 2>actual.err &&
test_line_count = 0 actual &&
test_i18ngrep "usage" actual.err
'
test_expect_success 'for-each-ref --contains <existent_object>' '
git for-each-ref --contains "master" >actual 2>actual.err &&
test_line_count = 2 actual &&
test_line_count = 0 actual.err
'
test_expect_success 'for-each-ref --contains <inexistent_object>' '
test_must_fail git for-each-ref --no-contains "noobject" >actual 2>actual.err &&
test_line_count = 0 actual &&
test_i18ngrep "error" actual.err &&
! grep "usage" actual.err
'
test_expect_success 'for-each-ref --no-contains <existent_object>' '
git for-each-ref --no-contains "master" >actual 2>actual.err &&
test_line_count = 0 actual &&
test_line_count = 0 actual.err
'
test_expect_success 'for-each-ref --no-contains <inexistent_object>' '
test_must_fail git for-each-ref --no-contains "noobject" >actual 2>actual.err &&
test_line_count = 0 actual &&
test_i18ngrep "error" actual.err &&
! grep "usage" actual.err
'
test_expect_success 'for-each-ref usage error' '
test_must_fail git for-each-ref --noopt >actual 2>actual.err &&
test_line_count = 0 actual &&
test_i18ngrep "usage" actual.err
'
test_done
|
debug log:
solving 7d84671941 ...
found 7d84671941 in https://public-inbox.org/git/20210111144740.6092-5-avarab@gmail.com/
found 5b927b76fe in https://80x24.org/mirrors/git.git
preparing index
index prepared:
100755 5b927b76fe58e5284d7b74e2f9fd8cc0b1f07764 t/t0041-usage.sh
applying [1/1] https://public-inbox.org/git/20210111144740.6092-5-avarab@gmail.com/
diff --git a/t/t0041-usage.sh b/t/t0041-usage.sh
index 5b927b76fe..7d84671941 100755
Checking patch t/t0041-usage.sh...
Applied patch t/t0041-usage.sh cleanly.
index at:
100755 7d8467194165774868f6062fb9aa29c4cf7c7e1b t/t0041-usage.sh
(*) Git path names are given by the tree(s) the blob belongs to.
Blobs themselves have no identifier aside from the hash of its contents.^
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).