Branch Coverage

blib/lib/MooseX/Role/MongoDB.pm
Criterion Covered Total %
branch 0 34 0.0


line true false branch
82 0 0 if (exists $$options{'host'})
143 0 0 @args > 1 ? :
176 0 0 $self->_has_mongo_client ? :
182 0 0 if ($$ != $self->_mongo_pid) { }
0 0 elsif (not $is_alpha and $mc and not $mc->connected) { }
183 0 0 unless $is_alpha
190 0 0 if ($reset_reason)
207 0 0 if ($uri =~ m[ ^ mongodb:// (?: ([^:]*) : ([^\@]*) @ )? # [username:password@] ([^/]*) # host1[:port1][,host2[:port2],...[,hostN[:portN]]] (?: / ([^?]*) # /[database] (?: [?] (.*) )? # [?options] )? $ ]x)
232 0 0 unless my $parsed = $self->_parse_connection_uri($uri)
244 0 0 if $err
246 0 0 if defined $ipaddr
248 0 0 unless defined $ipaddr
249 0 0 if defined $port and length $port
255 0 0 if length $$parsed{'username'}
258 0 0 if length $$parsed{'db_name'} or length $$parsed{'options'}
259 0 0 if length $$parsed{'db_name'}
260 0 0 if length $$parsed{'options'}