use 5.014;
use warnings;
use strict;

use Test::More;

plan tests => 5;

use Alias::Any;

alias my $x = 1;
is $x, 1 => 'alias works';

{
    alias my $z = 9;
    is $z, 9 => 'nested alias works';

    no Alias::Any;

    sub alias {
        is shift, 2 => 'Non-keyword alias sub';
        pass '...works as expected';
    }

    alias my $y = 2;
}

alias my $q = 42;
is $q, 42 => 'alias works again';

done_testing();

