ヤミRoot VoidGate
User / IP
:
216.73.216.2
Host / Server
:
146.88.233.70 / dev.loger.cm
System
:
Linux hybrid1120.fr.ns.planethoster.net 3.10.0-957.21.2.el7.x86_64 #1 SMP Wed Jun 5 14:26:44 UTC 2019 x86_64
Command
|
Upload
|
Create
Mass Deface
|
Jumping
|
Symlink
|
Reverse Shell
Ping
|
Port Scan
|
DNS Lookup
|
Whois
|
Header
|
cURL
:
/
home
/
itrave
/
.cpanm
/
work
/
1568630761.27314
/
Specio-0.44
/
t
/
Viewing: builtins.t
use strict; use warnings; use utf8; use open ':encoding(UTF-8)', ':std'; use Test::More 0.96; use Specio::Declare; use Specio::Library::Builtins; use Specio::PartialDump qw( partial_dump ); { my $str = t('Str'); isa_ok( $str, 'Specio::Constraint::Simple' ); like( $str->declared_at->filename, qr/Builtins\.pm/, 'declared_at has the right filename' ); for my $value ( q{}, 'foo', 'bar::baz', "\x{3456}", 0, 42 ) { ok( $str->value_is_valid($value), partial_dump($value) . ' is a valid Str value' ); } ## no critic (TestingAndDebugging::ProhibitNoWarnings) no warnings 'once'; ## use critic my $foo = 'foo'; for my $value ( undef, \42, \$foo, [], {}, sub { }, *glob, \*globref ) { ok( !$str->value_is_valid($value), partial_dump($value) . ' is not a valid Str value' ); } } is( t('Str')->parent->name, 'Value', 'parent of Str is Value' ); my $str_clone = t('Str')->clone; for my $name (qw( Str Value Defined Item )) { ok( t('Str')->is_a_type_of( t($name) ), "Str is_a_type_of($name)" ); next if $name eq 'Str'; ok( $str_clone->is_a_type_of( t($name) ), "Str clone is_a_type_of($name)" ); } for my $name (qw( Maybe ArrayRef Object )) { ok( !t('Str')->is_a_type_of( t($name) ), "Str ! is_a_type_of($name)" ); ok( !$str_clone->is_a_type_of( t($name) ), "Str clone ! is_a_type_of($name)" ); } for my $type ( t('Str'), $str_clone ) { ok( $type->is_same_type_as( t('Str') ), $type->name . ' is_same_type_as Str' ); } { my $child = anon( parent => t('Str') ); ok( $child->can_be_inlined, 'child of builtin with no additional constraint can be inlined' ); } done_testing();
Coded With 💗 by
0x6ick