<?php

/*
 * This file is part of the VITICORE2 package.
 *
 * (c) CP Creation <web@cpcreation.fr>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace CpCreation\VitiCore\Tests\Cart;

use PHPUnit\Framework\TestCase;

final class OrderPriceGroupVisibilityTest extends TestCase
{
    public function testOrderAdminDisplaysTheAppliedPriceGroupSnapshot(): void
    {
        $template = file_get_contents(\dirname(__DIR__, 2).'/src/Bridge/Symfony/Bundle/Resources/views/admin/order/order.html.twig');

        self::assertIsString($template);
        self::assertStringContainsString('pricing.priceGroupName', $template);
        self::assertStringContainsString("'order.price_group'|trans", $template);
        self::assertStringContainsString("'order.partner_code'|trans", $template);
        self::assertStringContainsString('cart.groupCode', $template);
    }
}
