Skip to content

Commit

Permalink
Automate squizlabs/php_codesniffer
Browse files Browse the repository at this point in the history
  • Loading branch information
phil-davis committed Sep 20, 2018
1 parent f2bf7fa commit 6756d04
Show file tree
Hide file tree
Showing 4 changed files with 73 additions and 3 deletions.
13 changes: 13 additions & 0 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,15 @@ pipeline:
matrix:
TEST_SUITE: phan

php-acceptance-test-style:
image: owncloudci/php:${PHP_VERSION}
pull: true
commands:
- make test-acceptance-style
when:
matrix:
TEST_SUITE: php-acceptance-test-style

install-server:
image: owncloudci/php:${PHP_VERSION}
pull: true
Expand Down Expand Up @@ -556,6 +565,10 @@ matrix:
- TEST_SUITE: phan
PHP_VERSION: 7.1

# php-acceptance-test-style
- TEST_SUITE: php-acceptance-test-style
PHP_VERSION: 7.2

# Litmus
- PHP_VERSION: 7.1
USE_SERVER: true
Expand Down
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ help:
@echo -e "make test\t\t\trun all tests"
@echo -e "make test-php\t\t\trun all PHP tests"
@echo -e "make test-php-style\t\trun PHP code style checks"
@echo -e "make test-acceptance-style\t\trun extra PHP code style checks on acceptance test code"
@echo -e "make test-js\t\t\trun Javascript tests"
@echo -e "make test-js-debug\t\trun Javascript tests in debug mode (continuous)"
@echo -e "make test-acceptance\t\trun acceptance tests"
Expand Down Expand Up @@ -205,8 +206,12 @@ test-php-style-fix: $(composer_dev_deps)
test-php-phan: $(PHAN_BIN)
php $(PHAN_BIN) --config-file .phan/config.php --require-config-exists -p

.PHONY: test-acceptance-style
test-acceptance-style: $(composer_dev_deps)
$(composer_deps)/bin/phpcs --standard=phpcs.xml tests/acceptance

.PHONY: test
test: test-php-lint test-php-style test-php test-js test-acceptance
test: test-php-lint test-php-style test-acceptance-style test-php test-js test-acceptance

.PHONY: clean-test-acceptance
clean-test-acceptance:
Expand Down
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
"jarnaiz/behat-junit-formatter": "^1.3",
"mikey179/vfsStream": "^1.6",
"owncloud/coding-standard": "^1.0",
"squizlabs/php_codesniffer": "3.*",
"phpunit/phpunit": "^5.7",
"rdx/behat-variables": "^1.2",
"roave/security-advisories": "dev-master",
Expand Down
55 changes: 53 additions & 2 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 6756d04

Please sign in to comment.