Skip to content

Commit

Permalink
Merge pull request #70 from phalcon/feature/#20-cli-options-parser
Browse files Browse the repository at this point in the history
#20 - Refactor CLI
  • Loading branch information
Jeckerson committed Mar 19, 2020
2 parents d225f61 + 8f6f403 commit ec6699f
Show file tree
Hide file tree
Showing 78 changed files with 3,365 additions and 2,388 deletions.
13 changes: 8 additions & 5 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ jobs:
name: PHP ${{ matrix.php-versions }}
runs-on: ubuntu-latest
env:
extensions: mbstring, intl, json, phalcon4, mysql, pgsql
key: cache-v1.2
extensions: mbstring, intl, json, phalcon-4.0.5, mysql, pgsql, xdebug
key: cache-v2.0
services:
mysql:
image: mysql:5.7
Expand Down Expand Up @@ -66,16 +66,19 @@ jobs:
- name: Install Composer dependencies
run: composer install --prefer-dist --no-suggest

- name: Run test suite
- name: Copy .env file
run: cp tests/.env.example tests/.env

- name: Run test suites
env:
MYSQL_TEST_DB_PORT: ${{ job.services.mysql.ports['3306'] }}
POSTGRES_TEST_DB_PORT: ${{ job.services.postgres.ports['5432'] }}
if: success()
run: vendor/bin/phpunit --coverage-clover=coverage.xml
run: vendor/bin/codecept run --coverage-xml=coverage-${{ matrix.php-versions }}.xml

- name: Upload coverage to Codecov
if: success()
uses: codecov/codecov-action@v1
with:
token: ${{secrets.CODECOV_TOKEN}}
file: ./coverage.xml
file: ./tests/_output/coverage-*.xml
2 changes: 1 addition & 1 deletion .github/workflows/validations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
name: Static Code with PHP ${{ matrix.php-versions }}
runs-on: ubuntu-latest
env:
extensions: mbstring, intl, json, phalcon4
extensions: mbstring, intl, json, phalcon-4.0.5
key: cache-v1.2
needs: validate-code-style
strategy:
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
composer.phar
/vendor/
.env
17 changes: 17 additions & 0 deletions codeception.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
paths:
tests: tests
output: tests/_output
data: tests/_data
support: tests/_support
envs: tests/_envs
actor_suffix: Tester
bootstrap: bootstrap.php
extensions:
enabled:
- Codeception\Extension\RunFailed
params:
- tests/.env
coverage:
enabled: true
include:
- src/*
32 changes: 19 additions & 13 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
{
"name": "phalcon/migrations",
"description": "Run and Generate DB Migrations with Phalcon Framework",
"keywords": ["framework", "phalcon", "migration", "phar"],
"keywords": [
"framework",
"phalcon",
"migration",
"phar"
],
"homepage": "https://phalcon.io",
"license": "BSD-3-Clause",
"authors": [
Expand All @@ -22,29 +27,28 @@
},
"require": {
"php": ">=7.2",
"ext-phalcon": "^4.0.0"
"ext-phalcon": "^4.0.5",
"phalcon/cli-options-parser": "^1.2"
},
"require-dev": {
"phpunit/phpunit": "8.4.1",
"ext-pdo": "*",
"phalcon/ide-stubs": "^4.0.0",
"vimeo/psalm": "3.6.2",
"squizlabs/php_codesniffer": "3.5.1",
"fzaninotto/faker": "^1.9",
"humbug/box": "^3.8"
"humbug/box": "^3.8",
"codeception/codeception": "^4.1",
"codeception/module-asserts": "^1.0.0",
"codeception/module-cli": "^1.0",
"codeception/module-phpbrowser": "^1.0.0",
"codeception/module-db": "^1.0",
"vlucas/phpdotenv": "^4.1"
},
"autoload": {
"psr-4": {
"Phalcon\\Migrations\\": "src/"
}
},
"autoload-dev": {
"psr-4": {
"Phalcon\\Migrations\\Tests\\": "tests/"
},
"files": [
"tests/Helpers.php"
]
},
"suggest": {
"robmorgan/phinx": "Phinx makes it ridiculously easy to manage the database migrations for your PHP app."
},
Expand All @@ -61,5 +65,7 @@
"psalm.xml.dist"
]
},
"bin": ["phalcon-migrations"]
"bin": [
"phalcon-migrations"
]
}
Loading

0 comments on commit ec6699f

Please sign in to comment.