test: removed lowercase goodie

master
Zaahir Moolla 2015-11-04 13:42:03 -05:00
parent 7b9ab804df
commit d65fc92031
2 changed files with 0 additions and 117 deletions

View File

@ -1,36 +0,0 @@
package DDG::Goodie::Lowercase;
# ABSTRACT: Convert a string into lowercase.
use strict;
use DDG::Goodie;
name "Lowercase";
description "Convert a string into lowercase.";
primary_example_queries "lowercase GitHub";
secondary_example_queries "lower case GitHub";
category 'conversions';
topics 'programming';
code_url 'https://github.com/duckduckgo/zeroclickinfo-goodies/blob/master/lib/DDG/Goodie/Lowercase.pm';
attribution github => ["https://github.com/DavidMascio", "DavidMascio"];
zci answer_type => "lowercase";
zci is_cached => 1;
triggers start => 'lowercase', 'lower case', 'lc', 'strtolower', 'tolower';
handle remainder => sub {
my $input = shift;
return unless $input;
my $lower = lc $input;
return $lower,
structured_answer => {
input => [html_enc($input)],
operation => 'Lowercase',
result => html_enc($lower)
};
};
1;

View File

@ -1,81 +0,0 @@
#!/usr/bin/env perl
use strict;
use warnings;
use Test::More;
use DDG::Test::Goodie;
zci answer_type => 'lowercase';
zci is_cached => 1;
ddg_goodie_test(
['DDG::Goodie::Lowercase'],
'lowercase foo' => test_zci(
'foo',
structured_answer => {
input => ['foo'],
operation => 'Lowercase',
result => 'foo'
},
),
'lower case foO' => test_zci(
'foo',
structured_answer => {
input => ['foO'],
operation => 'Lowercase',
result => 'foo'
},
),
'lowercase john Doe' => test_zci(
'john doe',
structured_answer => {
input => ['john Doe'],
operation => 'Lowercase',
result => 'john doe'
},
),
'lowercase GitHub' => test_zci(
'github',
structured_answer => {
input => ['GitHub'],
operation => 'Lowercase',
result => 'github'
},
),
'lower case GitHub' => test_zci(
'github',
structured_answer => {
input => ['GitHub'],
operation => 'Lowercase',
result => 'github'
},
),
'lc GitHub' => test_zci(
'github',
structured_answer => {
input => ['GitHub'],
operation => 'Lowercase',
result => 'github'
},
),
'strtolower GitHub' => test_zci(
'github',
structured_answer => {
input => ['GitHub'],
operation => 'Lowercase',
result => 'github'
},
),
'tolower GitHub' => test_zci(
'github',
structured_answer => {
input => ['GitHub'],
operation => 'Lowercase',
result => 'github'
},
),
'how to lowercase text' => undef
);
done_testing;