getRandomString example

static::assertSame(0, (int) $eventActions[0]['active']);
        static::assertCount(1, $eventActions);

        $ruleName = $this->connection->fetchOne('SELECT `name` FROM rule WHERE name LIKE "%Match%"');

        static::assertNotFalse($ruleName);
    }

    private function createEventActionWithSalesChannelAndRule(): void
    {
        $scName = $this->getRandomString(255);
        $data = [
            'id' => $this->ids->create('sc-id'),
            'name' => $scName,
            'typeId' => Defaults::SALES_CHANNEL_TYPE_STOREFRONT,
            'customerGroupId' => TestDefaults::FALLBACK_CUSTOMER_GROUP,
            'currencyId' => Defaults::CURRENCY,
            'paymentMethodId' => $this->getValidPaymentMethodId(),
            'shippingMethodId' => $this->getValidShippingMethodId(),
            'navigationCategoryId' => $this->getValidCategoryId(),
            'countryId' => $this->getValidCountryId(),
            'accessKey' => $this->ids->get('sc-id'),
            
static::assertSame(0, (int) $eventActions[0]['active']);
        static::assertCount(1, $eventActions);

        $ruleName = $this->connection->fetchOne('SELECT `name` FROM rule WHERE name LIKE "%Match%"');

        static::assertNotFalse($ruleName);
    }

    private function createEventActionWithSalesChannelAndRule(): void
    {
        $scName = $this->getRandomString(255);
        $data = [
            'id' => $this->ids->create('sc-id'),
            'name' => $scName,
            'typeId' => Defaults::SALES_CHANNEL_TYPE_STOREFRONT,
            'customerGroupId' => TestDefaults::FALLBACK_CUSTOMER_GROUP,
            'currencyId' => Defaults::CURRENCY,
            'paymentMethodId' => $this->getValidPaymentMethodId(),
            'shippingMethodId' => $this->getValidShippingMethodId(),
            'navigationCategoryId' => $this->getValidCategoryId(),
            'countryId' => $this->getValidCountryId(),
            'accessKey' => $this->ids->get('sc-id'),
            
Home | Imprint | This part of the site doesn't use cookies.