my $self = shift;
my $dbh = $self->_get_dbh;
+ return if ref $self ne __PACKAGE__;
+
if (not $self->_typeless_placeholders_supported) {
+ require
+ DBIx::Class::Storage::DBI::Sybase::Microsoft_SQL_Server::NoBindVars;
bless $self,
'DBIx::Class::Storage::DBI::Sybase::Microsoft_SQL_Server::NoBindVars';
$self->_rebless;
$schema = DBICTest::Schema->clone;
- if ($storage_idx != 0) { # autodetect
- $schema->storage_type("::$storage_type");
- }
-
$schema->connection($dsn, $user, $pass);
- $schema->storage->ensure_connected;
+ if ($storage_idx != 0) { # autodetect
+ no warnings 'redefine';
+ local *DBIx::Class::Storage::DBI::_typeless_placeholders_supported =
+ sub { 0 };
+# $schema->storage_type("::$storage_type");
+ $schema->storage->ensure_connected;
+ }
+ else {
+ $schema->storage->ensure_connected;
+ }
if ($storage_idx == 0 && ref($schema->storage) =~ /NoBindVars\z/) {
my $tb = Test::More->builder;