@@ -13,26 +13,26 @@ protected function setUp(): void
13
13
$ this ->workspace ->reset ();
14
14
}
15
15
16
- public function testBuild ()
16
+ public function testBuild (): void
17
17
{
18
18
$ manifest = <<<'EOT'
19
- // File: Foobar.php
20
- <?php
21
-
22
- class Foobar
23
- {
24
- }
25
- // File: Foobar/Barfoo.php
26
- <?php
27
-
28
- namespace Foobar;
29
-
30
- class Barfoo
31
- {
32
- }
33
- // File: Expected.php
34
- Hello World
35
- EOT
19
+ // File: Foobar.php
20
+ <?php
21
+
22
+ class Foobar
23
+ {
24
+ }
25
+ // File: Foobar/Barfoo.php
26
+ <?php
27
+
28
+ namespace Foobar;
29
+
30
+ class Barfoo
31
+ {
32
+ }
33
+ // File: Expected.php
34
+ Hello World
35
+ EOT
36
36
;
37
37
38
38
$ this ->workspace ->loadManifest ($ manifest );
@@ -43,15 +43,15 @@ class Barfoo
43
43
$ this ->assertEquals ('Hello World ' , $ this ->workspace ->getContents ('Expected.php ' ));
44
44
}
45
45
46
- public function testGetContentsNotExist ()
46
+ public function testGetContentsNotExist (): void
47
47
{
48
48
$ this ->expectException (InvalidArgumentException::class);
49
49
$ this ->expectExceptionMessage ('File "barbarbarbar" does not exist ' );
50
50
51
51
$ this ->workspace ->getContents ('barbarbarbar ' );
52
52
}
53
53
54
- public function testReset ()
54
+ public function testReset (): void
55
55
{
56
56
$ this ->workspace ->reset ();
57
57
touch ($ this ->workspace ->path ('Foobar.php ' ));
@@ -67,31 +67,31 @@ public function testReset()
67
67
$ this ->assertFalse ($ this ->workspace ->exists ('Barfoo/Bazboo.php ' ));
68
68
}
69
69
70
- public function testMkdir ()
70
+ public function testMkdir (): void
71
71
{
72
72
$ this ->workspace ->mkdir ('foobar ' );
73
73
$ this ->assertTrue ($ this ->workspace ->exists ('foobar ' ));
74
74
$ this ->assertFalse ($ this ->workspace ->exists ('barfoo ' ));
75
75
}
76
76
77
- public function testPutFileContents ()
77
+ public function testPutFileContents (): void
78
78
{
79
79
$ this ->workspace ->put ('foobar ' , 'foobar contents ' );
80
80
$ this ->assertTrue ($ this ->workspace ->exists ('foobar ' ));
81
81
$ this ->assertStringContainsString ('foobar contents ' , $ this ->workspace ->getContents ('foobar ' ));
82
82
}
83
83
84
- public function testGetPathWithNoArgs ()
84
+ public function testGetPathWithNoArgs (): void
85
85
{
86
86
$ this ->assertEquals ($ this ->workspaceDir (), $ this ->workspace ->path ());
87
87
}
88
88
89
- public function testGetPath ()
89
+ public function testGetPath (): void
90
90
{
91
91
$ this ->assertEquals ($ this ->workspaceDir () . '/foo ' , $ this ->workspace ->path ('foo ' ));
92
92
}
93
93
94
- public function testGetPathConcat ()
94
+ public function testGetPathConcat (): void
95
95
{
96
96
$ workspace = Workspace::create ($ this ->workspaceDir () . '/foobar/ ' );
97
97
$ this ->assertEquals ($ this ->workspaceDir () . '/foobar/foo ' , $ workspace ->path ('foo ' ));
0 commit comments