Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Adding Inflector::underscore tests

  • Loading branch information...
commit 3bd8bd2e0e99529c56b8a783da1eb98260407053 1 parent 4ffacfa
@predominant predominant authored
Showing with 13 additions and 0 deletions.
  1. +13 −0 cake/tests/cases/libs/inflector.test.php
View
13 cake/tests/cases/libs/inflector.test.php
@@ -246,6 +246,19 @@ function testInflectorSlugWithMap() {
}
/**
+ * testInflectorUnderscore method
+ *
+ * @return void
+ * @access public
+ */
+ function testInflectorUnderscore() {
+ $this->assertIdentical(Inflector::underscore('TestThing'), 'test_thing');
+ $this->assertIdentical(Inflector::underscore('testThing'), 'test_thing');
+ $this->assertIdentical(Inflector::underscore('TestThingExtra'), 'test_thing_extra');
+ $this->assertIdentical(Inflector::underscore('testThingExtra'), 'test_thing_extra');
+ }
+
+/**
* testVariableNaming method
*
* @access public
Please sign in to comment.
Something went wrong with that request. Please try again.