ldc-mesbr-app/tests/Unit/Domain/Models/ValueObjects/PrintableCoupon/PrintedCouponIdTest.php
2026-10-14 14:29:06 +02:00

28 lines
722 B
PHP

<?php
declare(strict_types=1);
namespace Tests\Unit\Domain\Models\ValueObjects\PrintableCoupon;
use Domain\Models\ValueObjects\PrintableCoupon\PrintedCouponId;
covers(PrintedCouponId::class);
describe('printed coupon id', function (): void {
it('generates a unique campaign id', function (): void {
// WHEN
$id = PrintedCouponId::generate();
// THEN
expect($id)->toBeInstanceOf(PrintedCouponId::class);
});
it('generates different ids on each call', function (): void {
// WHEN
$first = PrintedCouponId::generate();
$second = PrintedCouponId::generate();
// THEN
expect((string) $first)->not->toBe((string) $second);
});
});