File tree Expand file tree Collapse file tree 6 files changed +23
-9
lines changed Expand file tree Collapse file tree 6 files changed +23
-9
lines changed Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ COVERAGE_OUTPUT_STYLE ?= html
66BUILD_DIRECTORY ?= build
77REPORTS_DIRECTORY ?= ${BUILD_DIRECTORY}/reports
88COVERAGE_DIRECTORY ?= ${BUILD_DIRECTORY}/coverage
9+ BEHAT_COVERAGE_DIRECTORY ?= ${BUILD_DIRECTORY}/behat-coverage
910COVERAGE_CLOVER_FILE_PATH ?= ${COVERAGE_DIRECTORY}/clover.xml
1011
1112# # Commands options
@@ -88,15 +89,21 @@ codestyle: create-reports-directory
8889coverage : create-coverage-directory
8990 ./vendor/bin/phpunit ${PHPUNIT_COLOR_OPTION} ${PHPUNIT_OUTPUT_STYLE_OPTION} ${PHPUNIT_COVERAGE_OPTION}
9091
92+ behat-coverage : create-behat-coverage-directory
93+ composer required leanphp/behat-code-coverage
94+ ./vendor/bin/behat ${BEHAT_COLOR_OPTION} ${BEHAT_OUTPUT_STYLE_OPTION} --no-snippets --profile coverage
9195
9296
9397# Internal commands
9498create-coverage-directory :
9599 mkdir -p ${COVERAGE_DIRECTORY}
96100
101+ create-behat-coverage-directory :
102+ mkdir -p ${BEHAT_COVERAGE_DIRECTORY}
103+
97104create-reports-directory :
98105 mkdir -p ${REPORTS_DIRECTORY}
99106
100107
101- .PHONY : build install configure test test-technical test-functional codestyle coverage create-coverage-directory create-reports-directory
108+ .PHONY : build install configure test test-technical test-functional codestyle coverage behat-coverage create-coverage-directory create-behat -coverage-directory create-reports-directory
102109.DEFAULT : build
Original file line number Diff line number Diff line change 33
44[ ![ Scrutinizer Build Status] ( https://img.shields.io/scrutinizer/build/g/yoanm/php-jsonrpc-params-symfony-validator-sdk.svg?label=Scrutinizer&logo=scrutinizer )] ( https://scrutinizer-ci.com/g/yoanm/php-jsonrpc-params-symfony-validator-sdk/build-status/master ) [ ![ Scrutinizer Code Quality] ( https://img.shields.io/scrutinizer/g/yoanm/php-jsonrpc-params-symfony-validator-sdk/master.svg?logo=scrutinizer )] ( https://scrutinizer-ci.com/g/yoanm/php-jsonrpc-params-symfony-validator-sdk/?branch=master ) [ ![ Code Coverage] ( https://img.shields.io/scrutinizer/coverage/g/yoanm/php-jsonrpc-params-symfony-validator-sdk/master.svg?logo=scrutinizer )] ( https://scrutinizer-ci.com/g/yoanm/php-jsonrpc-params-symfony-validator-sdk/?branch=master )
55
6- [ ![ Travis Build Status] ( https://img.shields.io/travis/com/yoanm/php-jsonrpc-params-symfony-validator-sdk/master.svg?label=Travis&logo=travis )] ( https://travis-ci.com/yoanm/php-jsonrpc-params-symfony-validator-sdk ) [ ![ Travis PHP versions] ( https://img.shields.io/travis/php-v/yoanm/php-jsonrpc-params-symfony-validator-sdk.svg?logo=travis )] ( https://php.net/ ) [ ![ Travis Symfony Versions] ( https://img.shields.io/badge/Symfony-v3%20%2F%20v4-8892BF.svg?logo=travis )] ( https://symfony.com / )
6+ [ ![ Travis Build Status] ( https://img.shields.io/travis/com/yoanm/php-jsonrpc-params-symfony-validator-sdk/master.svg?label=Travis&logo=travis )] ( https://travis-ci.com/yoanm/php-jsonrpc-params-symfony-validator-sdk ) [ ![ Travis PHP versions] ( https://img.shields.io/travis/php-v/yoanm/php-jsonrpc-params-symfony-validator-sdk.svg?logo=travis )] ( https://travis-ci.com/yoanm/php-jsonrpc-params-symfony-validator-sdk ) [ ![ Travis Symfony Versions] ( https://img.shields.io/badge/Symfony-v3%20%2F%20v4-8892BF.svg?logo=travis )] ( https://php.net / )
77
88[ ![ Latest Stable Version] ( https://img.shields.io/packagist/v/yoanm/jsonrpc-params-symfony-validator-sdk.svg )] ( https://packagist.org/packages/yoanm/jsonrpc-params-symfony-validator-sdk ) [ ![ Packagist PHP version] ( https://img.shields.io/packagist/php-v/yoanm/jsonrpc-params-symfony-validator-sdk.svg )] ( https://packagist.org/packages/yoanm/jsonrpc-params-symfony-validator-sdk )
99
Original file line number Diff line number Diff line change @@ -3,3 +3,17 @@ default:
33 default :
44 contexts :
55 - Tests\Functional\BehatContext\FeatureContext : ~
6+ coverage :
7+ extensions :
8+ LeanPHP\Behat\CodeCoverage\Extension :
9+ drivers :
10+ - local
11+ filter :
12+ whitelist :
13+ include :
14+ directories :
15+ ' src ' : ~
16+ report :
17+ format : html
18+ options :
19+ target : build/behat-coverage
Original file line number Diff line number Diff line change 22namespace Tests \Functional \BehatContext ;
33
44use Behat \Behat \Context \Context ;
5- use Behat \Behat \Context \Environment \InitializedContextEnvironment ;
6- use Behat \Behat \Hook \Scope \BeforeScenarioScope ;
75use Behat \Gherkin \Node \PyStringNode ;
86use PHPUnit \Framework \Assert ;
97use PHPUnit \Framework \Constraint \IsIdentical ;
10- use Prophecy \Argument ;
118use Symfony \Component \Validator \ValidatorBuilder ;
12- use Tests \Functional \BehatContext \App \FakeEndpointCreator ;
139use Yoanm \JsonRpcParamsSymfonyValidator \Infra \JsonRpcParamsValidator ;
1410use Yoanm \JsonRpcServer \Domain \Model \JsonRpcRequest ;
1511
@@ -51,7 +47,6 @@ public function thenIShouldHaveXViolation($count = 1)
5147
5248 /**
5349 * @Then I should have the following validation error:
54- * @param PyStringNode $node
5550 */
5651 public function thenIShouldHaveTheFollowingViolation (PyStringNode $ node )
5752 {
Original file line number Diff line number Diff line change 88 processIsolation =" false"
99
1010 stopOnRisky =" true"
11-
1211 stopOnError =" true"
1312 stopOnFailure =" true"
1413
Original file line number Diff line number Diff line change @@ -36,7 +36,6 @@ public function setUp()
3636
3737 public function testShouldDoNothingIfMethodDoesNotImplementSpecificInterface ()
3838 {
39- $ paramList = ['paramList ' ];
4039 /** @var JsonRpcMethodInterface|ObjectProphecy $method */
4140 $ method = $ this ->prophesize (JsonRpcMethodInterface::class);
4241 /** @var JsonRpcRequest $jsonRpcRequest */
You can’t perform that action at this time.
0 commit comments