Merge pull request #1007 from murz/master

murz's IsAwesome Goodie
master
Chris Wilson 2015-02-14 10:23:59 +08:00
commit b47375023e
2 changed files with 44 additions and 0 deletions

View File

@ -0,0 +1,25 @@
package DDG::Goodie::IsAwesome::murz;
use DDG::Goodie;
zci answer_type => "is_awesome_murz";
zci is_cached => 1;
name "IsAwesome murz";
description "My first Goodie, it lets the world know that murz is awesome";
primary_example_queries "duckduckhack murz";
category "special";
topics "special_interest", "geek";
code_url "https://github.com/duckduckgo/zeroclickinfo-goodies/blob/master/lib/DDG/Goodie/IsAwesome/murz.pm";
attribution github => ["murz", "Mike Murray"];
# Triggers
triggers start => "duckduckhack murz";
# Handle statement
handle remainder => sub {
return if $_;
return "murz is awesome and has successfully completed the DuckDuckHack Goodie tutorial!";
};
1;

19
t/IsAwesome/murz.t Normal file
View File

@ -0,0 +1,19 @@
#!/usr/bin/env perl
use strict;
use warnings;
use Test::More;
use DDG::Test::Goodie;
zci answer_type => "is_awesome_murz";
zci is_cached => 1;
ddg_goodie_test(
[qw(
DDG::Goodie::IsAwesome::murz
)],
'duckduckhack murz' => test_zci('murz is awesome and has successfully completed the DuckDuckHack Goodie tutorial!'),
'duckduckhack murz is awesome' => undef,
);
done_testing;