Skip to content
Snippets Groups Projects
Commit 250a8e57 authored by Demian Katz's avatar Demian Katz Committed by Robert Lange
Browse files

Add test.

parent 3c012186
No related merge requests found
...@@ -94,6 +94,22 @@ class HistoryTest extends TestCase ...@@ -94,6 +94,22 @@ class HistoryTest extends TestCase
); );
} }
/**
* Test that purging history proxies to the right place.
*
* @return void
*/
public function testPurgeHistory()
{
$table = $this->getMockBuilder(\VuFind\Db\Table\Search::class)
->disableOriginalConstructor()->setMethods(['destroySession'])
->getMock();
$table->expects($this->once())->method('destroySession')
->with($this->equalTo('foosession'), $this->equalTo(1234));
$history = $this->getHistory($table);
$history->purgeSearchHistory(1234);
}
/** /**
* Get object for testing. * Get object for testing.
* *
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment