Skip to content
This repository has been archived by the owner on Jan 5, 2023. It is now read-only.

Commit

Permalink
0.27 release
Browse files Browse the repository at this point in the history
  • Loading branch information
Stevan Little committed Jul 11, 2005
1 parent 692ab49 commit 0fc088e
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 6 deletions.
12 changes: 7 additions & 5 deletions Changes
@@ -1,13 +1,15 @@
Revision history for Perl extension DBD::Mock.

0.27
0.27 Mon July 11, 2005
- added NULL_RESULTSET constant
- now allowing errors to be set with mock_add_resultset
see the docs for more information.
- now allowing errors to be set with mock_add_resultset.
Support is currently experimental, see the file
't/023_statement_failure.t' and the EXPERIMENTAL section
of the docs for more information.
- added patch from Collin Winter to fix a bug in
the begin_work(), commit() and rollback() methods
- added patch from <amcharg@acm.org> for the
fetchall_hashref(), fetchrow_hashref() and
- added patch from Andrew McHarg <amcharg@acm.org> for
the fetchall_hashref(), fetchrow_hashref() and
selectcol_arrayref() methods and tests

0.26 Fri Apr 08 2005
Expand Down
14 changes: 13 additions & 1 deletion lib/DBD/Mock.pm
Expand Up @@ -1738,6 +1738,18 @@ All functionality listed here is highly experimental and should be used with gre
=over 4
=item Error handling in I<mock_add_resultset>
We have added experimental erro handling in I<mock_add_resultset> the best example is the test file F<t/023_statement_failure.t>, but it looks something like this:
$dbh->{mock_add_resultset} = {
sql => 'SELECT foo FROM bar',
results => DBD::Mock->NULL_RESULTSET,
failure => [ 5, 'Ooops!' ],
};
The C<5> is the DBI error number, and C<'Ooops!'> is the error string passed to DBI. This basically allows you to force an error condition to occur when a given SQL statement is execute. We are currently working on allowing more control on the 'when' and 'where' the error happens, look for it in future releases.
=item Attribute Aliasing
Basically this feature allows you to alias attributes to other attributes. So for instance, you can alias a commonly expected attribute like 'mysql_insertid' to something DBD::Mock already has like 'mock_last_insert_id'. While you can also just set 'mysql_insertid' yourself, this functionality allows it to take advantage of things like the autoincrementing of the 'mock_last_insert_id' attribute.
Expand Down Expand Up @@ -1828,7 +1840,7 @@ L<http://groups-beta.google.com/group/DBDMock>
=item Thanks to Collin Winter for the patch to fix the C<begin_work()>, C<commit()> and C<rollback()> methods.
=item Thanks to E<lt>amcharg@acm.orgE<gt> for C<fetchall_hashref()>, C<fetchrow_hashref()> and C<selectcol_arrayref()> methods and tests.
=item Thanks to Andrew McHarg E<lt>amcharg@acm.orgE<gt> for C<fetchall_hashref()>, C<fetchrow_hashref()> and C<selectcol_arrayref()> methods and tests.
=back
Expand Down

0 comments on commit 0fc088e

Please sign in to comment.