Created my first Goodie

master
fabrgu 2015-05-19 11:36:42 +00:00
parent 204244f6c2
commit 7cb2d879e6
2 changed files with 42 additions and 0 deletions

View File

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

17
t/IsAwesome/fabrgu.t Normal file
View File

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