Update ProfaneValidatorTest.php

This commit is contained in:
Nationalcat 2017-06-20 18:36:10 +08:00 committed by GitHub
parent 579ceafc9c
commit 2ffa02d329
1 changed files with 3 additions and 3 deletions

View File

@ -29,7 +29,7 @@ class ProfaneValidatorTest extends PHPUnit_Framework_TestCase
$this->mockConfigs();
$attribute = 'description';
$text = 'fck you bitch. 幹!';
$parameters = ['es', 'en' , 'zh-TW'];
$parameters = ['es', 'en' , 'zh-tw'];
$profane = new ProfaneValidator();
@ -117,9 +117,9 @@ class ProfaneValidatorTest extends PHPUnit_Framework_TestCase
$this->mockConfigs();
$profane = new ProfaneValidator();
$profane->setDictionary(['es', 'en', 'it', 'zh-TW']);
$profane->setDictionary(['es', 'en', 'it', 'zh-tw']);
$expected = array_merge(include __DIR__.'/../src/dict/es.php', include __DIR__.'/../src/dict/en.php', include __DIR__.'/../src/dict/it.php', include __DIR__.'/../src/dict/zh-TW.php');
$expected = array_merge(include __DIR__.'/../src/dict/es.php', include __DIR__.'/../src/dict/en.php', include __DIR__.'/../src/dict/it.php', include __DIR__.'/../src/dict/zh-tw.php');
$this->assertEquals($profane->getBadwords(), $expected);
}