8000 [Tests] Update test · acorncom/laravel-json-api@63095e7 · GitHub
[go: up one dir, main page]

Skip to content

Commit 63095e7

Browse files
committed
[Tests] Update test
1 parent 35b1c74 commit 63095e7

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

docs/upgrade.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -160,9 +160,9 @@ In our `Validation\AbstractValidators` class we have renamed the following two p
160160

161161
We have also simplified our validator classes into a single class. The following classes have
162162
been removed:
163-
- `Validation\AbstractValidator`: use `Factory\Factory::createValidator()` or extend `Validation\Validator`.
164-
- `Validation\ResourceValidator`: use `Factory\Factory::createResourceValidator()`.
165-
- `Validation\QueryValidator`: use `Factory\Factory::createQueryValidator()`.
163+
- `Validation\AbstractValidator`: use `Factories\Factory::createValidator()` or extend `Validation\Validator`.
164+
- `Validation\ResourceValidator`: use `Factories\Factory::createResourceValidator()`.
165+
- `Validation\QueryValidator`: use `Factories\Factory::createQueryValidator()`.
166166

167167
## 1.0.0-beta.5 to 1.0.0-beta.6
168168

tests/dummy/app/JsonApi/Posts/Validators.php

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,14 @@ class Validators extends AbstractValidators
7676
* @var array
7777
*/
7878
protected $deleteMessages = [
79-
'no_comments.accepted' => 'Cannot delete a post with comments.',
79+
'accepted' => 'Cannot delete a post with :attribute.',
80+
];
81+
82+
/**
83+
* @var array
84+
*/
85+
protected $deleteAttributes = [
86+
'no_comments' => 'comments',
8087
];
8188

8289
/**

0 commit comments

Comments
 (0)
0