41 Commits
Author SHA1 Message Date
Ehsan MahmoodiandDan Harrin ba2d2e96d8 docs: replace deprecated assertFormExists with assertSchemaExists (#19365)
* docs: replace deprecated assertFormExists with assertSchemaExists

* Update assertSchemaExists usage in documentation

Signed-off-by: Dan Harrin <git@danharrin.com>

---------

Signed-off-by: Dan Harrin <git@danharrin.com>
Co-authored-by: Dan Harrin <git@danharrin.com>
2026-02-27 11:04:23 +00:00
Florian RaithandDan Harrin 2a8807fd3a Fix deprecation description (#19362)
* Update .stubs.php

Signed-off-by: Florian Raith <37345813+florianraith@users.noreply.github.com>

* Update 05-testing-actions.md

---------

Signed-off-by: Florian Raith <37345813+florianraith@users.noreply.github.com>
Co-authored-by: Dan Harrin <git@danharrin.com>
2026-02-27 11:00:35 +00:00
Cole Shirley 922652d5c1 Set current panel to 'admin' in testing resources (#19315)
Signed-off-by: Cole Shirley <84236864+coleshirley@users.noreply.github.com>
2026-02-23 08:23:41 +00:00
Dan Harrin 15866b910b fix: Missing schema visibility testing methods (#19191)
* fix: Missing schema visibility testing methods

* Update 04-testing-schemas.md
2026-02-03 22:01:13 +00:00
Cole ShirleyandDan Harrin ae66943b25 [4.x] Document testing for multi-tenant panels (#18924)
* Document testing for multi-tenant panels

Added instructions for testing resources in multi-tenant panels.

Signed-off-by: Cole Shirley <84236864+coleshirley@users.noreply.github.com>

* typo

Signed-off-by: Cole Shirley <84236864+coleshirley@users.noreply.github.com>

* Refactor Filament panel initialization in testing docs

Signed-off-by: Cole Shirley <84236864+coleshirley@users.noreply.github.com>

* Update 02-testing-resources.md

Signed-off-by: Dan Harrin <git@danharrin.com>

---------

Signed-off-by: Cole Shirley <84236864+coleshirley@users.noreply.github.com>
Signed-off-by: Dan Harrin <git@danharrin.com>
Co-authored-by: Dan Harrin <git@danharrin.com>
2026-01-15 11:39:48 +00:00
Dan Harrin 20f74b57db Update 02-testing-resources.md 2025-11-30 18:28:51 +00:00
Angus McRitchie ce1ee16bcf fixed various typos in docs (#18548) 2025-11-20 11:18:05 +00:00
PatrickandDan Harrin 258b7d44aa Correct the link to the schemas testing page (#18355)
* Update 01-overview.md

Correct the link to the schemas testing page

Signed-off-by: Patrick <privat@skyraptor.eu>

* Update 01-overview.md

---------

Signed-off-by: Patrick <privat@skyraptor.eu>
Co-authored-by: Dan Harrin <git@danharrin.com>
2025-10-30 10:47:41 -04:00
Craig PotterandDan Harrin 2d9d17e636 Update component type in schema test documention (#18332)
* Update component type in schema tests

Signed-off-by: Craig Potter <me@craigpotter.co.uk>

* Update docs/10-testing/04-testing-schemas.md

Signed-off-by: Dan Harrin <git@danharrin.com>

---------

Signed-off-by: Craig Potter <me@craigpotter.co.uk>
Signed-off-by: Dan Harrin <git@danharrin.com>
Co-authored-by: Dan Harrin <git@danharrin.com>
2025-10-29 10:14:09 -04:00
Dennis KochandDan Harrin f25ec70c29 [4.x] Mounted action modal test helpers (#18195)
* Mounted action modal test helpers

* docs: Update modal content assertions

* Code style

* Add stubs and fix phpstan

* Get partial html from nested actions

* Remove getMountedActionModalHtml method

Removed internal helper method for modal content.

Signed-off-by: Dan Harrin <git@danharrin.com>

* Refactor getMountedActionModalHtml method

Signed-off-by: Dan Harrin <git@danharrin.com>

---------

Signed-off-by: Dan Harrin <git@danharrin.com>
Co-authored-by: Dan Harrin <git@danharrin.com>
2025-10-14 09:52:12 +01:00
BenandDan Harrin c8abd63422 Add toggle all columns for testing (#18013)
* Toggle all table columns

* Add docs for toggling all columns

* chore: fix code style

* clean up

---------

Co-authored-by: Dan Harrin <git@danharrin.com>
2025-10-04 14:14:49 +01:00
d91c365104 Update testing form actions docs with new form-actions key (#17887)
* updates docs

* Update 05-testing-actions.md

* Document testing create and edit form actions

Added sections for testing create and edit form actions using TestAction in the documentation.

* Modifies action section to essentially a footnote

Removed example code for testing form actions and updated references to documentation for testing create and edit form actions.

* clean up and reduce duplication

---------

Co-authored-by: mrkbingham <mark.bingham@interworks.com>
Co-authored-by: Dan Harrin <git@danharrin.com>
2025-09-24 17:27:52 +01:00
Dan Harrin 84288a89b1 Add Aside component import to testing tables doc 2025-09-22 08:34:13 +01:00
MerdinandDan Harrin 22fc471a80 Update 03-testing-tables.md - "Testing that a column can be sorted" (#17871)
* Issue #17817: Update 03-testing-tables.md - "Testing that a column can be sorted"

Currently, the documentation includes a flaky test as an example for sorting a column. This is because Filament sorts its table records according to the underlying database strategy.

Previously, the documentation suggested using the `sortBy()` method on the collection returned by the factory. However, this approach does not account for differences in how various databases handle sorting, which can lead to inconsistent test results.

With this commit, the documentation has been updated.
The example test now uses a stable approach that explicitly orders records through the database query, ensuring reliable behavior across different database systems.

Signed-off-by: Merdin <me@merdin.dev>

* Update 03-testing-tables.md - "Testing that a column can be sorted"

Improve query

Signed-off-by: Merdin <me@merdin.dev>

* Update 03-testing-tables.md

Change `orderBy('title', 'desc')` to `orderByDesc('title')` to improve code readability.

Signed-off-by: Merdin <me@merdin.dev>

* Update 03-testing-tables.md

Signed-off-by: Merdin <me@merdin.dev>

* Refactor post sorting in test to use query builder

Signed-off-by: Dan Harrin <git@danharrin.com>

* Fix sorting order for posts by title

Signed-off-by: Dan Harrin <git@danharrin.com>

---------

Signed-off-by: Merdin <me@merdin.dev>
Signed-off-by: Dan Harrin <git@danharrin.com>
Co-authored-by: Dan Harrin <git@danharrin.com>
2025-09-20 12:46:02 +01:00
M. D. 3791361412 docs: Fixes syntax error 2025-09-17 03:18:34 +02:00
Dan Harrin de62176c47 Update 04-testing-schemas.md 2025-09-03 11:32:50 +01:00
M. D. 4c5e6df349 Refactor comments section tests for schema components
The shown example would lead to an error:

```php
 Livewire\Features\SupportTesting\Testable::{closure:Filament\Schemas\Testing\TestsSchemas::assertSchemaComponentExists():25}(): Argument #2 ($schema) must be of type ?string, Closure given,
```

because the 2nd parameter is expected to be a `Schema`

I suppose there is two options now, adding `null` as 2nd parameter in the examples or simply using named arguments. Named arguments looked like the better approach 😊
2025-09-03 12:21:07 +02:00
phuong 90e01dad19 Fix spelling errors in 4.x docs 2025-07-05 20:06:28 +07:00
Patrick Boivin b51f4eb91f Update 04-testing-schemas.md 2025-06-17 12:03:01 -04:00
Dan Harrin 0ebba01802 Update 04-testing-schemas.md 2025-06-12 10:33:41 +01:00
Dan Harrin e386bcd419 resources tests 2025-04-22 10:21:37 +01:00
Dan Harrin 60d161f8e9 more testing improvements 2025-04-21 22:46:49 +01:00
Dan Harrin 12d02a96b6 rename assertSchemaSet to assertSchemaStateSet 2025-04-21 17:22:29 +01:00
Dan Harrin e20addfbf2 Update 01-overview.md 2025-04-21 17:09:39 +01:00
Dan Harrin 1d36322c74 testing overview docs 2025-04-21 17:04:26 +01:00
Dan Harrin 764253860b update docs links 2025-04-21 16:55:45 +01:00
Dan Harrin 95dc1929ab testing repeaters and builders 2025-04-21 16:50:33 +01:00
Dan Harrin 9e72a8b15b Update 04-testing-schemas.md 2025-04-21 16:48:54 +01:00
Dan Harrin 63a0e4a99e docs 2025-04-21 16:48:26 +01:00
Dan Harrin 3ba4407251 restructure testing docs 2025-04-21 16:46:29 +01:00
Dan Harrin 0d4c2511d3 Replace old usages of methods 2025-04-21 16:20:10 +01:00
Dan Harrin 49522f4b64 replace old methods 2025-04-21 16:09:03 +01:00
Dan Harrin e8e764ef7f Update 05-testing-actions.md 2025-04-21 15:24:09 +01:00
Dan Harrin 6769deb392 assertSchemaSet 2025-04-21 13:01:26 +01:00
Dan Harrin eb7e735b76 Update 05-testing-actions.md 2025-04-21 11:55:28 +01:00
Dan Harrin 15f6e95766 work on testing 2025-04-21 11:15:32 +01:00
Dan Harrin e3bf27d301 testing 2025-04-20 10:57:00 +01:00
Dan Harrin f9a6d512b8 make overview/intro headings consistent 2025-03-17 11:13:14 +00:00
Dan Harrin 7701a1b99a docs 2025-03-06 10:30:52 +00:00
Dan Harrin 51b02920f2 move fields and entries docs into schemas 2025-02-23 09:03:19 +00:00
Dan Harrin d4a3e0b538 wip 2025-02-22 19:19:00 +00:00