fixed tests to expect __error__ instead of error mark
[scpubgit/System-Introspector.git] / dev-gather.pl
1 #!/usr/bin/env perl
2 use strictures 1;
3 use lib             qw( lib );
4 use Data::Dump      qw( pp );
5 use Module::Runtime qw( use_module );
6 use Getopt::Long;
7 use Data::YAML::Writer;
8
9 GetOptions(
10     'yaml'  => \(my $opt_yaml),
11 );
12
13 my $intro = shift(@ARGV)
14     or die "Probe argument required\n";
15
16 my $data = use_module("System::Introspector::$intro")->new(@ARGV)->gather;
17 if ($opt_yaml) {
18     my $writer = Data::YAML::Writer->new;
19     my $output = '';
20     $writer->write($data, \$output);
21     print $output;
22 }
23 else {
24     pp $data;
25 }