Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 19 additions & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,17 @@ on: [push, pull_request]
jobs:
run-tests:
name: PHP ${{ matrix.php-versions }}

services:
redis:
image: redis:5-alpine
ports:
- 6379
memcached:
image: memcached:1.5-alpine
ports:
- 11211

runs-on: ubuntu-latest
env:
extensions: mbstring, intl, json, phalcon4, redis, mongodb, xdebug
Expand Down Expand Up @@ -53,8 +64,15 @@ jobs:
run: composer install --prefer-dist --no-suggest

- name: Run test suites
env:
DATA_REDIS_HOST: '127.0.0.1'
DATA_REDIS_PORT: ${{ job.services.redis.ports['6379'] }}
DATA_MEMCACHED_HOST: '127.0.0.1'
DATA_MEMCACHED_PORT: ${{ job.services.memcached.ports['11211'] }}
if: success()
run: vendor/bin/codecept run --coverage-xml=coverage-${{ matrix.php-versions }}.xml
run: |
cp tests/.env.example tests/.env
vendor/bin/codecept run --coverage-xml=coverage-${{ matrix.php-versions }}.xml

- name: Upload coverage to Codecov
if: success()
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
composer.phar
/vendor/
.env

# Commit your application's lock file https://getcomposer.org/doc/01-basic-usage.md#commit-your-composer-lock-file-to-version-control
# You may choose to ignore a library lock file http://getcomposer.org/doc/02-libraries.md#lock-file
Expand Down
9 changes: 4 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ Usage examples of the adapters available here:
## Memcached

Stores the parsed annotations to Memcached.
This adapter uses a `Phalcon\Cache\Backend\Libmemcached` backend to store the cached content:
This adapter uses a `Phalcon\Cache\Adapter\Libmemcached` backend to store the cached content:

```php
use Phalcon\Annotations\Adapter\Memcached;
use Phalcon\Incubator\Annotations\Adapter\Memcached;

$di->set(
'annotations',
Expand All @@ -29,10 +29,10 @@ $di->set(
## Redis

Stores the parsed annotations to Redis.
This adapter uses a `Phalcon\Cache\Backend\Redis` backend to store the cached content:
This adapter uses a `Phalcon\Cache\Adapter\Redis` backend to store the cached content:

```php
use Phalcon\Annotations\Adapter\Redis;
use Phalcon\Incubator\Annotations\Adapter\Redis;

$di->set(
'annotations',
Expand All @@ -48,4 +48,3 @@ $di->set(
}
);
```

2 changes: 1 addition & 1 deletion codeception.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ coverage:

params:
# get params from environment vars
- env
- tests/.env
3 changes: 1 addition & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,7 @@
"codeception/codeception": "^4.1",
"codeception/module-asserts": "^1.0.0",
"phpstan/phpstan": "^0.12.18",
"vlucas/phpdotenv": "^2.5",
"ocramius/package-versions": "1.4.0",
"vlucas/phpdotenv": "^4.1",
"phpunit/php-token-stream": "3.1.2",
"webmozart/glob": "4.1.0"
},
Expand Down
Loading