-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
56 changed files
with
1,477 additions
and
907 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,8 @@ | ||
FROM php:7.1-apache | ||
FROM splitbrain/phpfarm:jessie | ||
|
||
RUN apt-get update \ | ||
&& apt-get install -y git zip | ||
RUN apt-get update && apt-get install -y git zip | ||
|
||
COPY --from=composer:latest /usr/bin/composer /usr/bin/composer | ||
COPY . /var/www/html | ||
COPY . /var/www/ | ||
|
||
WORKDIR /var/www/html | ||
WORKDIR /var/www/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
vendor/ | ||
composer.lock | ||
phpunit.xml | ||
.idea | ||
.phpunit.result.cache |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,34 @@ | ||
language: php | ||
|
||
sudo: false | ||
jobs: | ||
include: | ||
- name: 'Tests under PHP 7.4' | ||
php: '7.4' | ||
dist: bionic | ||
- name: 'Tests under PHP 8.0' | ||
php: '8.0' | ||
dist: bionic | ||
- name: 'Tests under PHP nightly' | ||
php: 'nightly' | ||
dist: bionic | ||
|
||
php: | ||
- 7.1 | ||
- 7.2 | ||
fast_finish: true | ||
allow_failures: | ||
- php: 'nightly' | ||
|
||
cache: | ||
directories: | ||
- $HOME/.composer/cache | ||
|
||
install: | ||
- composer install | ||
- composer install | ||
|
||
script: | ||
- ./vendor/phpunit/phpunit/phpunit --coverage-text --coverage-clover=coverage.clover | ||
- php -dmemory_limit=-1 -dxdebug.mode=coverage ./vendor/phpunit/phpunit/phpunit --coverage-text --coverage-clover=coverage.clover | ||
|
||
after_script: | ||
- wget https://scrutinizer-ci.com/ocular.phar | ||
- php ocular.phar code-coverage:upload --format=php-clover coverage.clover | ||
- wget https://scrutinizer-ci.com/ocular.phar | ||
- php -dmemory_limit=-1 ocular.phar code-coverage:upload --format=php-clover coverage.clover | ||
|
||
after_success: | ||
- bash <(curl -s https://codecov.io/bash) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# UPGRADE FROM 2.* to 3.* | ||
|
||
The main change, apart from requiring PHP >= 7.4, is that `PhpFunction` and `PhpMethod` now accepts a `$returnType` parameter which impacts four locations: | ||
- `WsdlToPhp\PhpGenerator\Element\PhpFunction::__construct` has a new parameter after the `$parameters` parameter named `$returnType` which is a string allowing to set the function return type | ||
- `WsdlToPhp\PhpGenerator\Element\PhpMethod::__construct` has a new parameter after the `$parameters` parameter named `$returnType` which is a string allowing to set the method return type | ||
- `WsdlToPhp\PhpGenerator\Component\PhpClass::addMethod` has a new parameter after the `$parameters` parameter named `$returnType` which is a string allowing to set the method return type | ||
- `WsdlToPhp\PhpGenerator\Component\PhpInterface::addMethod` has a new parameter after the `$parameters` parameter named `$returnType` which is a string allowing to set the method return type | ||
|
||
**Previously**: | ||
```php | ||
$phpFunction = new PhpFunction('name', ['firstParameter', 'secondParameter']); | ||
|
||
$phpMethod = new PhpMethod('name', ['firstParameter', 'secondParameter'], PhpMethod::ACCESS_PUBLIC); | ||
|
||
$phpClass = (new PhpClass('MyClass')) | ||
->addMethod('name', ['firstParameter', 'secondParameter'], PhpMethod::ACCESS_PUBLIC); | ||
|
||
$phpInterface = (new PhpInterface('MyInterface')) | ||
->addMethod('name', ['firstParameter', 'secondParameter'], PhpMethod::ACCESS_PUBLIC); | ||
``` | ||
|
||
**Now**: | ||
```php | ||
$phpFunction = new PhpFunction('name', ['firstParameter', 'secondParameter'] /*, 'int' or '?int' or '?App\\Entity\\MyEntity'*/); | ||
|
||
$phpMethod = new PhpMethod('name', ['firstParameter', 'secondParameter'], null /*, 'int' or '?int' or '?App\\Entity\\MyEntity'*/, PhpMethod::ACCESS_PUBLIC); | ||
|
||
$phpClass = (new PhpClass('MyClass')) | ||
->addMethod('name', ['firstParameter', 'secondParameter'], null /*, 'int' or '?int' or '?App\\Entity\\MyEntity'*/, PhpMethod::ACCESS_PUBLIC); | ||
|
||
$phpInterface = (new PhpInterface('MyInterface')) | ||
->addMethod('name', ['firstParameter', 'secondParameter'], null /*, 'int' or '?int' or '?App\\Entity\\MyEntity'*/, PhpMethod::ACCESS_PUBLIC); | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,18 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
|
||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:noNamespaceSchemaLocation="http://schema.phpunit.de/4.1/phpunit.xsd" | ||
backupGlobals="false" | ||
colors="true" | ||
bootstrap="vendor/autoload.php" | ||
> | ||
<php> | ||
<ini name="error_reporting" value="-1" /> | ||
</php> | ||
|
||
<testsuite name="Test Suite"> | ||
<directory>./tests/</directory> | ||
</testsuite> | ||
|
||
<filter> | ||
<whitelist> | ||
<directory>./</directory> | ||
<exclude> | ||
<directory>./tests</directory> | ||
<directory>./vendor</directory> | ||
</exclude> | ||
</whitelist> | ||
</filter> | ||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd" backupGlobals="false" colors="true" bootstrap="vendor/autoload.php"> | ||
<coverage> | ||
<include> | ||
<directory>./</directory> | ||
</include> | ||
<exclude> | ||
<directory>./tests</directory> | ||
<directory>./vendor</directory> | ||
</exclude> | ||
</coverage> | ||
<php> | ||
<ini name="error_reporting" value="-1"/> | ||
</php> | ||
<testsuite name="Test Suite"> | ||
<directory>./tests/</directory> | ||
</testsuite> | ||
</phpunit> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.