Add a new test with an accentuated character
This commit is contained in:
		
							parent
							
								
									88ff8f5409
								
							
						
					
					
						commit
						68d8282a98
					
				
					 1 changed files with 19 additions and 0 deletions
				
			
		| 
						 | 
					@ -592,6 +592,25 @@ class PageTest extends PHPUnit_Framework_TestCase
 | 
				
			||||||
        $this->assertFalse ($currentPage->ContainsBook ());
 | 
					        $this->assertFalse ($currentPage->ContainsBook ());
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    public function testPageSearch_WithAccentuatedCharacters ()
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        global $config;
 | 
				
			||||||
 | 
					        $page = Base::PAGE_OPENSEARCH_QUERY;
 | 
				
			||||||
 | 
					        $query = "curée";
 | 
				
			||||||
 | 
					        $qid = NULL;
 | 
				
			||||||
 | 
					        $n = "1";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        // Only books returned
 | 
				
			||||||
 | 
					        $currentPage = Page::getPage ($page, $qid, $query, $n);
 | 
				
			||||||
 | 
					        $currentPage->InitializeContent ();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        $this->assertEquals ("Search result for *curée*", $currentPage->title);
 | 
				
			||||||
 | 
					        $this->assertCount (1, $currentPage->entryArray);
 | 
				
			||||||
 | 
					        $this->assertEquals ("Search result for *curée* in books", $currentPage->entryArray [0]->title);
 | 
				
			||||||
 | 
					        $this->assertEquals ("1 book", $currentPage->entryArray [0]->content);
 | 
				
			||||||
 | 
					        $this->assertFalse ($currentPage->ContainsBook ());
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    public function testPageSearchScopeAuthors ()
 | 
					    public function testPageSearchScopeAuthors ()
 | 
				
			||||||
    {
 | 
					    {
 | 
				
			||||||
        $page = Base::PAGE_OPENSEARCH_QUERY;
 | 
					        $page = Base::PAGE_OPENSEARCH_QUERY;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue