@@ -17,9 +17,9 @@ protected function setUp(): void
17
17
18
18
public function testValidFilePath ()
19
19
{
20
- $ this ->assertTrue (PapiMethods::validFilePath ($ this ->papi_dir . '/phpunit.xml ' ));
21
- $ this ->assertFalse (PapiMethods::validFilePath ($ this ->papi_dir . '/app ' ));
22
- $ this ->assertFalse (PapiMethods::validFilePath ($ this ->papi_dir . '/unknown ' ));
20
+ $ this ->assertTrue (PapiMethods::validFilePath ($ this ->papi_dir . '/phpunit.xml ' ));
21
+ $ this ->assertFalse (PapiMethods::validFilePath ($ this ->papi_dir . '/app ' ));
22
+ $ this ->assertFalse (PapiMethods::validFilePath ($ this ->papi_dir . '/unknown ' ));
23
23
}
24
24
25
25
public function testSpecTestDirectory ()
@@ -34,7 +34,7 @@ public function testSpecTestDirectory()
34
34
35
35
public function testScanDirRecursively ()
36
36
{
37
- $ files = PapiMethods::scandirRecursively (getcwd (). '/bin ' );
37
+ $ files = PapiMethods::scandirRecursively (getcwd () . '/bin ' );
38
38
39
39
$ this ->assertCount (1 , $ files );
40
40
$ this ->assertEquals ($ files [0 ], 'papi ' );
@@ -67,19 +67,19 @@ public function testValidExtension()
67
67
68
68
public function testSpecFilesInDir ()
69
69
{
70
- $ examples_dir = $ this ->papi_dir . '/examples ' ;
70
+ $ examples_dir = $ this ->papi_dir . '/examples ' ;
71
71
72
- $ files = PapiMethods::specFilesInDir ($ examples_dir. '/reference/PetStore ' , 'json ' );
73
- $ this ->assertCount (2 , $ files );
72
+ $ files = PapiMethods::specFilesInDir ($ examples_dir . '/reference/PetStore ' , 'json ' );
73
+ $ this ->assertCount (3 , $ files );
74
74
75
- $ files = PapiMethods::specFilesInDir ($ examples_dir. '/reference/PetStore ' , 'js ' );
75
+ $ files = PapiMethods::specFilesInDir ($ examples_dir . '/reference/PetStore ' , 'js ' );
76
76
$ this ->assertCount (0 , $ files );
77
77
}
78
78
79
79
public function testSpecNameAndVersion ()
80
80
{
81
- $ spec_file = $ this ->papi_dir . '/examples/reference/PetStore/PetStore.2021-07-23.json ' ;
82
-
81
+ $ spec_file = $ this ->papi_dir . '/examples/reference/PetStore/PetStore.2021-07-23.json ' ;
82
+
83
83
$ results = PapiMethods::specNameAndVersion ($ spec_file );
84
84
85
85
$ this ->assertEquals ($ results [0 ], 'PetStore ' );
0 commit comments