mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-18 18:46:17 +00:00
Adding Inflector test for Ticket #2061
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@4463 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
709e257707
commit
5c2e4821f7
1 changed files with 11 additions and 2 deletions
|
@ -41,8 +41,17 @@ class InflectorTest extends UnitTestCase {
|
||||||
}
|
}
|
||||||
|
|
||||||
function testInflectingStuff() {
|
function testInflectingStuff() {
|
||||||
$this->assertEqual($this->inflector->pluralize('Bus'), 'Buses', 'Badness!');
|
$result = $this->inflector->pluralize('Bus');
|
||||||
$this->assertEqual($this->inflector->pluralize('bus'), 'buses', 'Badness!');
|
$expected = 'Buses';
|
||||||
|
$this->assertEqual($result, $expected, "Badness! Expected '{$expected}', got '{$result}'");
|
||||||
|
|
||||||
|
$result = $this->inflector->pluralize('bus');
|
||||||
|
$expected = 'buses';
|
||||||
|
$this->assertEqual($this->inflector->pluralize('bus'), 'buses', "Badness! Expected '{$expected}', got '{$result}'");
|
||||||
|
|
||||||
|
$result = $this->inflector->singularize('menus');
|
||||||
|
$expected = 'menu';
|
||||||
|
$this->assertEqual($result, $expected, "Badness! Expected '{$expected}', got '{$result}'");
|
||||||
}
|
}
|
||||||
|
|
||||||
function tearDown() {
|
function tearDown() {
|
||||||
|
|
Loading…
Add table
Reference in a new issue