You are here

function SearchByPagePathsAliasTest::testSearchPage in Search by Page 6

Same name and namespace in other branches
  1. 7 tests/search_by_page.test \SearchByPagePathsAliasTest::testSearchPage()

Tests that aliased page can be searched.

File

tests/search_by_page.test, line 1586
Tests for the Search by Page module. By Jennifer Hodgdon of Poplar ProductivityWare, www.poplarware.com

Class

SearchByPagePathsAliasTest
Tests for Search by Page Paths - searching nodes with aliases.

Code

function testSearchPage() {

  // Search for 'walk' - should find the page
  $search_path = $this->envinfo1['page_path'];
  $this
    ->drupalLogin($this->superuser);
  $this
    ->drupalPost($search_path, array(
    'keys' => 'walk',
  ), t('Search pages'));
  $this
    ->assertText('walk', "Walk appears in search results for walk");
  $this
    ->assertText('streets', "Aliased page was found");
}