Condition Coverage

blib/lib/WWW/Suffit/Server.pm
Criterion Covered Total %
condition 0 146 0.0


and 3 conditions

line !l l&&!r l&&r condition
1271 0 0 0 $self->conf->latest('/log') && $self->conf->latest('/log') =~ /syslog/iu
1414 0 0 0 -e $file and -r $file
1543 0 0 0 $( eq "$gid $gid" and $) eq "$gid $gid"
1547 0 0 0 $< == $uid and $> == $uid
1588 0 0 0 length $token and $token =~ /^[A-Za-z0-9_-]{2,}(?:\.[A-Za-z0-9_-]{2,}){2}$/u
1593 0 0 0 $self->app->debugmode and $token = $self->conf->latest("/token")

or 2 conditions

line l !l condition
1248 0 0 as_hash_ref($opts->{'config_opts'} || $self->config_opts) || {}
1270 0 0 as_hash_ref($opts->{'syslog_opts'} || $self->syslog_opts) || {}
1279 0 0 $self->max_history_size || 25
1341 0 0 as_hash_ref($opts->{'authdb_opts'} || $self->authdb_opts) || {}
1353 0 0 ($authdb_opts->{'cachedconnection'} // $self->conf->latest("/authdbcachedconnection")) // "on"
1361 0 0 as_hash_ref($opts->{'api_routes_opts'} || $self->api_routes_opts) || {}
1363 0 0 as_hash_ref($opts->{'user_routes_opts'} || $self->user_routes_opts) || {}
1365 0 0 as_hash_ref($opts->{'admin_routes_opts'} || $self->admin_routes_opts) || {}
1395 0 0 $self->server_url || 'http://127.0.0.1:8080'
1396 0 0 $self->server_addr || '*'
1397 0 0 $self->server_port || 8080
1405 0 0 $self->conf->latest("/tls_$k") // ""
1407 0 0 $v ||= "0x00"
1411 0 0 $self->conf->latest("/tls_$k") // ""
1425 0 0 as_array_ref($self->conf->list("/listenurl")) // []
1433 0 0 shift() || ''
1575 0 0 $self->req->headers->header("X-Token") // ""
1584 0 0 $self->req->headers->authorization || $self->req->env->{'X_HTTP_AUTHORIZATION'} || $self->req->env->{'HTTP_AUTHORIZATION'} || ''
1597 0 0 $token // ""
1609 0 0 shift() || 12
1618 0 0 $rsa->private_key // ""
0 0 $rsa->public_key // ""
1620 0 0 $rsa->key_size // "?"
1630 0 0 $self->req->headers->header("User-Agent") // "unknown"
1631 0 0 $self->remote_ip($self->app->trustedproxies) || $self->tx->remote_address || '::1'

or 3 conditions

line l !l&&r !l&&!r condition
1245 0 0 0 $opts->{'all_features'} // $self->all_features
1279 0 0 0 $self->loglevel || ($self->debugmode ? 'debug' : 'warn')
1317 0 0 0 $opts->{'init_rsa_keys'} // $self->init_rsa_keys
0 0 0 $all_features or is_true_flag($opts->{'init_rsa_keys'} // $self->init_rsa_keys)
1318 0 0 0 $self->conf->latest('/privatekeyfile') || path($self->datadir, 'rsa-private.key')->to_string
1319 0 0 0 $self->conf->latest('/publickeyfile') || path($self->datadir, 'rsa-public.key')->to_string
1320 0 0 0 -r $private_key_file || -r $public_key_file
1339 0 0 0 $opts->{'init_authdb'} // $self->init_authdb
0 0 0 $all_features or is_true_flag($opts->{'init_authdb'} // $self->init_authdb)
1344 0 0 0 $authdb_opts->{'uri'} || $authdb_opts->{'url'} || $self->conf->latest('/authdburl') || $self->conf->latest('/authdburi') || "sqlite://$authdb_file?sqlite_unicode=1"
1346 0 0 0 $self->conf->latest('/authdbcacheexpire') || $self->conf->latest('/authdbcacheexpiration')
1353 0 0 0 $authdb_opts->{'cachedconnection'} // $self->conf->latest("/authdbcachedconnection")
0 0 0 $authdb_opts->{'cacheexpire'} || $authdb_opts->{'cacheexpiration'} || (defined $cacheexpiration ? parse_time_offset($cacheexpiration) : undef)
0 0 0 $authdb_opts->{'cachemaxkeys'} || $self->conf->latest('/authdbcachemaxkeys')
0 0 0 $authdb_opts->{'sourcefile'} || $self->conf->latest('/authdbsourcefile')
1361 0 0 0 $opts->{'init_api_routes'} // $self->init_api_routes
0 0 0 $all_features or is_true_flag($opts->{'init_api_routes'} // $self->init_api_routes)
1363 0 0 0 $opts->{'init_user_routes'} // $self->init_user_routes
0 0 0 $all_features or is_true_flag($opts->{'init_user_routes'} // $self->init_user_routes)
1365 0 0 0 $opts->{'init_admin_routes'} // $self->init_admin_routes
0 0 0 $all_features or is_true_flag($opts->{'init_admin_routes'} // $self->init_admin_routes)
1398 0 0 0 $self->conf->latest('/listenaddr') || $host
1399 0 0 0 $self->conf->latest('/listenport') || $port
1473 0 0 0 $upgrade ||= &steady_time()
1506 0 0 0 $upgrade ||= &steady_time()
1614 0 0 0 shift() || $self->app->rsa_keysize