{
ok(my $index = List::Index->new(['aa'..'zz', 1..193]), 'non-alphabetic values (uniform)');
is_deeply($index->ranges, [map { [split /-/, $_, 2] } qw(
{
ok(my $index = List::Index->new(['aa'..'zz', 1..193]), 'non-alphabetic values (uniform)');
is_deeply($index->ranges, [map { [split /-/, $_, 2] } qw(
a-bv bw-dr ds-fn fo-hk hl-jg jh-k l-m n-ov ow-qr qs-sn so-uk ul-wg wh-x y-
)], 'default ranges');
is_deeply($index->ranges({pagesize => 300}), [map { [split /-/, $_, 2] } qw(
a-bv bw-dr ds-fn fo-hk hl-jg jh-k l-m n-ov ow-qr qs-sn so-uk ul-wg wh-x y-
)], 'default ranges');
is_deeply($index->ranges({pagesize => 300}), [map { [split /-/, $_, 2] } qw(
map { [split /-/, $_, 2] } qw(b-baa baa.-ba bb-c d-ea. eaa-)
], 'default context'); # context should be 1
is_deeply($index->ranges({pagesize => 2, context => 2}), [
map { [split /-/, $_, 2] } qw(b-baa baa.-ba bb-c d-ea. eaa-)
], 'default context'); # context should be 1
is_deeply($index->ranges({pagesize => 2, context => 2}), [
], 'overlap'); # first item equals second due to large context
is_deeply($index->ranges({pagesize => 2, length => 1}), [
], 'overlap'); # first item equals second due to large context
is_deeply($index->ranges({pagesize => 2, length => 1}), [