From 4170fb6f2b116ce0af04aaf16308fea698b9b388 Mon Sep 17 00:00:00 2001 From: ilv Date: Wed, 25 Feb 2015 05:02:41 +0000 Subject: [PATCH] Created my first Goodie :D --- lib/DDG/Goodie/IsAwesome/ilv.pm | 24 ++++++++++++++++++++++++ t/IsAwesome/ilv.t | 19 +++++++++++++++++++ 2 files changed, 43 insertions(+) create mode 100644 lib/DDG/Goodie/IsAwesome/ilv.pm create mode 100644 t/IsAwesome/ilv.t diff --git a/lib/DDG/Goodie/IsAwesome/ilv.pm b/lib/DDG/Goodie/IsAwesome/ilv.pm new file mode 100644 index 000000000..cd025da75 --- /dev/null +++ b/lib/DDG/Goodie/IsAwesome/ilv.pm @@ -0,0 +1,24 @@ +package DDG::Goodie::IsAwesome::ilv; +# ABSTRACT: ilv's first Goodie + +use DDG::Goodie; + +zci answer_type => "is_awesome_ilv"; +zci is_cached => 1; + +name "IsAwesome ilv"; +description "My first Goodie, it lets the world know that ilv is awesome"; +primary_example_queries "duckduckhack ilv"; +category "special"; +topics "special_interest", "geek"; +code_url "https://github.com/duckduckgo/zeroclickinfo-goodies/blob/master/lib/DDG/Goodie/IsAwesome/ilv.pm"; +attribution github => ["https://github.com/ilv", "ilv"]; + +triggers start => "duckduckhack ilv"; + +handle remainder => sub { + return if $_; + return "ilv is awesome and has successfully completed the DuckDuckHack Goodie tutorial!"; +}; + +1; diff --git a/t/IsAwesome/ilv.t b/t/IsAwesome/ilv.t new file mode 100644 index 000000000..e048e200d --- /dev/null +++ b/t/IsAwesome/ilv.t @@ -0,0 +1,19 @@ +#!/usr/bin/env perl + +use strict; +use warnings; +use Test::More; +use DDG::Test::Goodie; + +zci answer_type => "is_awesome_ilv"; +zci is_cached => 1; + +ddg_goodie_test( + [qw( + DDG::Goodie::IsAwesome::ilv + )], + 'duckduckhack ilv' => test_zci('ilv is awesome and has successfully completed the DuckDuckHack Goodie tutorial!'), + 'duckduckhack ilv is awesome' => undef, +); + +done_testing;