Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Timestamp for 0.34

A few minor code tweaks. Notably, only disable `with()`'s warnings when our
own tests are running. They should be quite visible for anyone else's tests.
  • Loading branch information...
commit 47cd819718eadb80c6b9906cbfe1cfbefc703ba3 1 parent 6b0e7a4
@theory authored
Showing with 5 additions and 4 deletions.
  1. +1 −1  Changes
  2. +3 −3 lib/DBIx/Connector.pm
  3. +1 −0  t/with.t
View
2  Changes
@@ -1,6 +1,6 @@
Revision history for Perl extension DBIx::Connector.
-0.34
+0.34 2010-05-03T03:15:40
- Added `mode()` attribute to control the default mode used by `run()`,
`txn()`, and `svp()`.
- Deprecated `with()`. Its use triggers a warning and it will be removed
View
6 lib/DBIx/Connector.pm
@@ -117,7 +117,6 @@ sub disconnect {
}
sub _errh {
- # Return $_[1] if $_[0] eq 'catch', $_[0] if it's CODE, else $die.
!$_[0] ? $die
: $_[0] eq 'catch' ? $_[1]
: ref $_[0] eq 'CODE' ? $_[0]
@@ -326,7 +325,7 @@ PROXY: {
sub with {
Carp::carp("DBIx::Connector->with is deprecated. Set the 'mode' attribute instead")
- unless $ENV{HARNESS_ACTIVE};
+ unless $ENV{DBICONNTEST};
DBIx::Connector::Proxy->new(@_)
}
@@ -788,7 +787,8 @@ In this way, you can reliably tell in what mode the code block is executing.
$_->do('UPDATE users SET active = true' );
})
-B<DEPRECATED.> Use the C<mode> accessor, instead.
+B<DEPRECATED.> Will be removed in a future version. Use the C<mode> accessor,
+instead.
Constructs and returns a proxy object that delegates calls to
L<C<run()>|/"run">, L<C<txn()>|/"txn">, and L<C<svp()>|/"svp"> with a default
View
1  t/with.t
@@ -10,6 +10,7 @@ my $CLASS;
BEGIN {
$CLASS = 'DBIx::Connector';
use_ok $CLASS or die;
+ $ENV{DBICONNTEST} = 1;
}
ok my $conn = $CLASS->new( 'dbi:ExampleP:dummy', '', '' ),
Please sign in to comment.
Something went wrong with that request. Please try again.