Skip to content

Commit 490cc25

Browse files
driesvintsgithub-actions[bot]
authored andcommitted
Fix code styling
1 parent 3e0f400 commit 490cc25

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

tests/Integration/Rules/PasscheckRuleTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,12 @@
1111
$this->login(['password' => bcrypt('foo')]);
1212
$rule = new PasscheckRule;
1313

14-
$rule->validate('password', 'foo', fn () => throw new Exception());
14+
$rule->validate('password', 'foo', fn () => throw new Exception);
1515
})->throwsNoExceptions();
1616

1717
it('fails when the password is incorrect', function () {
1818
$this->login();
1919
$rule = new PasscheckRule;
2020

21-
$rule->validate('password', 'foo', fn () => throw new Exception());
21+
$rule->validate('password', 'foo', fn () => throw new Exception);
2222
})->throws(Exception::class);

tests/Unit/Rules/DoesNotContainUrlRuleTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@
33
use App\Rules\DoesNotContainUrlRule;
44

55
it('detects a url in a string', function () {
6-
(new DoesNotContainUrlRule())->validate('foo', 'This is a string http://example.com with an url in it.', fn () => throw new Exception());
6+
(new DoesNotContainUrlRule)->validate('foo', 'This is a string http://example.com with an url in it.', fn () => throw new Exception);
77
})->throws(Exception::class);
88

99
it('passes when no url is present', function () {
10-
(new DoesNotContainUrlRule())->validate('foo', 'This is a string without an url in it.', fn () => throw new Exception());
10+
(new DoesNotContainUrlRule)->validate('foo', 'This is a string without an url in it.', fn () => throw new Exception);
1111
})->throwsNoExceptions();
1212

1313
it('passes when extra spaces are present', function () {
14-
(new DoesNotContainUrlRule())->validate('foo', 'This is a string with extra spaces.', fn () => throw new Exception());
14+
(new DoesNotContainUrlRule)->validate('foo', 'This is a string with extra spaces.', fn () => throw new Exception);
1515
})->throwsNoExceptions();

tests/Unit/Rules/HttpImageRuleTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
use App\Rules\HttpImageRule;
44

55
it('passes when no http links are detected', function () {
6-
(new HttpImageRule())->validate('body', 'some text ![](https://link.com)', fn () => throw new Exception());
6+
(new HttpImageRule)->validate('body', 'some text ![](https://link.com)', fn () => throw new Exception);
77
})->throwsNoExceptions();
88

99
it('fails when http links are detected', function () {
10-
(new HttpImageRule())->validate('body', 'some text ![](http://link.com)', fn () => throw new Exception());
10+
(new HttpImageRule)->validate('body', 'some text ![](http://link.com)', fn () => throw new Exception);
1111
})->throws(Exception::class);

tests/Unit/Rules/InvalidMentionRuleTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
use App\Rules\InvalidMentionRule;
44

55
it('passes when no invalid mentions are detected', function ($body) {
6-
expect((new InvalidMentionRule())->validate('body', $body, fn () => throw new Exception()));
6+
expect((new InvalidMentionRule)->validate('body', $body, fn () => throw new Exception));
77
})->with([
88
'Hello, I\'m looking for some help',
99
'I\'ve seen [this link](https://example.com), is it legit?',
@@ -27,7 +27,7 @@
2727
])->throwsNoExceptions();
2828

2929
it('fails when invalid mentions are detected', function ($body) {
30-
expect((new InvalidMentionRule())->validate('body', $body, fn () => throw new Exception()));
30+
expect((new InvalidMentionRule)->validate('body', $body, fn () => throw new Exception));
3131
})->with([
3232
'[@driesvints](https://somethingnasty.com)',
3333
'Hey [@joedixon](https://somethingnasty.com), is it legit?',

0 commit comments

Comments
 (0)