Skip to content

[HttpFoundation] Fix broken mock #42384

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 5, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Fix broken mock
Signed-off-by: Alexander M. Turek <me@derrabus.de>
  • Loading branch information
derrabus committed Aug 5, 2021
commit af37c646b5bb7f9562bc2a5d4634811d3d3f109c
Original file line number Diff line number Diff line change
Expand Up @@ -103,17 +103,21 @@ public function testRead()
public function testWrite()
{
$this->mock->expects($this->once())
->method('write');
->method('write')
->willReturn(true)
;

$this->proxy->write('id', 'data');
$this->assertTrue($this->proxy->write('id', 'data'));
}

public function testDestroy()
{
$this->mock->expects($this->once())
->method('destroy');
->method('destroy')
->willReturn(true)
;

$this->proxy->destroy('id');
$this->assertTrue($this->proxy->destroy('id'));
}

public function testGc()
Expand Down Expand Up @@ -149,7 +153,9 @@ public function testUpdateTimestamp()
$proxy->updateTimestamp('id', 'data');

$this->mock->expects($this->once())
->method('write');
->method('write')
->willReturn(true)
;

$this->proxy->updateTimestamp('id', 'data');
}
Expand Down