snipe-it/tests/Support/InteractsWithSettings.php

18 lines
305 B
PHP
Raw Normal View History

<?php
namespace Tests\Support;
use App\Models\Setting;
trait InteractsWithSettings
{
protected Settings $settings;
2023-05-01 16:06:28 -07:00
public function initializeSettings()
{
$this->settings = Settings::initialize();
$this->beforeApplicationDestroyed(fn() => Setting::$_cache = null);
}
}