test(config): align current odds and settlement contracts
This commit is contained in:
@@ -1,19 +1,26 @@
|
||||
<?php
|
||||
|
||||
use App\Models\AdminUser;
|
||||
use App\Models\Draw;
|
||||
use App\Models\Player;
|
||||
use App\Models\AdminUser;
|
||||
use App\Lottery\DrawStatus;
|
||||
use Illuminate\Foundation\Testing\RefreshDatabase;
|
||||
use Illuminate\Support\Carbon;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Illuminate\Support\Facades\Hash;
|
||||
use Illuminate\Foundation\Testing\RefreshDatabase;
|
||||
use App\Services\AgentSettlement\SettlementPeriodOpenHintsService;
|
||||
|
||||
uses(RefreshDatabase::class);
|
||||
|
||||
beforeEach(function (): void {
|
||||
Carbon::setTestNow('2026-07-09 12:00:00');
|
||||
$this->artisan('lottery:admin-auth-sync')->assertExitCode(0);
|
||||
});
|
||||
|
||||
afterEach(function (): void {
|
||||
Carbon::setTestNow();
|
||||
});
|
||||
|
||||
test('settlement period open hints api resource is configured after migrations', function (): void {
|
||||
expect(
|
||||
DB::table('admin_api_resources')
|
||||
@@ -295,7 +302,7 @@ test('settlement period open hints uses site timezone for orphan activity dates'
|
||||
'updated_at' => '2026-07-09 18:00:00',
|
||||
]);
|
||||
|
||||
$hints = app(\App\Services\AgentSettlement\SettlementPeriodOpenHintsService::class)->hints($siteId);
|
||||
$hints = app(SettlementPeriodOpenHintsService::class)->hints($siteId);
|
||||
|
||||
expect($hints['settlement_timezone'])->toBe('Asia/Kathmandu')
|
||||
->and($hints['occupied_period_dates'])->toContain('2026-07-09')
|
||||
|
||||
Reference in New Issue
Block a user