Skip to content

Commit bd10236

Browse files
committed
Merge branch 'release/4.1.6'
2 parents 334d921 + bac055a commit bd10236

File tree

164 files changed

+2651
-1619
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

164 files changed

+2651
-1619
lines changed

.github/workflows/release.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ jobs:
2121
matrix:
2222
php-version:
2323
- 7.4
24+
- 8.0
25+
- 8.1
26+
- 8.2
2427

2528
steps:
2629
- name: Get convenient env variables
@@ -41,7 +44,9 @@ jobs:
4144
run: echo $GITHUB_REF_NAME_SLUG
4245

4346
- name: Checkout code
44-
uses: actions/checkout@v2
47+
uses: actions/checkout@v3
48+
with:
49+
fetch-depth: 0
4550

4651
- name: Get convenient Docker Meta
4752
id: docker_meta

.github/workflows/sonars.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Sonars
2+
on:
3+
push:
4+
branches:
5+
- develop
6+
- feature/*
7+
- feat/*
8+
- release/*
9+
pull_request:
10+
types: [ opened, synchronize, reopened ]
11+
jobs:
12+
sonarcloud:
13+
name: Sonars
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Checkout code
17+
uses: actions/checkout@v3
18+
with:
19+
fetch-depth: 0
20+
21+
- name: Setup PHP with Xdebug
22+
uses: shivammathur/setup-php@v2
23+
with:
24+
php-version: 7.4
25+
coverage: xdebug
26+
27+
- name: Install dependencies with composer
28+
run: composer update --no-ansi --no-interaction --no-progress
29+
30+
- name: Generate coverage report with phpunit
31+
run: vendor/bin/phpunit --coverage-clover coverage.xml --log-junit report.xml
32+
33+
- name: Monitor coverage
34+
uses: slavcodev/coverage-monitor-action@v1
35+
with:
36+
github_token: ${{ secrets.ACTIONS_GITHUB_TOKEN }}
37+
coverage_path: coverage.xml
38+
threshold_alert: 95
39+
threshold_warning: 90
40+
41+
- name: Fix phpunit files paths
42+
run: sed -i 's@'$GITHUB_WORKSPACE/'@''@g' coverage.xml report.xml
43+
44+
- name: SonarCloud Scan
45+
uses: SonarSource/sonarcloud-github-action@master
46+
env:
47+
GITHUB_TOKEN: ${{ secrets.ACTIONS_GITHUB_TOKEN }}
48+
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

.php-cs-fixer.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,6 @@
99
->setUsingCache(false)
1010
->setRules(array(
1111
'@PhpCsFixer' => true,
12+
'phpdoc_separation' => false,
1213
))
1314
->setFinder($finder);

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
# CHANGELOG
22

3+
## 4.1.6 - 2023-02-20
4+
- issue #266, pr #270 - Usage of an undefined constant within a generate EnumType class #266
5+
- pr #267 - Remove deprecated message
6+
- issue #268, pr #271 - sequence Tag min/maxOccurs attribute is ignored
7+
- pr #269 - In method Utils::getStreamContextOptions function array_merge_recursive works not as expected
8+
- issue #272, pr #273 - Getter for a nullable-array-typed property is invalid
9+
- issue #274 - Improper validation of array #274
10+
311
## 4.1.5 - 2022-03-11
412
- issue #262 - Different destination dir when generating using 3.2.7 VS 4.1.1 ??
513

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,8 @@ First released on 03 April 2021, maintained until version 6.0 is released. Pleas
102102
### 3.0
103103
First released on 04 May 2018, maintained until version 5.0 is released. Please read the [UPGRADE-3.0](UPGRADE-3.0.md) note in order to acknowledge the main changes.
104104

105+
**NOT MAINTAINED ANYMORE**: even if version 5 is not published nor is expected soon, maintaining 2 versions, especially for an old PHP version, is time consuming, sorry for the people who would be still using it which would encounter issues fixed in the latest version.
106+
105107
### 2.0
106108
**Not maintained since 03 April 2021.**
107109

@@ -159,6 +161,7 @@ Developers who helped on this project are listed in the [composer.json](composer
159161
- [Jacob Dreesen](https://github.com/jdreesen)
160162
- [Clifford Vickrey](https://github.com/cliffordvickrey)
161163
- [Arnaud POINTET](https://github.com/Oipnet)
164+
- [dypa](https://github.com/dypa)
162165

163166
## FAQ
164167

composer.json

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,10 @@
8383
{
8484
"name": "Arnaud POINTET",
8585
"role": "Contributor"
86+
},
87+
{
88+
"name": "dypa",
89+
"role": "Contributor"
8690
}
8791
],
8892
"support" : {
@@ -103,10 +107,10 @@
103107
"wsdltophp/wsdlhandler": "^1.0"
104108
},
105109
"scripts": {
106-
"test": "vendor/bin/phpunit",
107-
"lint": "vendor/bin/php-cs-fixer fix --ansi --diff --verbose",
108-
"build": "box build --verbose",
109-
"phpstan": "vendor/bin/phpstan analyze src --level=2"
110+
"test": "php-7.4 vendor/bin/phpunit",
111+
"lint": "php-7.4 vendor/bin/php-cs-fixer fix --ansi --diff --verbose",
112+
"build": "php-7.4 box build --verbose",
113+
"phpstan": "php-7.4 vendor/bin/phpstan analyze src --level=2"
110114
},
111115
"require-dev": {
112116
"friendsofphp/php-cs-fixer": "^3.0",

phpstan.neon.dist

Lines changed: 0 additions & 3 deletions
This file was deleted.

sonar-project.properties

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
sonar.projectKey=WsdlToPhp_PackageGenerator
2+
sonar.organization=wsdltophp
3+
sonar.php.coverage.reportPaths=coverage.xml
4+
sonar.php.tests.reportPath=report.xml
5+
6+
sonar.sources=src/
7+
sonar.tests=tests/

src/Command/AbstractCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ abstract class AbstractCommand extends Command
1717

1818
protected OutputInterface $output;
1919

20-
protected function configure()
20+
protected function configure(): void
2121
{
2222
$this->addOption(
2323
'force',

src/Command/GeneratePackageCommand.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44

55
namespace WsdlToPhp\PackageGenerator\Command;
66

7-
use DateTime;
87
use Symfony\Component\Console\Input\InputInterface;
98
use Symfony\Component\Console\Input\InputOption;
109
use Symfony\Component\Console\Output\OutputInterface;
@@ -276,7 +275,7 @@ protected function configure(): void
276275
protected function execute(InputInterface $input, OutputInterface $output): int
277276
{
278277
parent::execute($input, $output);
279-
$start = new DateTime();
278+
$start = new \DateTime();
280279
$this->writeLn(sprintf(' Start at %s', $start->format('Y-m-d H:i:s')));
281280
$this->initGeneratorOptions();
282281
if ($this->canExecute()) {
@@ -287,7 +286,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
287286
$this->writeLn(" Used generator's options:");
288287
$this->writeLn(' '.implode(PHP_EOL.' ', $this->formatArrayForConsole($this->generatorOptions->toArray())));
289288
}
290-
$end = new DateTime();
289+
$end = new \DateTime();
291290
$this->writeLn(sprintf(' End at %s, duration: %s', $end->format('Y-m-d H:i:s'), $start->diff($end)->format('%H:%I:%S')));
292291

293292
return self::EXIT_OK;

0 commit comments

Comments
 (0)