Code Duplication    Length = 7-7 lines in 2 locations

tests/QueryGeneratorTest.php 2 locations

@@ 589-595 (lines=7) @@
586
587
588
	// ---- tests for field array to elasticsearch syntax
589
	public function testConvertWeightedFieldsForElasticaUnaryStrings() {
590
		$qg = new QueryGenerator();
591
		$qg->setClasses('FlickrPhotoTO');
592
		$fields = array('Title' => 1, 'Description' => 1);
593
		$expected = array('Title', 'Title.*','Description', 'Description.*');
594
		$this->assertEquals($expected, $qg->convertWeightedFieldsForElastica($fields));
595
	}
596
597
598
	public function testConvertWeightedFieldsForElasticaMultipleStrings() {
@@ 598-604 (lines=7) @@
595
	}
596
597
598
	public function testConvertWeightedFieldsForElasticaMultipleStrings() {
599
		$qg = new QueryGenerator();
600
		$qg->setClasses('FlickrPhotoTO');
601
		$fields = array('Title' => 2, 'Description' => 1);
602
		$expected = array('Title^2', 'Title.*^2','Description', 'Description.*');
603
		$this->assertEquals($expected, $qg->convertWeightedFieldsForElastica($fields));
604
	}
605
606
607
	public function testConvertWeightedFieldsForElasticaTestNonString() {