Skip to content

Commit

Permalink
Fix tests (#524)
Browse files Browse the repository at this point in the history
  • Loading branch information
samdark authored Feb 21, 2025
1 parent 9dd5534 commit 8f4c350
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,31 +3,31 @@ help: ## Display help information

build: ## Build an image from a docker-compose file. Params: {{ v=5.6 }}. Default latest PHP 5.6
@cp -n .env.example .env
PHP_VERSION=$(filter-out $@,$(v)) docker-compose up -d --build
PHP_VERSION=$(filter-out $@,$(v)) docker compose up -d --build

test: ## Run tests. Params: {{ v=5.6 }}. Default latest PHP 5.6
PHP_VERSION=$(filter-out $@,$(v)) docker-compose build --pull yii2-queue-php
PHP_VERSION=$(filter-out $@,$(v)) docker-compose run yii2-queue-php vendor/bin/phpunit --colors=always -v --debug
PHP_VERSION=$(filter-out $@,$(v)) docker compose build --pull yii2-queue-php
PHP_VERSION=$(filter-out $@,$(v)) docker compose run yii2-queue-php vendor/bin/phpunit --colors=always -v --debug
make down

down: ## Stop and remove containers, networks
docker-compose down
docker compose down

benchmark: ## Run benchmark. Params: {{ v=5.6 }}. Default latest PHP 5.6
PHP_VERSION=$(filter-out $@,$(v)) docker-compose build --pull yii2-queue-php
PHP_VERSION=$(filter-out $@,$(v)) docker-compose run yii2-queue-php tests/yii benchmark/waiting
PHP_VERSION=$(filter-out $@,$(v)) docker compose build --pull yii2-queue-php
PHP_VERSION=$(filter-out $@,$(v)) docker compose run yii2-queue-php tests/yii benchmark/waiting
make down

sh: ## Enter the container with the application
docker exec -it yii2-queue-php bash

check-cs:
docker-compose build php72
docker-compose run php72 php-cs-fixer fix --diff --dry-run
docker-compose down
docker compose build php72
docker compose run php72 php-cs-fixer fix --diff --dry-run
docker compose down

clean:
docker-compose down
docker compose down
rm -rf tests/runtime/*
rm -f .php_cs.cache
rm -rf composer.lock
Expand Down

0 comments on commit 8f4c350

Please sign in to comment.