3c2bb18537
- BalanceTransaction::TYPE_AUTOPODBOR_CHARGE = 'autopodbor_charge' - сид-миграция 4 ключей system_settings (idempotent): autopodbor_enabled (bool, 0), autopodbor_price_search_rub (decimal, 0), autopodbor_price_study_rub (decimal, 0), autopodbor_max_competitors (int, 15) - Unit + Feature тесты, оба PASS Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
14 lines
592 B
PHP
14 lines
592 B
PHP
<?php
|
|
|
|
use App\Support\SystemSettings;
|
|
use Illuminate\Foundation\Testing\DatabaseTransactions;
|
|
|
|
uses(DatabaseTransactions::class);
|
|
|
|
it('сид завёл ключи автоподбора', function () {
|
|
expect(SystemSettings::bool('autopodbor_enabled', true))->toBeFalse() // default OFF
|
|
->and(SystemSettings::get('autopodbor_max_competitors'))->toBe('15')
|
|
->and(\App\Models\SystemSetting::whereKey('autopodbor_price_search_rub')->exists())->toBeTrue()
|
|
->and(\App\Models\SystemSetting::whereKey('autopodbor_price_study_rub')->exists())->toBeTrue();
|
|
});
|