Skip to content

Commit c7ca4cc

Browse files
authored
Merge pull request #79 from simplesamlphp/feature/php8.3
Feature/php8.3
2 parents faa3768 + 4d3b0a3 commit c7ca4cc

File tree

192 files changed

+201
-548
lines changed

Some content is hidden

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

192 files changed

+201
-548
lines changed

.github/workflows/php.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@ jobs:
1919
strategy:
2020
fail-fast: false
2121
matrix:
22-
php-version: ['8.2', '8.3', '8.4', '8.5']
22+
php-version: ['8.3', '8.4', '8.5']
2323

24-
uses: simplesamlphp/simplesamlphp-test-framework/.github/workflows/reusable_phplinter.yml@v1.10.6
24+
uses: simplesamlphp/simplesamlphp-test-framework/.github/workflows/reusable_phplinter.yml@v1.11.0
2525
with:
2626
php-version: ${{ matrix.php-version }}
2727

@@ -30,7 +30,7 @@ jobs:
3030
strategy:
3131
fail-fast: false
3232

33-
uses: simplesamlphp/simplesamlphp-test-framework/.github/workflows/reusable_linter.yml@v1.10.6
33+
uses: simplesamlphp/simplesamlphp-test-framework/.github/workflows/reusable_linter.yml@v1.11.0
3434
with:
3535
enable_eslinter: false
3636
enable_jsonlinter: true
@@ -45,15 +45,15 @@ jobs:
4545
fail-fast: false
4646
matrix:
4747
operating-system: [ubuntu-latest]
48-
php-versions: ['8.2', '8.3', '8.4', '8.5']
48+
php-versions: ['8.3', '8.4', '8.5']
4949

5050
steps:
5151
- name: Setup PHP, with composer and extensions
5252
# https://github.com/shivammathur/setup-php
5353
uses: shivammathur/setup-php@v2
5454
with:
5555
php-version: ${{ matrix.php-versions }}
56-
extensions: ctype, date, dom, filter, libxml, pcre, spl, xml, xmlreader
56+
extensions: ctype, date, dom, filter, intl, libxml, pcre, sodium, spl, xml, xmlreader
5757
tools: composer
5858
ini-values: error_reporting=E_ALL
5959
coverage: pcov
@@ -107,15 +107,15 @@ jobs:
107107
fail-fast: true
108108
matrix:
109109
operating-system: [windows-latest]
110-
php-versions: ['8.2', '8.3', '8.4', '8.5']
110+
php-versions: ['8.3', '8.4', '8.5']
111111

112112
steps:
113113
- name: Setup PHP, with composer and extensions
114114
# https://github.com/shivammathur/setup-php
115115
uses: shivammathur/setup-php@v2
116116
with:
117117
php-version: ${{ matrix.php-versions }}
118-
extensions: ctype, date, dom, filter, libxml, pcre, spl, xml, xmlreader
118+
extensions: ctype, date, dom, filter, intl, libxml, pcre, sodium, spl, xml, xmlreader
119119
tools: composer
120120
ini-values: error_reporting=E_ALL
121121
coverage: none
@@ -163,7 +163,7 @@ jobs:
163163
# Should be the higest supported version, so we can use the newest tools
164164
php-version: '8.5'
165165
tools: composer, composer-require-checker, composer-unused
166-
extensions: ctype, date, dom, filter, libxml, pcre, spl, xml
166+
extensions: ctype, date, dom, filter, intl, libxml, pcre, sodium, spl, xml
167167
coverage: none
168168

