Created my first Goodie
parent
35980248f6
commit
f21dc6e412
|
@ -0,0 +1,24 @@
|
|||
package DDG::Goodie::IsAwesome::Echosa;
|
||||
|
||||
use DDG::Goodie;
|
||||
|
||||
zci answer_type => "is_awesome_echosa";
|
||||
zci is_cached => 1;
|
||||
|
||||
name "IsAwesome Echosa";
|
||||
description "My first Goodie. It lets the world know that Echosa is awesome.";
|
||||
primary_example_queries "duckduckhack echosa";
|
||||
category "special";
|
||||
topics "special_interest", "geek";
|
||||
code_url "https://github.com/duckduckgo/zeroclickinfo-goodies/blob/master/lib/DDG/Goodie/IsAwesome/Echosa.pm";
|
||||
attribution github => ["https://github.com/echosa", "Echosa"],
|
||||
twitter => "echosa";
|
||||
|
||||
triggers start => "duckduckhack echosa";
|
||||
|
||||
handle remainder => sub {
|
||||
return if $_;
|
||||
return "Echosa is awesome and has successfully completed the DuckDuckHack Goodie tutorial!"
|
||||
};
|
||||
|
||||
1;
|
|
@ -0,0 +1,19 @@
|
|||
#!/usr/bin/env perl
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
use Test::More;
|
||||
use DDG::Test::Goodie;
|
||||
|
||||
zci answer_type => "is_awesome_echosa";
|
||||
zci is_cached => 1;
|
||||
|
||||
ddg_goodie_test(
|
||||
[qw(
|
||||
DDG::Goodie::IsAwesome::Echosa
|
||||
)],
|
||||
'duckduckhack echosa' => test_zci('Echosa is awesome and has successfully completed the DuckDuckHack Goodie tutorial!'),
|
||||
'duckduckhack echosa is awesome' => undef,
|
||||
);
|
||||
|
||||
done_testing;
|
Loading…
Reference in New Issue