Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 29 lines (20 sloc) 0.952 kb
f42ca42 [t/spec] new file S02-builtin_data_types/parcel.t
moritz authored
1 use v6;
2 use Test;
3
73296d8 Carl Mäsak [S02-types/parcel.t] added test about zen slicing
masak authored
4 plan 14;
f42ca42 [t/spec] new file S02-builtin_data_types/parcel.t
moritz authored
5
6 isa_ok (5, 7, 8), Parcel, '(5, 7, 8) is Parcel';
7 is +(5, 7, 8), 3, 'prefix:<+> on a Parcel';
8 is ~(5, 7, 8), '5 7 8', 'prefix:<~> on a Parcel';
9 is (5, 7, 8).Str, '5 7 8', '.Str on a Parcel';
10
75bf7cb Matthew Wilson fix all the remaining S02/Literals smartlinks I broke by adding headings...
diakopter authored
11 # L<S02/Quoting forms/Elsewhere it is equivalent to a parenthesized list of strings>
f42ca42 [t/spec] new file S02-builtin_data_types/parcel.t
moritz authored
12
13 isa_ok <5 7 8>, Parcel, '<5 7 8> is Parcel';
14 is +<5 7 8>, 3, 'prefix:<+> on an angle bracket Parcel';
15 is ~<5 7 8>, '5 7 8', 'prefix:<~> on an angle bracket Parcel';
16 is <5 7 8>.Str, '5 7 8', '.Str on an angle bracket Parcel';
17
6a6cd4f Will Coleda niecza fudging
coke authored
18 #?niecza 3 skip 'Unable to resolve method Array in class Parcel'
3977901 Patrick Abi Salloum Added tests for RT86764 Array method on parcel
patrickas authored
19 isa_ok (5, 7, 8).Array, Array, '.Array returns an array';
20 is (5, 7, 8).Array, [5,7,8], '.Array contains the right items';
21 is (5, 7, 8).Array.elems, 3, '.Array contains the right number of elements';
22
8d1595b Patrick R. Michaud Add tests for Parcel.Bool.
pmichaud authored
23 is ?(), False, 'empty Parcel is False';
24 is ?(1,2,3), True, 'non-empty Parcel is True';
25
73296d8 Carl Mäsak [S02-types/parcel.t] added test about zen slicing
masak authored
26 lives_ok { <5 7 8>[] }, 'can zen slice a Parcel';
f42ca42 [t/spec] new file S02-builtin_data_types/parcel.t
moritz authored
27
28 # vim: ft=perl6
Something went wrong with that request. Please try again.