summaryrefslogtreecommitdiff
path: root/tests/simple_unit/ActiveRecord
diff options
context:
space:
mode:
authorxue <>2007-09-29 22:07:12 +0000
committerxue <>2007-09-29 22:07:12 +0000
commit54e9feab491bcf8d1a95b486b68605cb4441e603 (patch)
treebffc84037861293872f5db616345888ffbd0e453 /tests/simple_unit/ActiveRecord
parent109ff4ee3bec41d95a122c6a69ad204c5dcfe099 (diff)
Changed RELATIONS declaration.
Diffstat (limited to 'tests/simple_unit/ActiveRecord')
-rw-r--r--tests/simple_unit/ActiveRecord/ForeignKeyTestCase.php6
-rw-r--r--tests/simple_unit/ActiveRecord/ForeignObjectUpdateTest.php8
-rw-r--r--tests/simple_unit/ActiveRecord/records/ItemRecord.php2
3 files changed, 8 insertions, 8 deletions
diff --git a/tests/simple_unit/ActiveRecord/ForeignKeyTestCase.php b/tests/simple_unit/ActiveRecord/ForeignKeyTestCase.php
index 0c1da5d2..cbde7fa0 100644
--- a/tests/simple_unit/ActiveRecord/ForeignKeyTestCase.php
+++ b/tests/simple_unit/ActiveRecord/ForeignKeyTestCase.php
@@ -24,7 +24,7 @@ class Album extends SqliteRecord
public $cover;
- protected static $RELATIONS = array(
+ public static $RELATIONS = array(
'Tracks' => array(self::HAS_MANY, 'Track'),
'Artists' => array(self::HAS_MANY, 'Artist', 'album_artists'),
'cover' => array(self::HAS_ONE, 'Cover')
@@ -42,7 +42,7 @@ class Artist extends SqliteRecord
public $Albums = array();
- protected static $RELATIONS=array(
+ public static $RELATIONS=array(
'Albums' => array(self::HAS_MANY, 'Album', 'album_artists')
);
@@ -60,7 +60,7 @@ class Track extends SqliteRecord
public $Album;
- protected static $RELATIONS = array(
+ public static $RELATIONS = array(
'Album' => array(self::BELONGS_TO, 'Album'),
);
diff --git a/tests/simple_unit/ActiveRecord/ForeignObjectUpdateTest.php b/tests/simple_unit/ActiveRecord/ForeignObjectUpdateTest.php
index ad64e4b6..36864f77 100644
--- a/tests/simple_unit/ActiveRecord/ForeignObjectUpdateTest.php
+++ b/tests/simple_unit/ActiveRecord/ForeignObjectUpdateTest.php
@@ -28,7 +28,7 @@ class TeamRecord extends BaseFkRecord
public $players=array();
//define the $player member having has many relationship with PlayerRecord
- protected static $RELATIONS=array
+ public static $RELATIONS=array
(
'players' => array(self::HAS_MANY, 'PlayerRecord'),
);
@@ -50,7 +50,7 @@ class PlayerRecord extends BaseFkRecord
private $_skills;
public $profile;
- protected static $RELATIONS=array
+ public static $RELATIONS=array
(
'skills' => array(self::HAS_MANY, 'SkillRecord', 'player_skills'),
'team' => array(self::BELONGS_TO, 'TeamRecord'),
@@ -91,7 +91,7 @@ class ProfileRecord extends BaseFkRecord
public $player;
- protected static $RELATIONS=array
+ public static $RELATIONS=array
(
'player' => array(self::BELONGS_TO, 'PlayerRecord'),
);
@@ -110,7 +110,7 @@ class SkillRecord extends BaseFkRecord
public $players=array();
- protected static $RELATIONS=array
+ public static $RELATIONS=array
(
'players' => array(self::HAS_MANY, 'PlayerRecord', 'player_skills'),
);
diff --git a/tests/simple_unit/ActiveRecord/records/ItemRecord.php b/tests/simple_unit/ActiveRecord/records/ItemRecord.php
index 189d22c9..45d15427 100644
--- a/tests/simple_unit/ActiveRecord/records/ItemRecord.php
+++ b/tests/simple_unit/ActiveRecord/records/ItemRecord.php
@@ -19,7 +19,7 @@ class ItemRecord extends TActiveRecord
public $related_items = array();
public $related_item_id;
- protected static $RELATIONS=array
+ public static $RELATIONS=array
(
'related_items' => array(self::HAS_MANY, 'ItemRecord', 'related_items.(related_item_id)'),
);