Skip to content

Commit f9a4271

Browse files
committed
refactor: change notation type in methods
The notation type in the test function names has been changed from camel to snake case for readability. Closes #3
1 parent e261015 commit f9a4271

File tree

1 file changed

+15
-13
lines changed

1 file changed

+15
-13
lines changed

tests/HttpStatusCodeTest.php

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
11
<?php
22

33
/*
4-
* This file is part of https://github.com/josantonius/php-http-status-code repository.
5-
*
6-
* (c) Josantonius <hello@josantonius.dev>
7-
*
8-
* For the full copyright and license information, please view the LICENSE
9-
* file that was distributed with this source code.
10-
*/
4+
* This file is part of https://github.com/josantonius/php-http-status-code repository.
5+
*
6+
* (c) Josantonius <hello@josantonius.dev>
7+
*
8+
* For the full copyright and license information, please view the LICENSE
9+
* file that was distributed with this source code.
10+
*
11+
* @phpcs:disable PSR1.Methods.CamelCapsMethodName.NotCamelCaps
12+
*/
1113

1214
namespace Josantonius\HttpStatusCode\Tests;
1315

@@ -29,14 +31,14 @@ public function setUp(): void
2931
$this->httpStatusCodeEs = new HttpStatusCode('es');
3032
}
3133

32-
public function testShouldFailIfUnsupportedLanguageIsUsed()
34+
public function test_should_fail_if_unsupported_language_is_used()
3335
{
3436
$this->expectException(UnsupportedLanguageException::class);
3537

3638
new HttpStatusCode('fr');
3739
}
3840

39-
public function testShouldGetMessage()
41+
public function test_should_get_message()
4042
{
4143
$this->assertEquals(
4244
'Request Time-out',
@@ -49,15 +51,15 @@ public function testShouldGetMessage()
4951
);
5052
}
5153

52-
public function testShouldGetMessages()
54+
public function test_should_get_messages()
5355
{
5456
$messages = $this->httpStatusCodeEn->getMessages();
5557

5658
$this->assertIsArray($messages);
5759
$this->assertArrayHasKey(408, $messages);
5860
}
5961

60-
public function testShouldGetDefinition()
62+
public function test_should_get_definition()
6163
{
6264
$this->assertStringContainsString(
6365
'The server timed out waiting for the request.',
@@ -70,15 +72,15 @@ public function testShouldGetDefinition()
7072
);
7173
}
7274

73-
public function testShouldGetDefinitions()
75+
public function test_should_get_definitions()
7476
{
7577
$definitions = $this->httpStatusCodeEn->getDefinitions();
7678

7779
$this->assertIsArray($definitions);
7880
$this->assertArrayHasKey(408, $definitions);
7981
}
8082

81-
public function testShouldGetAll()
83+
public function test_should_get_all()
8284
{
8385
$all = $this->httpStatusCodeEn->getAll();
8486

0 commit comments

Comments
 (0)