예제 #1
0
	public function setUp()
	{
		parent::setUp();
	
		$bar = new SearchBar;
		$bar->title = 'Bar Title';
		$bar->someOtherPrimary = 'The Primary';
		$bar->body = 'Lorem Ipsum';
		$bar->language = 'en';
		$bar->save();
	
		$foo = new SearchFoo;
		$foo->title = 'My Title';
		$foo->someOtherPrimary = 'other-primary';
		$foo->datePrimary = '2010-01-01';
		$foo->body = 'Somewhere over the rainbow goes, tudeludoedoe <bold>This is some text that has to be searched</bold>';
		$foo->barTitle = 'Bar Title';
		$foo->barSomeOtherPrimary = 'The Primary';
		$foo->identity = 'Keep Me As I am';
		$foo->language = 'en';
		$foo->save();
		
		$tag = new Tagging;
		$tag->title = 'Some Title';
		$tag->language = 'en';
		$tag->body = 'Some Very Long body.';
		$tag->save();
		$tag->tag('Gamma');
		$tag->tag('Alpha');
		$tag->tag('Beta');
		
		$tag = new Tagging;
		$tag->title = 'Some Other Title';
		$tag->language = 'en';
		$tag->body = 'Some Very short body.';
		$tag->save();
		$tag->tag('Aay');
		$tag->tag('Bee');
		$tag->tag('Cee');
	}
예제 #2
0
	public function setUp()
	{
		parent::setUp();
	
		$bar = new SearchBar;
		$bar->title = 'Bar Title';
		$bar->someOtherPrimary = 'The Primary';
		$bar->body = 'Lorem Ipsum';
		$bar->language = 'en';
		$bar->save();
		
		$bar = new SearchBar;
		$bar->title = 'Other Bar Title';
		$bar->someOtherPrimary = 'The Primary';
		$bar->body = 'Lorem Ipsum Dolor Sit Amet and more latin';
		$bar->language = 'en';
		$bar->save();
		
		$foo = new SearchFoo;
		$foo->title = 'My Title';
		$foo->someOtherPrimary = 'other-primary';
		$foo->datePrimary = '2010-01-01';
		$foo->body = 'Somewhere over the rainbow goes, tudeludoedoe <bold>This is some text that has to be searched</bold>';
		$foo->barTitle = 'Bar Title';
		$foo->barSomeOtherPrimary = 'The Primary';
		$foo->identity = 'Keep Me As I am';
		$foo->language = 'en';
		$foo->save();
	
		$foo = new SearchFoo;
		$foo->title = 'My Title';
		$foo->someOtherPrimary = 'primary';
		$foo->datePrimary = '2010-06-01';
		$foo->body = 'Lorem	Ipsum	Dolor
		Sit Amet Title
		is very important. So I put title here so its very high up into the list.';
		$foo->language = 'en';
		$foo->identity = 'kEEP me';
		$foo->save();
		
		$foo = new SearchFoo;
		$foo->title = 'My Other Title';
		$foo->someOtherPrimary = 'primary';
		$foo->datePrimary = '2010-08-01';
		$foo->body = 'Aleia iacta est is not the title';
		$foo->language = 'en';
		$foo->save();
		
		
		$foo = new SearchFoo;
		$foo->title = 'Mijn andere titel';
		$foo->someOtherPrimary = 'primary';
		$foo->datePrimary = '2010-09-01';
		$foo->body = 'Dit is mijn nederlandse tekst, om te zien of het goed werkt. Put some english here (title) so it matches with title, but not when searching for english texts...';
		$foo->language = 'nl';
		$foo->save();
		
		$isa = new SearchFooISA;
		$isa->title = 'Some Dodo';
		$isa->someOtherPrimary = 'some-primary';
		$isa->datePrimary = '2010-11-01';
		$isa->body = 'I want you to search this ISA for me...';
		$isa->language = 'en';
		$isa->someISAVar = '...';
		$isa->otherVar = 10;
		$isa->save();
	}