Skip to content

Commit

Permalink
because of tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mlantz committed Sep 5, 2023
1 parent a2eaa6c commit 3d83e53
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/php-package-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
php-versions: ['7.3', '7.4', '8.0']
php-versions: ['8.0', '8.1']

steps:
- uses: actions/checkout@v2
Expand Down
2 changes: 1 addition & 1 deletion tests/Unit/Components/ImageTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ public function testHtmlRendering()

$blade = (string) $this->blade($template);

$this->assertStringContainsString('<img class="img-thumbnail img-fluid" src="https://somewhere.com/picture.jpg"', $blade);
$this->assertStringContainsString('<img class="img-thumbnail img-fluid" src="https://somewhere.com/picture.jpg"', $blade);
$this->assertStringContainsString('img-thumbnail img-fluid', $blade);
$this->assertStringContainsString('What!', $blade);
}
Expand Down
8 changes: 4 additions & 4 deletions tests/Unit/ImageTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ class ImageTest extends TestCase
public function testHtmlRendering()
{
$html = Image::make()->source('https://example.com/picture.jpg')->thumbnail()->render();
$this->assertStringContainsString('<img class="img-thumbnail" src="https://example.com/picture.jpg" alt="" />', $html);
$this->assertStringContainsString('<img class="img-thumbnail" src="https://example.com/picture.jpg" alt="" />', $html);

$html = Image::make()->source('https://example.com/picture.jpg')->fluid()->render();
$this->assertStringContainsString('<img class="img-fluid" src="https://example.com/picture.jpg" alt="" />', $html);
$this->assertStringContainsString('<img class="img-fluid" src="https://example.com/picture.jpg" alt="" />', $html);

$html = Image::make()->source('https://example.com/picture.jpg')->css('rounded')->fluid()->render();
$this->assertStringContainsString('<img class="rounded img-fluid" src="https://example.com/picture.jpg" alt="" />', $html);
$this->assertStringContainsString('<img class="rounded img-fluid" src="https://example.com/picture.jpg" alt="" />', $html);

$html = Image::make()->source('https://example.com/picture.jpg')->css('rounded')->placeholder()->render();
$this->assertStringContainsString('<div class="html-placeholder"><img class="rounded" src="https://example.com/picture.jpg" alt="" /></div>', $html);
$this->assertStringContainsString('<div class="html-placeholder"><img class="rounded" src="https://example.com/picture.jpg" alt="" /></div>', $html);
}
}

0 comments on commit 3d83e53

Please sign in to comment.