Skip to content

Commit

Permalink
chore(deps-dev): update phpunit/phpunit requirement
Browse files Browse the repository at this point in the history
Updates the requirements on [phpunit/phpunit](https://github.com/sebastianbergmann/phpunit) to permit the latest version.
- [Release notes](https://github.com/sebastianbergmann/phpunit/releases)
- [Changelog](https://github.com/sebastianbergmann/phpunit/blob/main/ChangeLog-9.5.md)
- [Commits](sebastianbergmann/phpunit@9.5.25...9.5.26)

---
updated-dependencies:
- dependency-name: phpunit/phpunit
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <[email protected]>
  • Loading branch information
dependabot[bot] authored and neilime committed Nov 8, 2022
1 parent bc01ed9 commit f0de7c2
Show file tree
Hide file tree
Showing 5 changed files with 58 additions and 7 deletions.
5 changes: 1 addition & 4 deletions .github/workflows/build-website.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: echo ::set-output name=NVMRC::$(cat .nvmrc)
id: nvm

- uses: actions/[email protected]
id: setup-node
with:
node-version: "${{ steps.nvm.outputs.NVMRC }}"
node-version-file: ".nvmrc"
cache: yarn
cache-dependency-path: website/yarn.lock

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/continuous-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:

- name: ♻️ Get composer cache directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT

- name: ♻️ Cache composer dependencies
uses: actions/cache@v3
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

## Demonstration / example

🚀 Render **ALL** of the [Twitter Bootstrap v5+](https://getbootstrap.com/) elements with TwbsHelper : [see it in action, on-line](https://neilime.github.io/twbs-helper-module/#/usage/?id=rendering).
🚀 Render **ALL** of the [Twitter Bootstrap v5+](https://getbootstrap.com/) elements with TwbsHelper : [see it in action, on-line](https://neilime.github.io/twbs-helper-module/docs/usage/intro/).

## Documentation

Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
"phpstan/extension-installer": "^1.1",
"phpstan/phpstan": "^0.12",
"phpstan/phpstan-phpunit": "^0.12",
"phpunit/phpunit": "^9.5.25",
"phpunit/phpunit": "^9.5.26",
"slam/phpstan-laminas-framework": "^0.12",
"spatie/phpunit-snapshot-assertions": "^4.2",
"squizlabs/php_codesniffer": "^3.7"
Expand Down
54 changes: 54 additions & 0 deletions tests/TestSuite/TwbsHelper/View/HtmlStyleAttributeSetTest.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
<?php

namespace TestSuite\TwbsHelper\View;

class HtmlStyleAttributeSetTest extends \PHPUnit\Framework\TestCase
{
/**
* @var \\Laminas\View\Renderer\PhpRenderer
*/
protected $phpRenderer;

protected function setUp(): void
{
$viewHelperPluginManager = \TestSuite\Bootstrap::getServiceManager()->get('ViewHelperManager');
$this->phpRenderer = new \Laminas\View\Renderer\PhpRenderer();
$this->phpRenderer->setHelperPluginManager($viewHelperPluginManager);
}

public function testToString()
{
$htmlStyleAttributeSet = new \TwbsHelper\View\HtmlStyleAttributeSet([
'width' => '50%',
'color' => 'red',
]);

$this->assertSame(
'color: red; width: 50%;',
$htmlStyleAttributeSet->__toString()
);
}

public function testMerge()
{
$htmlStyleAttributeSet = new \TwbsHelper\View\HtmlStyleAttributeSet([
'width' => '50%',
'color' => 'red',
]);

$htmlStyleAttributeSet->merge([
'width' => '50%',
'color' => 'green',
'height' => '100%',
]);

$this->assertSame(
[
'color' => 'green',
'height' => '100%',
'width' => '50%',
],
$htmlStyleAttributeSet->getArrayCopy()
);
}
}

0 comments on commit f0de7c2

Please sign in to comment.