Skip to content

Commit aaadc03

Browse files
committed
wip
1 parent 3e3b326 commit aaadc03

File tree

4 files changed

+10
-23
lines changed

4 files changed

+10
-23
lines changed

.github/workflows/run-tests.yml

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
matrix:
1111
os: [ubuntu-latest, windows-latest]
1212
php: [7.4]
13-
laravel: [5.5.*, 5.6.*, 5.7.*, 5.8.*, 6.*, 7.*]
13+
laravel: [5.8.*, 6.*, 7.*]
1414
dependency-version: [prefer-lowest, prefer-stable]
1515
include:
1616
- laravel: 7.*
@@ -19,12 +19,6 @@ jobs:
1919
testbench: 4.*
2020
- laravel: 5.8.*
2121
testbench: 3.8.*
22-
- laravel: 5.7.*
23-
testbench: 3.7.*
24-
- laravel: 5.6.*
25-
testbench: 3.6.*
26-
- laravel: 5.5.*
27-
testbench: 3.5.*
2822

2923
name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.dependency-version }} - ${{ matrix.os }}
3024

composer.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@
1616
}
1717
],
1818
"require": {
19-
"php": "^7.1",
20-
"illuminate/support": "~5.5|~5.6|~5.7|~5.8|^6.0|^7.0"
19+
"php": "^7.2",
20+
"illuminate/support": "~5.8|^6.0|^7.0"
2121
},
2222
"require-dev": {
23-
"orchestra/testbench": "~3.5|~3.6|~3.7|~3.8|^4.0|^5.0"
23+
"orchestra/testbench": "~3.8|^4.0|^5.0"
2424
},
2525
"autoload": {
2626
"psr-4": {

phpunit.xml.dist

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,4 @@
1919
<directory suffix=".php">src/</directory>
2020
</whitelist>
2121
</filter>
22-
<logging>
23-
<log type="tap" target="build/report.tap"/>
24-
<log type="junit" target="build/report.junit.xml"/>
25-
<log type="coverage-html" target="build/coverage"/>
26-
<log type="coverage-text" target="build/coverage.txt"/>
27-
<log type="coverage-clover" target="build/logs/clover.xml"/>
28-
</logging>
2922
</phpunit>

tests/ViewModelMakeCommandTest.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,17 @@ public function it_can_create_a_view_model()
1717

1818
$this->assertEquals(0, $exitCode);
1919

20-
$this->assertContains('ViewModel created successfully.', Artisan::output());
20+
$this->assertStringContainsString('ViewModel created successfully.', Artisan::output());
2121

2222
$shouldOutputFilePath = $this->app['path'].'/ViewModels/HomeViewModel.php';
2323

2424
$this->assertTrue(File::exists($shouldOutputFilePath), 'File exists in default app/ViewModels folder');
2525

2626
$contents = File::get($shouldOutputFilePath);
2727

28-
$this->assertContains('namespace App\ViewModels;', $contents);
28+
$this->assertStringContainsString('namespace App\ViewModels;', $contents);
2929

30-
$this->assertContains('class HomeViewModel extends ViewModel', $contents);
30+
$this->assertStringContainsString('class HomeViewModel extends ViewModel', $contents);
3131
}
3232

3333
/** @test */
@@ -40,16 +40,16 @@ public function it_can_create_a_view_model_with_a_custom_namespace()
4040

4141
$this->assertEquals(0, $exitCode);
4242

43-
$this->assertContains('ViewModel created successfully.', Artisan::output());
43+
$this->assertStringContainsString('ViewModel created successfully.', Artisan::output());
4444

4545
$shouldOutputFilePath = $this->app['path'].'/Blog/PostsViewModel.php';
4646

4747
$this->assertTrue(File::exists($shouldOutputFilePath), 'File exists in custom app/Blog folder');
4848

4949
$contents = File::get($shouldOutputFilePath);
5050

51-
$this->assertContains('namespace App\Blog;', $contents);
51+
$this->assertStringContainsString('namespace App\Blog;', $contents);
5252

53-
$this->assertContains('class PostsViewModel extends ViewModel', $contents);
53+
$this->assertStringContainsString('class PostsViewModel extends ViewModel', $contents);
5454
}
5555
}

0 commit comments

Comments
 (0)