You are here

protected function FacetapiTestCase::assertUrl in Facet API 6.3

Pass if the internal browser's URL matches the given path.

Parameters

$path: The expected system path.

$options: (optional) Any additional options to pass for $path to url().

$message: Message to display.

$group: The group this message belongs to, defaults to 'Other'.

Return value

TRUE on pass, FALSE on fail.

Overrides DrupalWebTestCase::assertUrl

1 call to FacetapiTestCase::assertUrl()
FacetapiSearchPageInterfaceTestCase::testFormAccess in tests/facetapi.test

File

tests/facetapi.test, line 115
Tests for the Facet API module.

Class

FacetapiTestCase
Base class for all Facet API test cases.

Code

protected function assertUrl($path, array $options = array(), $message = '', $group = 'Other') {
  if (!$message) {
    $url = url($path, $options);
    $message = t('Current URL is @url.', array(
      '@url' => $url,
    ));
  }
  $options['absolute'] = TRUE;
  return $this
    ->assertEqual($this
    ->getUrl(), url($path, $options), $message, $group);
}