File tree Expand file tree Collapse file tree 2 files changed +10
-6
lines changed Expand file tree Collapse file tree 2 files changed +10
-6
lines changed Original file line number Diff line number Diff line change 2
2
3
3
set -e
4
4
5
- message=" has changed"
6
-
7
5
if ! git diff-index --quiet HEAD; then
6
+ printf ' These files changed when running the command:\n\n'
7
+
8
8
git diff --name-only | while read -r n ; do
9
- echo " ::error file= $n :: $n $message "
9
+ echo " * $n "
10
10
done
11
11
12
12
exit 1
Original file line number Diff line number Diff line change 17
17
end
18
18
19
19
context "with a file change" do
20
- it "emits a annotation with the file " do
20
+ it "emits a summary with the files changed " do
21
21
session = create_session
22
22
23
23
session . run ( "echo 'new text' >> README" )
24
24
25
- expect ( session . run ( "diff-check" ) ) .
26
- to have_stdout ( "::error file=README::README has changed\n " )
25
+ expect ( session . run ( "diff-check" ) ) . to have_stdout ( <<~SUMMARY
26
+ These files changed when running the command:
27
+
28
+ * README
29
+ SUMMARY
30
+ )
27
31
end
28
32
29
33
it "exits with a status of 1" do
You can’t perform that action at this time.
0 commit comments