Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Adding documentation on tests

  • Loading branch information...
commit 98e7575c5aaebf403028137838f2a4a0954926a8 1 parent 8f29f59
@lorenzo lorenzo authored
Showing with 25 additions and 0 deletions.
  1. +25 −0 cake/tests/cases/libs/model/datasources/dbo_source.test.php
View
25 cake/tests/cases/libs/model/datasources/dbo_source.test.php
@@ -4082,6 +4082,11 @@ function testShowQuery() {
$this->assertNoPattern('/Took:/s', $contents);
}
+/**
+ * test fields generating usable virtual fields to use in query
+ *
+ * @return void
+ */
function testVirtualFields() {
$this->loadFixtures('Article');
@@ -4115,6 +4120,11 @@ function testVirtualFields() {
$this->assertEqual($expected,$result);
}
+/**
+ * test conditions to generate query conditions for virtual fields
+ *
+ * @return void
+ */
function testVirtualFieldsInConditions() {
$this->loadFixtures('Article');
@@ -4146,6 +4156,11 @@ function testVirtualFieldsInConditions() {
$this->assertEqual($expected,$result);
}
+/**
+ * test order to generate query order clause for virtual fields
+ *
+ * @return void
+ */
function testVirtualFieldsInOrder() {
$this->loadFixtures('Article');
@@ -4160,6 +4175,11 @@ function testVirtualFieldsInOrder() {
$this->assertEqual($expected,$result);
}
+/**
+ * test calculate to generate claculate statements on virtual fields
+ *
+ * @return void
+ */
function testVirtualFieldsInCalculate() {
$this->loadFixtures('Article');
@@ -4180,6 +4200,11 @@ function testVirtualFieldsInCalculate() {
$this->assertEqual($expected,$result);
}
+/**
+ * test a full example of using virtual fields
+ *
+ * @return void
+ */
function testVirtualFieldsFetch() {
$this->loadFixtures('Article','Comment');

0 comments on commit 98e7575

Please sign in to comment.
Something went wrong with that request. Please try again.