Skip to content

Commit

Permalink
set phpstan check level to 5
Browse files Browse the repository at this point in the history
  • Loading branch information
skoro committed Jan 2, 2023
1 parent a11558a commit 35d3fbf
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 8 deletions.
2 changes: 1 addition & 1 deletion phpstan.neon.dist
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
parameters:
level: 4
level: 5
paths:
- src
- tests
Expand Down
3 changes: 1 addition & 2 deletions tests/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
use PHPUnit\Framework\TestCase as FrameworkTestCase;
use Tkui\Application;
use Tkui\Evaluator;
use Tkui\Widgets\Widget;
use Tkui\Windows\Window;

class TestCase extends FrameworkTestCase
Expand Down Expand Up @@ -36,7 +35,7 @@ protected function createEvalMock()
return $this->createMock(Evaluator::class);
}

protected function createWindowStub(): Widget
protected function createWindowStub(): Window
{
/** @var Window|Stub $win */
$win = $this->createStub(Window::class);
Expand Down
6 changes: 3 additions & 3 deletions tests/Widgets/EntryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@
use Tkui\Tests\TestCase;
use Tkui\TclTk\Variable;
use Tkui\Widgets\Entry;
use Tkui\Widgets\Widget;
use Tkui\Windows\Window;

class EntryTest extends TestCase
{
protected function createWindowStub(): Widget
protected function createWindowStub(): Window
{
/** @var Widget|Stub $win */
/** @var Window|Stub $win */
$win = parent::createWindowStub();

$var = $this->createStub(Variable::class);
Expand Down
4 changes: 2 additions & 2 deletions tests/Widgets/TreeViewTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public function treeview_created(): void
/** @test */
public function treeview_can_add_item(): void
{
$item = new Item([1,2,3]);
$item = new Item(['1', '2', '3']);

$this->tclEvalTest(3, [
['ttk::treeview', $this->checkWidget('.tv')],
Expand All @@ -47,7 +47,7 @@ public function treeview_can_add_item(): void
/** @test */
public function treeview_item_can_be_deleted(): void
{
$item = new Item([1,2,3]);
$item = new Item(['1', '2', '3']);

$this->tclEvalTest(4, [
['ttk::treeview', $this->checkWidget('.tv')],
Expand Down

0 comments on commit 35d3fbf

Please sign in to comment.