tangled
alpha
login
or
join now
jcs.org
/
halfmoon
0
fork
atom
a tiny mvc framework for php using php-activerecord
0
fork
atom
overview
issues
pulls
pipelines
Merge branch 'master' into gh101-has_many-through
Yoan Blanc
15 years ago
0567cf8f
ce925f76
+4
-6
3 changed files
expand all
collapse all
unified
split
lib
php-activerecord
test
AllTests.php
RelationshipTest.php
helpers
config.php
+1
-3
lib/php-activerecord/test/AllTests.php
···
1
1
<?php
2
2
require_once 'PHPUnit/Framework.php';
3
3
4
4
-
date_default_timezone_set('Europe/Zurich');
5
5
-
6
4
foreach (glob('*Test.php') as $file)
7
5
{
8
6
if ($file != 'AllValidationsTest.php')
···
24
22
return $suite;
25
23
}
26
24
}
27
27
-
?>
25
25
+
?>
+2
-2
lib/php-activerecord/test/RelationshipTest.php
···
501
501
AuthorWithNonModelRelationship::first()->books;
502
502
}
503
503
504
504
-
public function test_gh93_eager_loading_respects_association_options()
504
504
+
public function test_gh93_and_gh100_eager_loading_respects_association_options()
505
505
{
506
506
-
Venue::$has_many = array(array('events', 'order' => 'id asc', 'conditions' => array('length(title) = ?', 14)));
506
506
+
Venue::$has_many = array(array('events', 'class_name' => 'Event', 'order' => 'id asc', 'conditions' => array('length(title) = ?', 14)));
507
507
$venues = Venue::find(array(2, 6), array('include' => 'events'));
508
508
509
509
$this->assert_sql_has("WHERE length(title) = ? AND venue_id IN(?,?) ORDER BY id asc",ActiveRecord\Table::load('Event')->last_sql);
+1
-1
lib/php-activerecord/test/helpers/config.php
···
71
71
});
72
72
73
73
error_reporting(E_ALL | E_STRICT);
74
74
-
?>
74
74
+
?>