Skip to content

Commit fa97216

Browse files
committed
Merge pull request #586 from honza/tests
Add test for incorrect indentation, add Travis CI
2 parents fe844b6 + abdd057 commit fa97216

File tree

2 files changed

+23
-0
lines changed

2 files changed

+23
-0
lines changed

.travis.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
language: c
2+
sudo: false
3+
4+
notifications:
5+
email: false
6+
7+
script:
8+
- ./tests.sh

tests.sh

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
#!/usr/bin/env bash
2+
3+
SPACED=$(grep -REn '^ .+' --include '*.snippets' snippets);
4+
5+
if [[ -n SPACED ]]; then
6+
echo These snippet lines are indented with spaces:;
7+
echo;
8+
echo "$SPACED";
9+
echo;
10+
echo Tests failed!
11+
exit 1;
12+
fi
13+
14+
echo Tests passed!
15+
exit 0;

0 commit comments

Comments
 (0)