From 8152c3951a2d45531647b39a798df99bae441ca3 Mon Sep 17 00:00:00 2001
From: Bueltge <133425+bueltge@users.noreply.github.com>
Date: Thu, 19 Nov 2026 11:21:47 +0100
Subject: [PATCH] chore: tidy tests, phpunit coverage config, app config and
README
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
---
.github/github-app.yml | 21 ++-------------------
CHANGELOG.md | 3 +++
README.md | 2 +-
composer.json | 1 +
phpunit.xml.dist | 6 ------
tests/phpunit/Unit/MarksimpleTest.php | 9 +++++----
6 files changed, 12 insertions(+), 30 deletions(-)
diff --git a/.github/github-app.yml b/.github/github-app.yml
index 80e81cb..b6416dc 100644
--- a/.github/github-app.yml
+++ b/.github/github-app.yml
@@ -1,24 +1,7 @@
-# GitHub App Manifest / Konfigurationsdatei (.github/github-app.yml)
-version: 1
-
-# Grundlegende Informationen zur App-Konfiguration
-name: "Copilot & Bot Workflow Integration"
-description: "Repository-spezifische Konfiguration für automatisierte Workflows und Copilot-Assistenten."
-
-# Standard-Anweisungen und Prompt-Kontext für Copilot im Repository
+# Repository configuration for the GitHub Copilot app
+# https://docs.github.com/copilot/reference/github-copilot-app-reference/repository-configuration
instructions: |
# Repository-Richtlinien für GitHub Copilot
- Achten Sie darauf, bestehende Architekturmuster und Code-Konventionen (z. B. Coding Styles, Namenskonventionen) einzuhalten.
- Dokumentieren Sie neue Funktionen und Schnittstellen direkt im jeweiligen Code-Modul.
- Vermeiden Sie hardgecodete Secrets oder sensible Konfigurationswerte im Code.
-
-# Berechtigungen und Events (Beispielhaft für Automatisierungen)
-default_permissions:
- contents: write
- pull_requests: write
- issues: read
-
-default_events:
- - pull_request
- - push
- - issues
diff --git a/CHANGELOG.md b/CHANGELOG.md
index e3c4ab1..e178c6e 100755
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -10,6 +10,9 @@ This project adheres to [Semantic Versioning](http://semver.org/).
* Lower `phpunit/phpunit` to `^11.5`: PHPUnit 13 requires PHP 8.4, but the library and CI support PHP 8.2 and 8.3. Refresh `composer.lock`.
* Set `minimum-stability` to `stable` and remove unused `allow-plugins` entries.
* CI: remove the duplicate `phpcbf.yml` autofix workflow (autofix stays in `main.yml` for pull requests), set default `contents: read` permissions, drop the redundant non-blocking `phpcs` step and `composer clear-cache`, and cache Composer packages.
+* Create the unreadable test file in the system temp directory, so no `no_readable_file.txt` is left in the repository.
+* Remove the coverage reports from `phpunit.xml.dist` (no more "No code coverage driver" warning) and add the `composer coverage` script.
+* Reduce `.github/github-app.yml` to the supported `instructions` key and update the PHP requirement in the README.
* Update `antecedent/patchwork` to 2.2.5 and `stefanzweifel/git-auto-commit-action` to 7.
## 2.3.0 (2026-11-06)
diff --git a/README.md b/README.md
index bf6819b..a240923 100755
--- a/README.md
+++ b/README.md
@@ -44,7 +44,7 @@ My class supports currently the follow syntax. But Pull Request are really welco
#### Requirements
- * PHP 8.2 tested
+ * PHP 8.2 or higher, tested with PHP 8.2 to 8.5
Install static via download, clone the repository or use dependency management via Composer
diff --git a/composer.json b/composer.json
index 02218a0..b57a1f1 100644
--- a/composer.json
+++ b/composer.json
@@ -48,6 +48,7 @@
"cs": "@php ./vendor/squizlabs/php_codesniffer/bin/phpcs",
"csfix": "@php ./vendor/bin/phpcbf",
"pu": "@php ./vendor/bin/phpunit",
+ "coverage": "@php ./vendor/bin/phpunit --coverage-html tmp --coverage-clover clover.xml",
"qa": [
"@cs",
"@pu"
diff --git a/phpunit.xml.dist b/phpunit.xml.dist
index 9f2e85d..0fa9424 100755
--- a/phpunit.xml.dist
+++ b/phpunit.xml.dist
@@ -15,10 +15,4 @@
src
-
-
-
-
-
-
diff --git a/tests/phpunit/Unit/MarksimpleTest.php b/tests/phpunit/Unit/MarksimpleTest.php
index 4ab2cd0..9207cb3 100755
--- a/tests/phpunit/Unit/MarksimpleTest.php
+++ b/tests/phpunit/Unit/MarksimpleTest.php
@@ -19,15 +19,15 @@ class MarksimpleTest extends AbstractTestCase
*
* @var string
*/
- protected $noReadableFile = __DIR__ . '/./no_readable_file.txt';
+ protected $noReadableFile = '';
/**
- * Set up environment with adding unreadable file
+ * Set up environment with adding unreadable file in the system temp directory
*/
public function setUp():void
{
- touch($this->noReadableFile);
- chmod($this->noReadableFile, 27);
+ $this->noReadableFile = (string) tempnam(sys_get_temp_dir(), 'no_readable_file_');
+ chmod($this->noReadableFile, 0000);
}
/**
@@ -35,6 +35,7 @@ public function setUp():void
*/
public function tearDown():void
{
+ chmod($this->noReadableFile, 0600);
unlink($this->noReadableFile);
}