Skip to content

Commit

Permalink
Drop PhpSpec 5 for PhpSpec 6 (#13)
Browse files Browse the repository at this point in the history
* build(deps): update phpspec to ^6.0

* doc: update comptability table

* chore: fix specs
  • Loading branch information
Kocal authored Jan 3, 2021
1 parent 032e1d0 commit 82b9dc9
Show file tree
Hide file tree
Showing 5 changed files with 93 additions and 65 deletions.
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,11 @@

## Compatibility

| PHPStan version | PhpSpec extension version |
| --------------- | ---------------------- |
| 0.11.6 | 0.2.x |
| 0.10.7 | 0.1.x |
| PHPStan version | PhpSpec version | PhpSpec extension version |
| --------------- | --------------- | ------------------------- |
| ^0.11.6 | ^6.0 | 0.3.x |
| ^0.11.6 | ^5.1 | 0.2.x |
| ^0.10.7 | ^5.1 | 0.1.x |


## Installation
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"php": "^7.1",
"phpstan/phpstan": "^0.11.6",
"nikic/php-parser": "^4.1",
"phpspec/phpspec": "^5.1"
"phpspec/phpspec": "^6.0"
},
"require-dev": {
"phpunit/phpunit": "^7.0",
Expand Down
139 changes: 79 additions & 60 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ public function it_generates_spec_class_from_resource_and_puts_it_into_appropria
'%filepath%' => '/project/spec/Acme/AppSpec.php',
'%name%' => 'AppSpec',
'%namespace%' => 'spec\Acme',
'%imports%' => "use Acme\App;\nuse PhpSpec\ObjectBehavior;",
'%subject%' => 'Acme\App',
'%subject_class%' => 'App'
];
Expand Down Expand Up @@ -86,6 +87,7 @@ public function it_uses_template_provided_by_templating_system_if_there_is_one(
'%filepath%' => '/project/spec/Acme/AppSpec.php',
'%name%' => 'AppSpec',
'%namespace%' => 'spec\Acme',
'%imports%' => "use Acme\App;\nuse PhpSpec\ObjectBehavior;",
'%subject%' => 'Acme\App',
'%subject_class%' => 'App'
];
Expand Down
6 changes: 6 additions & 0 deletions spec/PhpSpec/Formatter/Presenter/Differ/ArrayEngineSpec.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,15 @@
namespace spec\PhpSpec\Formatter\Presenter\Differ;

use PhpSpec\ObjectBehavior;
use SebastianBergmann\Exporter\Exporter;

class ArrayEngineSpec extends ObjectBehavior
{
public function let(Exporter $exporter)
{
$this->beConstructedWith($exporter);
}

public function it_is_a_diff_engine()
{
$this->shouldBeAnInstanceOf('PhpSpec\Formatter\Presenter\Differ\DifferEngine');
Expand Down

0 comments on commit 82b9dc9

Please sign in to comment.