From 7b914bab9f61d6922909f8e36ca13d7e8496d351 Mon Sep 17 00:00:00 2001 From: phpnut Date: Wed, 24 Oct 2007 17:04:14 +0000 Subject: [PATCH] Correcting tests git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@5893 3807eeeb-6ff5-0310-8944-8be069107fe0 --- cake/tests/cases/libs/model/model.test.php | 3 +++ cake/tests/fixtures/primary_model_fixture.php | 2 +- cake/tests/fixtures/secondary_model_fixture.php | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/cake/tests/cases/libs/model/model.test.php b/cake/tests/cases/libs/model/model.test.php index bca6b779b..703f7fcb7 100644 --- a/cake/tests/cases/libs/model/model.test.php +++ b/cake/tests/cases/libs/model/model.test.php @@ -694,6 +694,9 @@ class ModelTest extends CakeTestCase { $result = $Primary->getInsertID(); $this->assertTrue(!empty($result)); + $result = $Primary->field('primary_name', array('id' => $result)); + $this->assertEqual($result, 'Primary Name New'); + $result = $Primary->findCount(); $this->assertEqual($result, 2); } diff --git a/cake/tests/fixtures/primary_model_fixture.php b/cake/tests/fixtures/primary_model_fixture.php index e85f2c591..7472c38da 100644 --- a/cake/tests/fixtures/primary_model_fixture.php +++ b/cake/tests/fixtures/primary_model_fixture.php @@ -39,7 +39,7 @@ class PrimaryModelFixture extends CakeTestFixture { 'primary_name' => array('type' => 'string', 'null' => false) ); var $records = array( - array ('id' => 1, 'title' => 'Primary Name Existing') + array ('id' => 1, 'primary_name' => 'Primary Name Existing') ); } diff --git a/cake/tests/fixtures/secondary_model_fixture.php b/cake/tests/fixtures/secondary_model_fixture.php index 25c35c505..0fde09444 100644 --- a/cake/tests/fixtures/secondary_model_fixture.php +++ b/cake/tests/fixtures/secondary_model_fixture.php @@ -39,7 +39,7 @@ class SecondaryModelFixture extends CakeTestFixture { 'secondary_name' => array('type' => 'string', 'null' => false) ); var $records = array( - array ('id' => 1, 'title' => 'Secondary Name Existing') + array ('id' => 1, 'secondary_name' => 'Secondary Name Existing') ); }