File: moose.t

package info (click to toggle)
libperl-prereqscanner-notquitelite-perl 0.9917-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 944 kB
  • sloc: perl: 5,239; makefile: 2
file content (40 lines) | stat: -rw-r--r-- 955 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
use strict;
use warnings;
use FindBin;
use lib "$FindBin::Bin/../../";
use Test::More;
use t::Util;

test('both extends and with', <<'END', {'Moose' => 0, 'Test::More' => 0, 'Exporter' => 0});
use Moose;
extends 'Test::More';
with 'Exporter';
END

test('with', <<'END', {'Moo::Role' => 0, 'Test::More' => 0});
use Moo::Role;
with 'Test::More';
END

test('extends', <<'END', {'Mo' => 0, 'Test::More' => 0});
use Mo;
extends 'Test::More';
END

test('Moose-like module that does not have Moose in its name', <<'END', {'Moxie' => 0, 'Test::More' => 0, 'Exporter' => 0});
use Moxie;
extends 'Test::More';
with 'Exporter';
END

test('Moose::Role-like module that does not have Role in its name', <<'END', {'Test::Routine' => 0, 'Test::More' => 0});
use Test::Routine;
with 'Test::More';
END

test('Mo-like module that does not have Moose in its name', <<'END', {'Pegex::Base' => 0, 'Test::More' => 0});
use Pegex::Base;
extends 'Test::More';
END

done_testing;