[Bps-public-commit] jifty-dbi branch, master, updated. 863031eba3832efa3f3261937191baf676c66958

Alex M Vandiver alexmv at bestpractical.com
Mon Dec 28 17:05:01 EST 2009


The branch, master has been updated
       via  863031eba3832efa3f3261937191baf676c66958 (commit)
      from  46c818bded3109dc9047a9e4c8414d9af02906a7 (commit)

Summary of changes:
 t/12prefetch.t |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

- Log -----------------------------------------------------------------
commit 863031eba3832efa3f3261937191baf676c66958
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Mon Dec 28 17:04:59 2009 -0500

    Don't rely on the database's sort order defaulting to 'id'

diff --git a/t/12prefetch.t b/t/12prefetch.t
index 021982d..45f7ad2 100644
--- a/t/12prefetch.t
+++ b/t/12prefetch.t
@@ -7,7 +7,7 @@ use Test::More;
 
 BEGIN { require "t/utils.pl" }
 our (@available_drivers);
-use constant TESTS_PER_DRIVER => 58;
+use constant TESTS_PER_DRIVER => 59;
 
 my $total = scalar(@available_drivers) * TESTS_PER_DRIVER;
 
@@ -95,12 +95,14 @@ SKIP: {
                 column2 => 'employee'
             );
             $collection->prefetch( $phones_alias => 'phones' );
+            $collection->order_by( column => 'id' );
             is( $collection->count, 2 );
             is( scalar( $handle->sql_statement_log ),
                 1, "count is one statement" );
 
             $handle->clear_sql_statement_log;
             my $user = $collection->next;
+            is( $user->name, 'RUZ' );
             is( $user->id, 1, "got our user" );
             my $phones = $user->phones;
             is( $phones->first->id, 1 );

-----------------------------------------------------------------------



More information about the Bps-public-commit mailing list