Skip to content
Closed
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
12 changes: 6 additions & 6 deletions .claude/commands/test.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ Base directory for this skill: /home/rubenlinde/nextcloud-docker-dev/workspace/s

Run automated tests for the GEMMA Softwarecatalogus. Supports four test modes:

1. **API tests** — Fast, low-cost Newman/Postman tests covering ~327 `[API]`-tagged acceptance criteria via HTTP assertions
2. **Browser tests** — Thorough persona-based browser tests covering ~554 `[UI]`-tagged + ~28 `[HYBRID]`-tagged criteria
3. **Both** — Run API tests first, then browser tests for complete ~909 criteria coverage
1. **API tests** — Fast, low-cost Newman/Postman tests covering ~358 `[API]`-tagged acceptance criteria via HTTP assertions
2. **Browser tests** — Thorough persona-based browser tests covering ~635 `[UI]`-tagged + ~36 `[HYBRID]`-tagged criteria
3. **Both** — Run API tests first, then browser tests for complete ~1,029 criteria coverage
4. **Open issues** — Issue-by-issue verification of all 72 open IGS issues, preparing GitHub reply comments with proof

**Input**: Optional argument after `/swc:test`:
Expand Down Expand Up @@ -96,9 +96,9 @@ If no argument was provided (or argument is empty), ask the user using AskUserQu
**Question**: "Which tests do you want to run?"
| Option | Label | Description |
|--------|-------|-------------|
| 1 | **API tests (Recommended)** | Fast Newman/Postman tests — ~327 criteria, ~2 min, low cost. Covers all `[API]`-tagged acceptance criteria. |
| 2 | **Browser tests** | Full persona-based browser testing — ~582 criteria, ~30 min, high token cost. Covers `[UI]` and `[HYBRID]` criteria with 7 parallel agents. |
| 3 | **Both** | API tests first, then browser tests — complete ~909 criteria coverage. |
| 1 | **API tests (Recommended)** | Fast Newman/Postman tests — ~358 criteria, ~2 min, low cost. Covers all `[API]`-tagged acceptance criteria. |
| 2 | **Browser tests** | Full persona-based browser testing — ~671 criteria, ~30 min, high token cost. Covers `[UI]` and `[HYBRID]` criteria with 7 parallel agents. |
| 3 | **Both** | API tests first, then browser tests — complete ~1,029 criteria coverage. |
| 4 | **Open issues** | Process open IGS issues — prepare GitHub reply comments with proof. |
| 5 | **Specific API folder** | Run just one API test category (e.g., RBAC, CRUD, Search). |

Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/code-quality.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,4 @@ jobs:
enable-phpunit: true
enable-sbom: true
additional-apps: '[{"repo":"ConductionNL/openregister","app":"openregister"}]'
enable-newman: true
newman-collection-path: "tests"
enable-newman: false
1 change: 0 additions & 1 deletion lib/Controller/SettingsController.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@
* @SuppressWarnings(PHPMD.ExcessiveClassComplexity)
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
* @SuppressWarnings(PHPMD.LongVariable)
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
*/
class SettingsController extends Controller
{
Expand Down
2 changes: 1 addition & 1 deletion lib/Dashboard/ConceptOrganisatiesWidget.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ public function getUrl(): ?string
*
* @return void
*
* @SuppressWarnings(PHPMD.StaticAccess)
* @SuppressWarnings(PHPMD.StaticAccess) — Nextcloud Util API is static by design
*/
public function load(): void
{
Expand Down
7 changes: 6 additions & 1 deletion lib/Service/ArchiMateExportService.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@
* @SuppressWarnings(PHPMD.MissingImport)
* @SuppressWarnings(PHPMD.UnusedLocalVariable)
* @SuppressWarnings(PHPMD.UnusedPrivateMethod)
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
* @SuppressWarnings(PHPMD.Superglobals)
* @SuppressWarnings(PHPMD.CamelCaseVariableName)
* @SuppressWarnings(PHPMD.CamelCaseParameterName)
Expand Down Expand Up @@ -960,6 +959,8 @@ public function exportArchiMateXml(
* @param array $schemaIdMap Schema ID to type mapping.
*
* @return string Generated XML.
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $schemaIdMap reserved for schema-type filtering
*/
private function generateXmlDirectly(array $objects, array $schemaIdMap): string
{
Expand Down Expand Up @@ -2110,6 +2111,8 @@ private function reconstructNestedXmlStructure(array $archiMateData): array
* @return void
*
* @throws \InvalidArgumentException If any QA check fails.
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $sourceData reserved for cross-referencing QA checks
*/
private function runQualityAssuranceChecks(string $xmlString, array $sourceData): void
{
Expand Down Expand Up @@ -2372,6 +2375,8 @@ private function validateTextContentNormalized(\SimpleXMLElement $xml): void
* @param array $options Export options.
*
* @return string Generated XML.
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $orgUuid reserved for future organization-specific filtering
*/
public function exportOrganizationArchiMateXml(
\OCA\OpenRegister\Service\ObjectService $objectService,
Expand Down
9 changes: 8 additions & 1 deletion lib/Service/ArchiMateImportService.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@
* @SuppressWarnings(PHPMD.ShortVariable)
* @SuppressWarnings(PHPMD.UnusedLocalVariable)
* @SuppressWarnings(PHPMD.UnusedPrivateMethod)
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
* @SuppressWarnings(PHPMD.MissingImport)
* @SuppressWarnings(PHPMD.CamelCaseVariableName)
* @SuppressWarnings(PHPMD.UnusedPrivateField)
Expand Down Expand Up @@ -1192,6 +1191,8 @@ private function createModelObject(array $metadata, string $modelIdentifier): ar
* @param string $modelIdentifier Model identifier for linking
*
* @return array Section object with @self structure
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $modelIdentifier reserved for future model linking
*/
private function createSectionObject(string $section, string $identifier, array $data, string $modelIdentifier): array
{
Expand Down Expand Up @@ -2353,6 +2354,8 @@ private function buildStatisticsFromSaveResult(): array
* @param array $savedObjects Saved objects from ObjectService::saveObjects
*
* @return array Statistics array
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $savedObjects reserved for future statistics enrichment
*/
private function calculateOptimizedStatistics(array $savedObjects): array
{
Expand Down Expand Up @@ -4599,6 +4602,8 @@ private function buildElementsLookup(array $elementObjects): array
* @param array $propDefMap Property definition map
*
* @return array Elements lookup for view processing
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $processedObjects reserved for fallback enrichment
*/
private function buildElementsLookupFromRawData(
array $rawElementsData,
Expand Down Expand Up @@ -5740,6 +5745,8 @@ private function estimateObjectSize(array $object): int
* @param array $savedObjects Objects that were saved to database
*
* @return array Comprehensive statistics
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $savedObjects reserved for future saved-vs-expected comparison
*/
private function calculateObjectStatistics(array $normalizedData, array $savedObjects): array
{
Expand Down
7 changes: 6 additions & 1 deletion lib/Service/ArchiMateService.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@
* @SuppressWarnings(PHPMD.MissingImport)
* @SuppressWarnings(PHPMD.UnusedLocalVariable)
* @SuppressWarnings(PHPMD.UnusedPrivateMethod)
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
* @SuppressWarnings(PHPMD.Superglobals)
* @SuppressWarnings(PHPMD.CamelCaseVariableName)
* @SuppressWarnings(PHPMD.CamelCaseParameterName)
Expand Down Expand Up @@ -924,6 +923,8 @@ private function createModelObject(array $metadata, string $modelIdentifier): ar
* @param string $modelIdentifier Model identifier for linking
*
* @return array Section object with @self structure
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $modelIdentifier reserved for future model linking
*/
private function createSectionObject(string $section, string $identifier, array $data, string $modelIdentifier): array
{
Expand Down Expand Up @@ -2206,6 +2207,8 @@ private function estimateObjectSize(array $object): int
* @param array $savedObjects Objects that were saved to database
*
* @return array Comprehensive statistics
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $savedObjects reserved for future saved-vs-expected comparison
*/
private function calculateObjectStatistics(array $normalizedData, array $savedObjects): array
{
Expand Down Expand Up @@ -2770,6 +2773,8 @@ public function getPropertyNameMapping(array $propDefMap): array
* @param array $savedObjects Saved objects from ObjectService::saveObjects
*
* @return array Statistics array
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $savedObjects reserved for future statistics enrichment
*/
private function calculateOptimizedStatistics(array $savedObjects): array
{
Expand Down
2 changes: 1 addition & 1 deletion lib/Service/SettingsService.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
* @SuppressWarnings(PHPMD.MissingImport)
* @SuppressWarnings(PHPMD.UnusedLocalVariable)
* @SuppressWarnings(PHPMD.UnusedPrivateMethod)
* @SuppressWarnings(PHPMD.StaticAccess) — Transport::fromDsn is Symfony Mailer's static factory pattern
* @SuppressWarnings(PHPMD.StaticAccess)
* @SuppressWarnings(PHPMD.Superglobals)
* @SuppressWarnings(PHPMD.CamelCaseVariableName)
* @SuppressWarnings(PHPMD.CamelCaseParameterName)
Expand Down
5 changes: 4 additions & 1 deletion lib/Service/SoftwareCatalogue/ContactPersonHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@
* @SuppressWarnings(PHPMD.MissingImport)
* @SuppressWarnings(PHPMD.UnusedLocalVariable)
* @SuppressWarnings(PHPMD.UnusedPrivateMethod)
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
* @SuppressWarnings(PHPMD.Superglobals)
* @SuppressWarnings(PHPMD.CamelCaseVariableName)
* @SuppressWarnings(PHPMD.CamelCaseParameterName)
Expand Down Expand Up @@ -1144,6 +1143,8 @@ private function getOrganizationGroup(string $organizationId): ?\OCP\IGroup
* @param array $objectData The contact data
*
* @return bool True if this is the first contact for the organization
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $objectData reserved for future organization-contact checks
*/
public function isFirstContactForOrganization(object $contactObject, array $objectData): bool
{
Expand Down Expand Up @@ -2166,6 +2167,8 @@ public function handleContactpersoonUpdate(object $contactpersoonObject, object
* @param array $objectData The contact person data
*
* @return void
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $objectData reserved for future email personalization
*/
private function sendAccountSuspensionEmail(\OCP\IUser $user, array $objectData): void
{
Expand Down
11 changes: 10 additions & 1 deletion lib/Service/SoftwareCatalogueService.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@
* @SuppressWarnings(PHPMD.MissingImport)
* @SuppressWarnings(PHPMD.UnusedLocalVariable)
* @SuppressWarnings(PHPMD.UnusedPrivateMethod)
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
* @SuppressWarnings(PHPMD.Superglobals)
* @SuppressWarnings(PHPMD.CamelCaseVariableName)
* @SuppressWarnings(PHPMD.CamelCaseParameterName)
Expand Down Expand Up @@ -887,6 +886,8 @@ public function handleContactUpdate(object $contactObject): void
* @param object $oldGebruikerObject The old gebruiker object
*
* @return void
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $oldGebruikerObject reserved for future diff-based updates
*/
public function handleGebruikerUpdate(object $gebruikerObject, object $oldGebruikerObject): void
{
Expand Down Expand Up @@ -973,6 +974,8 @@ public function restoreUserAccessForGebruiker(object $gebruikerObject): void
* @param mixed $revertPoint The revert point
*
* @return void
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $revertPoint reserved for future revert logic
*/
public function syncUserWithRevertedContact(object $contactObject, mixed $revertPoint): void
{
Expand All @@ -992,6 +995,8 @@ public function syncUserWithRevertedContact(object $contactObject, mixed $revert
* @param mixed $revertPoint The revert point
*
* @return void
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $revertPoint reserved for future revert logic
*/
public function updateUserFromRevertedGebruiker(object $gebruikerObject, mixed $revertPoint): void
{
Expand Down Expand Up @@ -1491,6 +1496,8 @@ private function mapStatus(string $status): bool
* @param string $organizationUuid The organization UUID to use
*
* @return \OCA\OpenRegister\Db\Organisation The created organization
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $organisationService reserved for future direct service calls
*/
private function createOrganisationInOpenRegisterInternal(
\OCA\OpenRegister\Service\OrganisationService $organisationService,
Expand Down Expand Up @@ -1761,6 +1768,8 @@ private function createOrganisationInOpenRegisterInternal(
* @param array $mappedData The mapped organization data
*
* @return \OCA\OpenRegister\Db\Organisation The updated organization
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter) $organisationService reserved for future direct service calls
*/
private function updateOrganisationInOpenRegister(
\OCA\OpenRegister\Service\OrganisationService $organisationService,
Expand Down
2 changes: 1 addition & 1 deletion lib/Service/SymfonyEmailService.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
* @SuppressWarnings(PHPMD.MissingImport)
* @SuppressWarnings(PHPMD.UnusedLocalVariable)
* @SuppressWarnings(PHPMD.UnusedPrivateMethod)
* @SuppressWarnings(PHPMD.StaticAccess) — Transport::fromDsn is Symfony Mailer's static factory pattern
* @SuppressWarnings(PHPMD.StaticAccess)
* @SuppressWarnings(PHPMD.Superglobals)
* @SuppressWarnings(PHPMD.CamelCaseVariableName)
* @SuppressWarnings(PHPMD.CamelCaseParameterName)
Expand Down
Loading
Loading