X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=web%2Fmodules%2Fcontrib%2Fporterstemmer%2Ftests%2Fsrc%2FUnit%2FPorter2Pecl5.php;fp=web%2Fmodules%2Fcontrib%2Fporterstemmer%2Ftests%2Fsrc%2FUnit%2FPorter2Pecl5.php;h=85c22c7033a70f99634b1f3f1b256e186593cb41;hp=0000000000000000000000000000000000000000;hb=5ca1b61ad2659177690cbde2cf7675f9c0d50491;hpb=4e1bfbf98b844da83b18aca92ef00f11a4735806 diff --git a/web/modules/contrib/porterstemmer/tests/src/Unit/Porter2Pecl5.php b/web/modules/contrib/porterstemmer/tests/src/Unit/Porter2Pecl5.php new file mode 100644 index 000000000..85c22c703 --- /dev/null +++ b/web/modules/contrib/porterstemmer/tests/src/Unit/Porter2Pecl5.php @@ -0,0 +1,47 @@ +has_pecl_stem) { + $this->assertEquals($stem, stem_english($word)); + } + else { + $this->assertTrue(TRUE, 'No PECL stem library found, Aborting test.'); + } + } + + /** + * Data provider for testStem(). + * + * @return array + * Nested arrays of values to check: + * - $word + * - $stem + */ + public function stemDataProvider() { + if ($this->has_pecl_stem) { + return $this->retrieveStemWords(20000); + } + else { + return array(array('', '')); + } + } + +}