Changeset 4439 for branches/0.11/tests
- Timestamp:
- 05/25/08 22:36:03 (8 months ago)
- Location:
- branches/0.11/tests
- Files:
-
- 2 added
- 2 modified
-
models/SoftDeleteTest.php (modified) (1 diff)
-
run.php (modified) (1 diff)
-
SoftDelete (added)
-
SoftDeleteTestCase.php (added)
Legend:
- Unmodified
- Added
- Removed
-
branches/0.11/tests/models/SoftDeleteTest.php
r2353 r4439 6 6 $this->hasColumn('name', 'string', null, array('primary' => true)); 7 7 $this->hasColumn('something', 'string', '25', array('notnull' => true, 'unique' => true)); 8 $this->hasColumn('deleted', 'boolean', 1);9 8 } 10 public function preDelete($event) 9 10 public function setUp() 11 11 { 12 $event->skipOperation(); 13 } 14 public function postDelete($event) 15 { 16 $this->deleted = true; 17 18 $this->save(); 12 $this->actAs('SoftDelete'); 19 13 } 20 14 } -
branches/0.11/tests/run.php
r4409 r4439 209 209 $behaviors->addTestCase(new Doctrine_Sluggable_TestCase()); 210 210 $behaviors->addTestCase(new Doctrine_Record_Generator_TestCase()); 211 $behaviors->addTestCase(new Doctrine_SoftDelete_TestCase()); 211 212 $test->addTestCase($behaviors); 212 213