Commit | Line | Data |
7f52eac8 |
1 | #!/usr/bin/perl -w |
2 | |
3 | use strict; |
4 | use Test::More 'no_plan'; |
5 | $| = 1; |
6 | |
7 | |
8 | |
9 | # =begin testing |
10 | { |
11 | use Text::Tradition; |
12 | use Text::Tradition::Analysis qw/ run_analysis analyze_variant_location /; |
13 | |
14 | my $datafile = 't/data/florilegium_tei_ps.xml'; |
15 | my $tradition = Text::Tradition->new( 'input' => 'TEI', |
16 | 'name' => 'test0', |
17 | 'file' => $datafile ); |
18 | my $s = $tradition->add_stemma( 'dotfile' => 't/data/florilegium.dot' ); |
19 | is( ref( $s ), 'Text::Tradition::Stemma', "Added stemma to tradition" ); |
20 | |
21 | my $data = run_analysis( $tradition ); |
5be0cdeb |
22 | # TODO Check genealogical count |
23 | is( $data->{'genealogical_count'}, 13, "Got right genealogical count" ); |
24 | is( $data->{'conflict_count'}, 16, "Got right conflict count" ); |
25 | is( $data->{'variant_count'}, 28, "Got right total variant number" ); |
7f52eac8 |
26 | } |
27 | |
28 | |
29 | |
30 | |
31 | 1; |