You are here

protected function MongoDBSessionHttpsTestCase::assertSessionIds in MongoDB 7

Test that there exists a session with two specific session IDs.

Parameters

string $sid: The insecure session ID to search for.

string $ssid: The secure session ID to search for.

string $assertion_text: The text to display when we perform the assertion.

Return value

bool The result of assertTrue() that there's a session in the system that has the given insecure and secure session IDs.

Overrides SessionHttpsTestCase::assertSessionIds

File

mongodb_session/mongodb_session.test, line 80
Contains \MongoDBSessionTestCase and \MongoDBSessionHttpsTestCase.

Class

MongoDBSessionHttpsTestCase

Code

protected function assertSessionIds($sid, $ssid, $assertion_text) {
  return $this
    ->assertTrue($this->collection
    ->findOne(array(
    'sid' => $sid,
    'ssid' => $ssid,
  ), array(
    'sid',
  )), $assertion_text);
}