EnvironmentRequirementsValidator example



        $composer = $this->createMock(Composer::class);
        $composer->method('getRepositoryManager')->willReturn($repoManagerMock);

        if ($coreComposerName) {
            $composer->expects(static::never())->method('getPackage');
        } else {
            $composer->expects(static::once())->method('getPackage')->willReturn($corePackage);
        }

        $validator = new EnvironmentRequirementsValidator($composer$systemEnvironment);

        $checks = new RequirementsCheckCollection();

        static::assertEquals($expectedChecks$validator->validateRequirements($checks)->getElements());
    }

    public static function composerRequirementsProvider(): \Generator
    {
        $versionParser = new VersionParser();

        yield 'platform repo with satisfied requirement' => [
            
Home | Imprint | This part of the site doesn't use cookies.