169169
- name: Setup problem matchers for PHP
@@ -215,7 +215,7 @@ jobs:
215215
uses: shivammathur/setup-php@v2
216216
with:
217217
# Should be the lowest supported version
218-
php-version: '8.2'
218+
php-version: '8.3'
219219
extensions: ctype, date, dom, filter, libxml, pcre, spl, xml
220220
tools: composer
221221
coverage: none

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
}
3333
},
3434
"require": {
35-
"php": "^8.2",
35+
"php": "^8.3",
3636

3737
"ext-bcmath": "*",
3838
"ext-date": "*",
@@ -47,7 +47,7 @@
4747
"simplesamlphp/composer-xmlprovider-installer": "~1.2"
4848
},
4949
"require-dev": {
50-
"simplesamlphp/simplesamlphp-test-framework": "~1.10"
50+
"simplesamlphp/simplesamlphp-test-framework": "~1.11"
5151
},
5252
"support": {
5353
"issues": "https://github.com/simplesamlphp/xml-common/issues",

src/XML/AbstractElement.php

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,9 @@
2525
*
2626
* @package simplesamlphp/xml-common
2727
*/
28-
abstract class AbstractElement implements SerializableElementInterface
28+
abstract class AbstractElement implements
29+
SerializableElementInterface,
30+
ElementInterface
2931
{
3032
use SerializableElementTrait;
3133

@@ -34,7 +36,6 @@ abstract class AbstractElement implements SerializableElementInterface
3436
* Create a document structure for this element
3537
*
3638
* @param \DOMElement|null $parent The element we should append to.
37-
* @return \DOMElement
3839
*/
3940
public function instantiateParentElement(?DOMElement $parent = null): DOMElement
4041
{
@@ -117,7 +118,6 @@ public static function getOptionalAttribute(
117118
* Static method that processes a fully namespaced class name and returns the name of the class from it.
118119
*
119120
* @param string $class
120-
* @return string
121121
*/
122122
public static function getClassName(string $class): string
123123
{
@@ -129,8 +129,6 @@ public static function getClassName(string $class): string
129129

130130
/**
131131
* Get the XML qualified name (prefix:name) of the element represented by this class.
132-
*
133-
* @return string
134132
*/
135133
public function getQualifiedName(): string
136134
{
@@ -166,8 +164,6 @@ public static function getChildrenOfClass(DOMElement $parent): array
166164

167165
/**
168166
* Get the namespace for the element.
169-
*
170-
* @return string|null
171167
*/
172168
public static function getNamespaceURI(): ?string
173169
{
@@ -187,8 +183,6 @@ public static function getNamespaceURI(): ?string
187183

188184
/**
189185
* Get the namespace-prefix for the element.
190-
*
191-
* @return string
192186
*/
193187
public static function getNamespacePrefix(): string
194188
{
@@ -206,8 +200,6 @@ public static function getNamespacePrefix(): string
206200

207201
/**
208202
* Get the local name for the element.
209-
*
210-
* @return string
211203
*/
212204
public static function getLocalName(): string
213205
{
@@ -224,8 +216,6 @@ public static function getLocalName(): string
224216

225217
/**
226218
* Whether the element may be normalized.
227-
*
228-
* @return bool
229219
*/
230220
public static function getNormalization(): bool
231221
{
@@ -244,7 +234,6 @@ public static function getNormalization(): bool
244234
* Test if an object, at the state it's in, would produce an empty XML-element
245235
*
246236
* @codeCoverageIgnore
247-
* @return bool
248237
*/
249238
public function isEmptyElement(): bool
250239
{

src/XML/ArrayizableElementInterface.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ interface ArrayizableElementInterface
1515
* Create a class from an array
1616
*
1717
* @param array<string, mixed> $data
18-
* @return static
1918
*/
2019
public static function fromArray(array $data): static;
2120

src/XML/Assert/ByteTrait.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
*/
1212
trait ByteTrait
1313
{
14-
/** @var string */
1514
private static string $byte_regex = '/^
1615
(
1716
(

src/XML/Assert/DateTimeTrait.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,6 @@ trait DateTimeTrait
3030
* * ss is a two-integer-digit numeral that represents the whole seconds;
3131
* * '.' s+ (if present) represents the fractional seconds;
3232
* * zzzzzz (if present) represents the timezone (as described below).
33-
*
34-
* @var string
3533
*/
3634
private static string $datetime_regex = '/^
3735
-?

src/XML/Assert/DateTrait.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,6 @@ trait DateTrait
2121
*
2222
* and the least upper bound of the interval is the timeline point represented (noncanonically) by:
2323
* '-' yyyy '-' mm '-' dd 'T24:00:00' zzzzzz?.
24-
*
25-
* @var string
2624
*/
2725
private static string $date_regex = '/^
2826
-?

src/XML/Assert/DayTrait.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@ trait DayTrait
1313
{
1414
/**
1515
* Format: ---DD with optional timezone representation
16-
*
17-
* @var string
1816
*/
1917
private static string $day_regex = '/^
2018
---

src/XML/Assert/DecimalTrait.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
*/
1212
trait DecimalTrait
1313
{
14-
/** @var string */
1514
private static string $decimal_regex = '/^[+-]?((\d+(\.\d*)?)|(\.\d+))$/D';
1615

1716

src/XML/Assert/DoubleTrait.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
*/
1212
trait DoubleTrait
1313
{
14-
/** @var string */
1514
private static string $double_regex = '/^
1615
(
1716
([+-]?([0-9]+[.][0-9]*|[.][0-9]+)([e][+-]?[0-9]+)?)

0 commit comments

Comments
 (0)