Skip to content

Commit

Permalink
fix Teng::Schema::Loader->load
Browse files Browse the repository at this point in the history
  • Loading branch information
yibe committed Feb 9, 2011
1 parent 605af90 commit 52c83ea
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/Teng/Schema/Loader.pm
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ sub load {
name => $table_name,
primary_keys => \@table_pk,
sql_types => {},
inflators => {},
deflators => {},
inflators => [],
deflators => [],
row_class => join '::', $namespace, 'Row', Teng::Schema::camelize($table_name),
)
);
Expand Down
3 changes: 3 additions & 0 deletions t/001_basic/003_schema_loader.t
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,8 @@ is(join(',', @{$user->columns}), 'user_id,name,email,created_on');
my $row = $db->schema->get_row_class('user');
is $row, 'Mock::DB::Row::User';

ok $db->insert('user', { user_id => 1, name => 'inserted' });
is $db->single('user', { user_id => 1 })->name, 'inserted';

done_testing;

0 comments on commit 52c83ea

Please sign in to comment.