Open Journal Systems  2.4.4
 All Classes Namespaces Functions Variables Groups Pages
FunctionalLucenePluginAutocompletionTest Class Reference
Inheritance diagram for FunctionalLucenePluginAutocompletionTest:
FunctionalLucenePluginBaseTestCase WebTestCase

Public Member Functions

 testAutocompletionForAdvancedSearch ()
 
 testAutocompletionForSimpleSearch ()
 
 testAutocompletionSelection ()
 
 testPrefilteredAutosuggestion ()
 

Protected Member Functions

 getAffectedTables ()
 
 setUp ()
 
- Protected Member Functions inherited from FunctionalLucenePluginBaseTestCase
 simpleSearch ($searchPhrase, $searchField= 'query', $articles=array(), $notArticles=array(), $locale= 'en_US', $journal= 'lucene-test')
 
 simpleSearchAcrossJournals ($searchTerm, $locale= 'en_US')
 
- Protected Member Functions inherited from WebTestCase
 getAffectedTables ()
 
 improveException ($e, $testObject)
 
 logIn ()
 
 setUp ()
 
 tearDown ()
 
 verified ()
 
 verifyAndOpen ($url)
 

Detailed Description

Integration/Functional test for the auto-completion feature of the lucene plug-in.

See Also
LucenePlugin

NB: We are testing the UI-part of the auto-suggest feature here, not the intricacies of faceting vs. suggester behaviour. We use the faceting implementation here so that we can comply with the more complicated scope-specific requirements. Please see the SolrWebServiceTest for such tests.

FEATURE: auto-completion

Definition at line 29 of file FunctionalLucenePluginAutocompletionTestCase.php.

Member Function Documentation

FunctionalLucenePluginAutocompletionTest::getAffectedTables ( )
protected
FunctionalLucenePluginAutocompletionTest::setUp ( )
protected
FunctionalLucenePluginAutocompletionTest::testAutocompletionForAdvancedSearch ( )

SCENARIO OUTLINE: auto-completion for advanced search GIVEN I am on the advanced search page in {search scope} context WHEN I enter a {letter} combination into a {search field} THEN I'll see an auto-completion drop down with at least {proposals} for auto-completion from {search scope} AND I'll not see proposals that are {not in scope}.

EXAMPLES:

search scope | search field | letter | proposals | not in scope

all journals | all categories | te | test, tester, tests, testen, tester | lucene-test | all categories | te | test, tests | tester lucene-test | authors | au | author, authorname | all journals | title | te | test, testartikel | lucene-test | title | te | test | testartikel lucene-test | full text | nu | nutella | lucene-test | suppl. files | ma | mango | lucene-test | discipline | die | dietary | all journals | keywords | top | topology, topologische | lucene-test | keywords | lun | lunch, lunchtime | lucene-test | type | ex | experience | exotic lucene-test | coverage | ce | century | chicken

Definition at line 150 of file FunctionalLucenePluginAutocompletionTestCase.php.

References WebTestCase\improveException().

FunctionalLucenePluginAutocompletionTest::testAutocompletionForSimpleSearch ( )

SCENARIO OUTLINE: auto-completion for simple search GIVEN I am on a page in {search scope} WHEN I enter select a {search field} AND I enter {letters} into the simple search field THEN I'll see an auto-completion drop down with at least {proposals} for auto-completion from {search scope} AND I'll not see proposals that are {not in scope}.

EXAMPLES:

search scope | search field | letters | proposals | not in scope

all journals | query | ar | article, arthur, are, artikel | lucene-test | query | Ar | Article, Arthur, Are | artikel lucene-test | authors | ar | arthur | article, artikel, are

Definition at line 90 of file FunctionalLucenePluginAutocompletionTestCase.php.

References WebTestCase\improveException(), and WebTestCase\verifyAndOpen().

FunctionalLucenePluginAutocompletionTest::testAutocompletionSelection ( )

SCENARIO: auto-completion selection GIVEN I have entered the letter combination 'win' in journal context AND I am seeing an auto-completion drop down with 'wings' as its first entry WHEN I press the 'down arrow' and then the 'enter' key THEN the word 'chicken' will automatically be entered into the search field

Definition at line 255 of file FunctionalLucenePluginAutocompletionTestCase.php.

FunctionalLucenePluginAutocompletionTest::testPrefilteredAutosuggestion ( )

SCENARIO OUTLINE: pre-filtered auto-suggestion GIVEN I am on the search page in journal scope AND I have entered {authorname} in the authors box WHEN I enter type 'lu' into the main search box THEN I'll see a pre-filtered auto-completion drop down with {proposals} for auto-completion AND I'll not see proposals that are {not in scope}.

EXAMPLES:

authorname | proposals | not in scope

authorname | lucene | lunch, lunchtime author | lucene, lunch, lunchtime |

Definition at line 213 of file FunctionalLucenePluginAutocompletionTestCase.php.


The documentation for this class was generated from the following file: