Skip to content

Commit

Permalink
chore: Migrated PHPUnit config. Added script for running tests to com…
Browse files Browse the repository at this point in the history
…poser.json (#203)
  • Loading branch information
bhdnb authored Jan 16, 2025
1 parent d2e4f80 commit 593e50e
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 13 deletions.
9 changes: 9 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,5 +42,14 @@
"CrowdinApiClient\\FrameworkSupport\\Laravel\\CrowdinServiceProvider"
]
}
},
"config": {
"sort-packages": true
},
"scripts": {
"test": "vendor/bin/phpunit"
},
"scripts-descriptions": {
"test": "Run tests"
}
}
2 changes: 1 addition & 1 deletion composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 14 additions & 12 deletions phpunit.xml
Original file line number Diff line number Diff line change
@@ -1,25 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit backupGlobals="false"
backupStaticAttributes="false"
bootstrap="vendor/autoload.php"
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd"
colors="true"
bootstrap="vendor/autoload.php"
backupGlobals="false"
backupStaticAttributes="false"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
convertDeprecationsToExceptions="true"
processIsolation="false"
stopOnFailure="false">
<coverage processUncoveredFiles="true">
<include>
<directory suffix=".php">./src</directory>
</include>
<exclude>
<directory>./src/CrowdinApiClient/FrameworkSupport</directory>
</exclude>
</coverage>
<testsuites>
<testsuite name="crowdin api client Test Suite">
<testsuite name="Crowdin API Client Test Suite">
<directory>./tests/CrowdinApiClient/</directory>
</testsuite>
</testsuites>
<filter>
<whitelist processUncoveredFilesFromWhitelist="true">
<directory suffix=".php">./src</directory>
<exclude>
<directory>./src/CrowdinApiClient/FrameworkSupport</directory>
</exclude>
</whitelist>
</filter>
</phpunit>

0 comments on commit 593e50e

Please sign in to comment.