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
4 changes: 3 additions & 1 deletion .github/workflows/analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@ jobs:
run: composer install --no-progress --prefer-dist --optimize-autoloader

- name: Run Static Analysis
run: composer run-script analyse
run: |
composer run-script analyse
composer run-script analyse-tests

- name: Run Test Coverage
run: composer run-script test-coverage
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ jobs:
strategy:
matrix:
operating-system: [ubuntu-latest, windows-latest]
php-versions: ['8.1', '8.2', '8.3', '8.4', '8.5']
php-versions: ['8.2', '8.3', '8.4', '8.5']
name: PHP ${{ matrix.php-versions }} Test on ${{ matrix.operating-system }}
steps:
- name: Checkout
Expand All @@ -16,7 +16,7 @@ jobs:
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
coverage: xdebug
coverage: none

- name: Get Composer Cache Directory
id: composer-cache
Expand All @@ -33,5 +33,5 @@ jobs:
- name: Install Composer dependencies
run: composer install --no-progress --prefer-dist --optimize-autoloader

- name: Run Specs
run: composer run-script test
- name: Run Tests
run: composer run-script test-unit
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ composer.lock
composer.phar
.idea/
vendor/
bin/
bin/
.phpunit.result.cache
28 changes: 18 additions & 10 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,14 @@
}
],
"require": {
"php": ">=7.1"
"php": ">=8.2"
},
"require-dev": {
"phpspec/phpspec": "^7.1|^8.0",
"freedsx/asn1": ">=0.4, <1.0",
"friends-of-phpspec/phpspec-code-coverage": "^6.1|^7.0",
"phpstan/phpstan": "^2.0"
"phpunit/phpunit": "^11.5",
"phpstan/phpstan": "^2.0",
"phpstan/phpstan-phpunit": "^2.0",
"phpstan/extension-installer": "^1.4"
},
"suggest": {
"ext-openssl": "For SSL/TLS support.",
Expand All @@ -32,19 +33,26 @@
},
"autoload-dev": {
"psr-4": {
"fixture\\FreeDSx\\Socket\\": "tests/fixture/FreeDSx/Socket",
"spec\\FreeDSx\\Socket\\": "tests/spec/FreeDSx/Socket"
"Tests\\Unit\\FreeDSx\\Socket\\": "tests/unit"
}
},
"config": {
"allow-plugins": {
"phpstan/extension-installer": true
}
},
"scripts": {
"test-coverage": [
"phpspec run --no-interaction -c phpspec.cov.yml"
"test-unit": [
"@php -d xdebug.mode=off vendor/bin/phpunit --testsuite unit"
],
"test": [
"phpspec run --no-interaction"
"test-coverage": [
"@php -d xdebug.mode=coverage vendor/bin/phpunit --testsuite unit --coverage-clover=coverage.xml"
],
"analyse": [
"phpstan analyse"
],
"analyse-tests": [
"phpstan analyse -c phpstan.tests.neon"
]
}
}
13 changes: 0 additions & 13 deletions phpspec.cov.yml

This file was deleted.

4 changes: 0 additions & 4 deletions phpspec.yml

This file was deleted.

4 changes: 2 additions & 2 deletions phpstan.neon
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ parameters:
level: 6
paths:
- %currentWorkingDirectory%/src
phpVersion: 70100
treatPhpDocTypesAsCertain: false
phpVersion: 80200
treatPhpDocTypesAsCertain: false
5 changes: 5 additions & 0 deletions phpstan.tests.neon
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
parameters:
treatPhpDocTypesAsCertain: false
level: 10
paths:
- %currentWorkingDirectory%/tests
30 changes: 30 additions & 0 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
backupGlobals="false"
colors="true"
displayDetailsOnTestsThatTriggerDeprecations="true"
displayDetailsOnTestsThatTriggerErrors="true"
displayDetailsOnTestsThatTriggerNotices="true"
displayDetailsOnTestsThatTriggerWarnings="true"
displayDetailsOnPhpunitDeprecations="true"
processIsolation="false"
stopOnFailure="false"
bootstrap="vendor/autoload.php"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/11.5/phpunit.xsd"
>
<source ignoreIndirectDeprecations="true">
<include>
<directory suffix=".php">./src</directory>
</include>
</source>
<coverage includeUncoveredFiles="true"
pathCoverage="false"
ignoreDeprecatedCodeUnits="true"
disableCodeCoverageIgnore="true">
</coverage>
<testsuites>
<testsuite name="unit">
<directory>./tests/unit</directory>
</testsuite>
</testsuites>
</phpunit>
21 changes: 0 additions & 21 deletions src/FreeDSx/Socket/MessageQueue.php

This file was deleted.

50 changes: 0 additions & 50 deletions tests/fixture/FreeDSx/Socket/Pdu.php

This file was deleted.

27 changes: 0 additions & 27 deletions tests/spec/FreeDSx/Socket/Exception/ConnectionExceptionSpec.php

This file was deleted.

This file was deleted.

62 changes: 0 additions & 62 deletions tests/spec/FreeDSx/Socket/MessageQueueSpec.php

This file was deleted.

Loading
Loading