DumpSchemaCommand example

/** * @internal * * @covers \Shopware\Core\Framework\Api\Command\DumpSchemaCommand */
class DumpSchemaCommandTest extends TestCase
{
    public function testSimpleCall(): void
    {
        $definitionService = $this->createMock(DefinitionService::class);
        $definitionService->expects(static::once())->method('getSchema');
        $cmd = new DumpSchemaCommand($definitionService);

        $cmd = new CommandTester($cmd);
        $cmd->execute(['outfile' => '-']['capture_stderr_separately' => true]);

        $cmd->assertCommandIsSuccessful();
        static::assertNotEmpty($cmd->getErrorOutput(), 'no status messages in stderr found');
    }

    public function testEntitySchema(): void
    {
        $definitionService = $this->createMock(DefinitionService::class);
        
Home | Imprint | This part of the site doesn't use cookies.