zeroclickinfo-goodies/t/Regexp.t

33 lines
672 B
Perl
Raw Normal View History

2013-03-11 13:27:50 -07:00
#!/usr/bin/env perl
use strict;
use warnings;
use Test::More;
use DDG::Test::Goodie;
zci answer_type => 'regexp';
zci is_cached => 1;
2013-03-11 13:27:50 -07:00
ddg_goodie_test(
[qw( DDG::Goodie::Regexp )],
'regexp /(hello\s)/ hello probably' => test_zci(
"hello ",
heading => 'Regexp Result',
2013-03-11 13:27:50 -07:00
),
'regexp /(dd)/ ddg' => test_zci(
"dd",
heading => 'Regexp Result',
2013-03-11 13:27:50 -07:00
),
'regex /(poss)/ many possibilities' => test_zci(
"poss",
heading => 'Regexp Result',
),
'regexp /(.*)/ ddg' => test_zci(
2014-10-28 11:36:15 -07:00
'ddg',
heading => 'Regexp Result'
),
2013-03-11 13:27:50 -07:00
);
done_testing;