diff --git a/lib/DDG/Goodie/IsAwesome/amneher.pm b/lib/DDG/Goodie/IsAwesome/amneher.pm new file mode 100644 index 000000000..c73f8346c --- /dev/null +++ b/lib/DDG/Goodie/IsAwesome/amneher.pm @@ -0,0 +1,29 @@ +package DDG::Goodie::IsAwesome::amneher; +# ABSTRACT: amneher's first goodie + + +use DDG::Goodie; + +zci answer_type => "is_awesome_amneher"; +zci is_cached => 1; + + +name "IsAwesome amneher"; +description "Tells everyone that I'm awesome"; +primary_example_queries "duckduckhack amneher"; +category "special"; +topics "special_interest", "geek"; +code_url "https://github.com/duckduckgo/zeroclickinfo-goodies/blob/master/lib/DDG/Goodie/IsAwesome/amneher.pm"; +attribution github => ["amneher"], + twitter => "amneher"; + + +triggers start => "duckduckhack amneher"; + + +handle remainder => sub { + return if $_; + return "amneher is awesome and has just completed the duckduckhack goodie tutorial!"; +}; + +1; diff --git a/t/IsAwesome/amneher.t b/t/IsAwesome/amneher.t new file mode 100644 index 000000000..8168b1216 --- /dev/null +++ b/t/IsAwesome/amneher.t @@ -0,0 +1,22 @@ +#!/usr/bin/env perl + +use strict; +use warnings; +use Test::More; +use DDG::Test::Goodie; + +zci answer_type => "is_awesome_amneher"; +zci is_cached => 1; + +ddg_goodie_test( + [qw( DDG::Goodie::IsAwesome::amneher )], + # At a minimum, be sure to include tests for all: + # - primary_example_queries + # - secondary_example_queries + 'duckduckhack amneher' => test_zci('amneher is awesome and has just completed the duckduckhack goodie tutorial!'), + # Try to include some examples of queries on which it might + # appear that your answer will trigger, but does not. + 'duckduckhack amneher is awesome' => undef, +); + +done_testing;