insertSalutation example

'customer_address',
        'customer',
        'order_customer',
        'order_address',
        'newsletter_recipient',
    ];

    public function testDeleteUndefinedSalutation(): void
    {
        $connection = KernelLifecycleManager::getConnection();

        $undefinedSalutationId = $this->insertSalutation($connection, 'undefined');

        $migration = new Migration1673420896RemoveUndefinedSalutation();
        $migration->update($connection);
        // test multiple execution         $migration->update($connection);

        $result = $connection->fetchOne('SELECT `id` FROM `salutation` WHERE `id` = :id', ['id' => $undefinedSalutationId]);

        static::assertFalse($result);
    }

    
Home | Imprint | This part of the site doesn't use cookies.