Checks: Difference between revisions
From Sunhill Framework Documentation
→The check command: +Artisan commands |
+Category |
||
Line 28: | Line 28: | ||
... | ... | ||
} | } | ||
[[Category:Checks]] |
Revision as of 07:14, 7 October 2024
This page is incomplete |
Checks are an unified way to perform sanity checks on the installed system. Initially developed to check if the database tables are consistent you can check all kinds of sanity.
The check command
The framework defines a artisan command called check
. It is called via
./artisan check
Note that you have to replace artisan
with the name of your artisan application.
The check command has one parameter:
./artisan check --repair
This tells the check not just to report an inconsistency but also to try to repair it.
Also see Artisan commands.
Writing own checks
To write your own check just create a class with Sunhill\Basic\Checker\Checker
as ancestor.
<?php use Sunhill\Basic\Checker\Checker; class MyCheck extends Checker { ... }