Skip to content

Commit b24f0e0

Browse files
committed
Merge pull request php-curl-class#115 from zachborboa/master
Run unit tests before checking trailing whitespace in php files
2 parents 7ca96aa + f8b851d commit b24f0e0

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/script.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
# Check syntax in php files.
22
find . -type "f" -iname "*.php" | xargs -L "1" php -l
33

4+
# Run tests.
5+
cd tests && phpunit --configuration phpunit.xml
6+
47
# Check for trailing whitespace in php files.
58
trailing_whitespace=$(find . -type "f" -iname "*.php" -exec egrep --line-number -H " +$" {} \;)
69
if [[ ! -z "${trailing_whitespace}" ]]; then
710
echo -e "${trailing_whitespace}" | perl -pe 's/^(.*)$/Trailing whitespace found in \1/'
811
exit 1
912
fi
10-
11-
# Run tests.
12-
cd tests && phpunit --configuration phpunit.xml

0 commit comments

Comments
 (0)