Lint
This commit is contained in:
parent
3b63a73161
commit
10a966c6ad
|
@ -8,6 +8,7 @@ use Spatie\LaravelData\Data;
|
|||
class EditorData extends Data implements Editorable
|
||||
{
|
||||
|
||||
/** @param array<int, mixed> $blocks */
|
||||
public function __construct(
|
||||
public string $version,
|
||||
public array $blocks,
|
||||
|
@ -47,6 +48,9 @@ class EditorData extends Data implements Editorable
|
|||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array<int, string> $replacements
|
||||
*/
|
||||
public function replaceWithList(string $blockContent, array $replacements): self
|
||||
{
|
||||
$this->blocks = collect($this->blocks)->map(function ($block) use ($blockContent, $replacements) {
|
||||
|
|
|
@ -12,6 +12,9 @@ class SettingStoreAction
|
|||
{
|
||||
use AsAction;
|
||||
|
||||
/**
|
||||
* @return array<string, string>
|
||||
*/
|
||||
public function rules(): array
|
||||
{
|
||||
return [
|
||||
|
|
|
@ -6,6 +6,7 @@ parameters:
|
|||
|
||||
stubFiles:
|
||||
- tests/stub/phpstan/TestResponse.stub
|
||||
- tests/stub/phpstan/Settings.stub
|
||||
|
||||
paths:
|
||||
- app
|
||||
|
|
|
@ -21,6 +21,7 @@ use Worksome\RequestFactories\RequestFactory;
|
|||
* @method self isActive(bool $isActive)
|
||||
* @method self isPrivate(bool $isPrivate)
|
||||
* @method self export(ExportData $export)
|
||||
* @method self preventionText(EditorRequestFactory $text)
|
||||
*/
|
||||
class FormRequest extends RequestFactory
|
||||
{
|
||||
|
|
|
@ -131,7 +131,7 @@ class FormUpdateActionTest extends FormTestCase
|
|||
$this->login()->loginNami()->withoutExceptionHandling();
|
||||
$form = Form::factory()->create();
|
||||
$payload = FormRequest::new()
|
||||
->preventionText(EditorRequestFactory::new()->text(10, 'lorem ipsum')->create())
|
||||
->preventionText(EditorRequestFactory::new()->text(10, 'lorem ipsum'))
|
||||
->state(['needs_prevention' => true])
|
||||
->create();
|
||||
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
<?php
|
||||
|
||||
namespace Illuminate\Testing;
|
||||
|
||||
namespace Spatie\LaravelSettings;
|
||||
|
||||
/**
|
||||
* @method static refresh()
|
||||
*/
|
||||
abstract class Settings
|
||||
{
|
||||
}
|
Loading…
Reference in New Issue