fix: patch remaining lib/ references missed in core/ rename
CliAppBootstrap and ModuleCliRuntime still required from the old lib/ path, which would break all CLI commands. Also fixes stale lib/ references in docs, test assertion messages, and a PHPDoc comment. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -30,10 +30,10 @@ final class CliAppBootstrap
|
||||
|
||||
require_once $projectRoot . '/vendor/autoload.php';
|
||||
require_once $projectRoot . '/config/config.php';
|
||||
require_once $projectRoot . '/lib/Support/helpers.php';
|
||||
require_once $projectRoot . '/core/Support/helpers.php';
|
||||
|
||||
/** @var AppContainer $container */
|
||||
$container = require $projectRoot . '/lib/App/registerContainer.php';
|
||||
$container = require $projectRoot . '/core/App/registerContainer.php';
|
||||
setAppContainer($container);
|
||||
|
||||
self::$container = $container;
|
||||
|
||||
@@ -30,9 +30,9 @@ final class ModuleCliRuntime
|
||||
|
||||
require_once $projectRoot . '/vendor/autoload.php';
|
||||
require_once $projectRoot . '/config/config.php';
|
||||
require_once $projectRoot . '/lib/Support/helpers.php';
|
||||
require_once $projectRoot . '/core/Support/helpers.php';
|
||||
|
||||
$container = require $projectRoot . '/lib/App/registerContainer.php';
|
||||
$container = require $projectRoot . '/core/App/registerContainer.php';
|
||||
setAppContainer($container);
|
||||
|
||||
self::$booted = true;
|
||||
|
||||
@@ -131,7 +131,7 @@ Struktur-Gates zusätzlich:
|
||||
```bash
|
||||
(rg 'new\s+[^\s(]+Factory\(' core/Service || true) | wc -l
|
||||
(rg --glob '!**/*Factory.php' 'new\s+[^\s(]+(Service|Gateway|Repository)\(' core/Service || true) | wc -l
|
||||
(rg "\b(accessServicesFactory|directoryServicesFactory|userServicesFactory|authServicesFactory|tenantServicesFactory|settingServicesFactory|userRepositoryFactory|authRepositoryFactory|authGatewayFactory)\(" pages lib templates web || true) | wc -l
|
||||
(rg "\b(accessServicesFactory|directoryServicesFactory|userServicesFactory|authServicesFactory|tenantServicesFactory|settingServicesFactory|userRepositoryFactory|authRepositoryFactory|authGatewayFactory)\(" pages core templates web || true) | wc -l
|
||||
(rg -n 'new\s+[^\s(]+(Service|Gateway|Repository)\(' pages -g '*.php' || true) | wc -l
|
||||
(rg -n '\bDB::' pages -g '*.php' || true) | wc -l
|
||||
(rg -n 'app\([^\n]*Factory::class\)->create' pages/admin -g '*.php' || true) | wc -l
|
||||
|
||||
@@ -70,7 +70,7 @@ final class AddressBookModuleIsolationContractTest extends TestCase
|
||||
$coreServiceDir = dirname(__DIR__, 2) . '/core/Service/AddressBook';
|
||||
self::assertDirectoryDoesNotExist(
|
||||
$coreServiceDir,
|
||||
'Addressbook service classes should live in modules/addressbook/lib, not in Core lib/Service'
|
||||
'Addressbook service classes should live in modules/addressbook/lib, not in core/Service'
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -46,7 +46,7 @@ final class AuditModuleIsolationContractTest extends TestCase
|
||||
$root = dirname(__DIR__, 2);
|
||||
self::assertDirectoryDoesNotExist(
|
||||
$root . '/core/Repository/Audit',
|
||||
'Audit repository classes should live in modules/audit/lib, not in Core core/Repository/Audit'
|
||||
'Audit repository classes should live in modules/audit/lib, not in core/Repository/Audit'
|
||||
);
|
||||
}
|
||||
|
||||
@@ -63,7 +63,7 @@ final class AuditModuleIsolationContractTest extends TestCase
|
||||
self::assertSame(
|
||||
[],
|
||||
array_values($auditFiles),
|
||||
'Core lib/Domain/Taxonomy/ still contains audit enum files: ' . implode(', ', $auditFiles)
|
||||
'core/Domain/Taxonomy/ still contains audit enum files: ' . implode(', ', $auditFiles)
|
||||
);
|
||||
}
|
||||
|
||||
@@ -91,7 +91,7 @@ final class AuditModuleIsolationContractTest extends TestCase
|
||||
$root = dirname(__DIR__, 2);
|
||||
self::assertFileDoesNotExist(
|
||||
$root . '/core/Http/ApiSystemAuditReporter.php',
|
||||
'ApiSystemAuditReporter should live in modules/audit/lib, not in Core lib/Http'
|
||||
'ApiSystemAuditReporter should live in modules/audit/lib, not in core/Http'
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@ final class BookmarksModuleIsolationContractTest extends TestCase
|
||||
$root = dirname(__DIR__, 2);
|
||||
self::assertDirectoryDoesNotExist(
|
||||
$root . '/core/Service/Bookmark',
|
||||
'Bookmark service classes should live in modules/bookmarks/lib, not in Core lib/Service'
|
||||
'Bookmark service classes should live in modules/bookmarks/lib, not in core/Service'
|
||||
);
|
||||
}
|
||||
|
||||
@@ -70,7 +70,7 @@ final class BookmarksModuleIsolationContractTest extends TestCase
|
||||
$root = dirname(__DIR__, 2);
|
||||
self::assertFileDoesNotExist(
|
||||
$root . '/core/Support/BookmarkUrlNormalizer.php',
|
||||
'BookmarkUrlNormalizer should live in modules/bookmarks/lib, not in Core lib/Support'
|
||||
'BookmarkUrlNormalizer should live in modules/bookmarks/lib, not in core/Support'
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -64,7 +64,7 @@ class CoreStarterkitContractTest extends TestCase
|
||||
|
||||
foreach ($patterns as $pattern => $label) {
|
||||
$violations = $this->findPatternMatchesInPhpFiles('core/Service', $pattern);
|
||||
$this->assertSame([], $violations, "Superglobal {$label} usage found in lib/Service/:\n" . implode("\n", $violations));
|
||||
$this->assertSame([], $violations, "Superglobal {$label} usage found in core/Service/:\n" . implode("\n", $violations));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ namespace MintyPHP\Tests\Architecture;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
/**
|
||||
* GR-SEC-005: All encryption/decryption MUST use lib/Support/Crypto.php.
|
||||
* GR-SEC-005: All encryption/decryption MUST use core/Support/Crypto.php.
|
||||
* No raw openssl_encrypt/decrypt calls outside that single file.
|
||||
*/
|
||||
class SecurityCryptoContractTest extends TestCase
|
||||
|
||||
@@ -124,6 +124,6 @@ class ErrorHandlerTest extends TestCase
|
||||
putenv('APP_VENDOR_PHP_ISSUES_MODE=suppress_deprecations_warnings');
|
||||
|
||||
$this->expectException(\ErrorException::class);
|
||||
ErrorHandler::handleError(E_WARNING, 'warning', '/var/www/lib/Http/ErrorHandler.php', 69);
|
||||
ErrorHandler::handleError(E_WARNING, 'warning', '/var/www/core/Http/ErrorHandler.php', 69);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user