File: u_bill.t

package info (click to toggle)
libgraph-perl 1%3A0.96-2
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 1,316 kB
  • ctags: 938
  • sloc: perl: 6,094; sh: 8; makefile: 2
file content (16 lines) | stat: -rw-r--r-- 301 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use Test::More tests => 30;

use strict;
use Graph;

my$g = new Graph::Undirected;
$g->add_edges(qw(a1 b1 b1 c1 c1 a1 a2 b2 b2 c2 c2 a2 a1 a2));
$g->add_vertices(1..5);

foreach (1..10) {
    my @b = $g->bridges;
    is(@b, 1);
    my ($u, $v) = sort @{ $b[0] };
    is($u, "a1");
    is($v, "a2");
}