Commit Graph

2986 Commits (80d837cd65c4e00e156bc5b92535ef5216dc84cd)

Author SHA1 Message Date
Rob Emery a8071eb7ed HelpLine: Updating tests to use Test::Deep and text template 2016-05-16 20:53:04 +01:00
Rob Emery a3c7fe52fe MacAddress: Working template and tests 2016-05-16 20:32:50 +01:00
Ben Moon 3b32b27bc8 LeetSpeak: Convert to Text Template (#3073)
LeetSpeak: Converting to Text Template
2016-05-16 19:52:13 +01:00
rgaul 7e056981e9 Merge remote-tracking branch 'upstream/master' into issue-2002 2016-05-16 16:56:15 +00:00
rgaul 0616988280 Improve unit test code 2016-05-16 16:53:38 +00:00
Ben Moon 83b9bbd6b7 Fix newline at end of file 2016-05-16 14:19:39 +01:00
Ben Moon 5f85cf4121 Update Goodies to use Test::Deep
* Ensure Test::Deep is imported.

* Replace '-ANY-' with ignore()

* Replace regexes with re(...)
2016-05-16 14:07:57 +01:00
Rob Emery f4119f7fbf LeetSpeak: Updating tests for text template 2016-05-16 13:18:14 +01:00
Rob Emery 0ca397ab70 Kana: Updating tests for text template 2016-05-16 13:08:20 +01:00
rgaul f9685a9f25 Convert to structured text template 2016-05-15 23:16:03 +00:00
Rob Emery 8cbcdf66ed Fibonacci: Refactoring tests 2016-05-15 21:59:15 +01:00
Ben Moon 8eeddb5c19 Merge pull request #3064 from duckduckgo/mintsoft/GenerateMAC-template
GenerateMAC: Switching to text template
2016-05-15 20:05:22 +01:00
Rob Emery 58ce9b09c9 Fortune: Switching to text template (#3063)
* Fortune: Switching to text template

* Fortune: Adding subtitle and using Test::Deep
2016-05-15 20:01:11 +01:00
Rob Emery 0d73da25b2 Jira: Fixing options->group; this should be content 2016-05-15 19:33:20 +01:00
Rob Emery 104b963bca GenerateMAC: Switching out to use Test::Deep 2016-05-15 19:22:30 +01:00
Rob Emery 5f87fa6b38 JIRA: updating tests for template 2016-05-15 18:50:49 +01:00
Rob Emery 536c21c1eb Switching JIRA to text template 2016-05-15 18:46:11 +01:00
Rob Emery 057511dc7b ISO639: Converting to text template 2016-05-15 18:38:40 +01:00
Rob Emery 3349534b76 Factors: Convert to text template (#3061) 2016-05-15 18:38:30 +01:00
Rob Emery fb88949c44 GenerateMAC: Switching tests to Test::Deep and text template 2016-05-15 18:12:51 +01:00
Rob Emery 24b58cddd3 Fibonacci: Extending test coverage around question formats 2016-05-15 17:57:14 +01:00
Rob Emery 8d52252fe0 Fibonacci: Converting to Text Template 2016-05-15 17:54:04 +01:00
Rob Emery 0cc555fe1b HexToDec: Convert to text template (#3054)
* HexToDec: Converting to text template

* HexToDec: Refactoring tests
2016-05-15 17:13:24 +01:00
Rob Emery 348df8e526 POTUS: Flipping out to text template (#3053)
* POTUS: Flipping out to text template

* POTUS: Tests should be calling `build_test` :)

* POTUS: Test refactor
2016-05-14 23:32:11 +01:00
Rob Emery 707350bf90 Combination: Switching to text template (#3058) 2016-05-14 23:04:54 +01:00
Rob Emery 0e438ddc08 Uppercase: Converting to text template (#3057) 2016-05-14 22:52:17 +01:00
Rob Emery 6a2fdedbf6 Lowercase: Flipping out to Text template (#3055)
* Lowercase: Flipping out to Text template
2016-05-14 22:46:41 +01:00
Rob Emery ad089234ae Titlecase: Converting to text template (#3056) 2016-05-14 22:44:23 +01:00
Rob Emery 39b44adc0c Constants: Switching to customised template 2016-05-14 20:30:39 +01:00
Rob Emery 683018f4a1 Constants: It's crap that the IA currently returns HTML for the plain answer; no remedied 2016-05-14 20:26:09 +01:00
Rob Emery abd685d3ae Constants: Switching to text template 2016-05-14 20:21:54 +01:00
Ben Moon da3c7b26c7 Fix test for real numbers (#3049)
Wasn't allowing the case for numbers like `1.3e-7`.
2016-05-14 19:14:43 +01:00
Naveen Karippai af18492b8a Convert simple structured to full template goodie (#3000)
* Convert simple structured to full template goodie

Goodies have full support for templates, and it'd be great to make sure all
Goodies use full templates. The "simple structured_answer" was provided
as a way to get goodies using basic templates before they had full template
support.

* change to 'text' template for structured_answer object

* refactored test suite

* added alias and removed encode

See also: Updates FlipText Goodie Re: #2767

IA: https://duck.co/ia/view/flip_text

* Remove unnecessary trigger words on flipText goodie

There were trigger words added to flipText goodie which may not be
used or confuse the search results. This should be removed.

* extra triggers removed

See also: Updates FlipText Goodie Re: #2767

* Indent code on FlipText goodie

It would be easier to eyes in the long run to understand
code when it's properly indented.

* code indented on .pm and .t
2016-05-14 19:00:12 +01:00
Ben Moon e271760377 GreatestCommonFactor: Update tests to use 'build_test' (#3048)
* Update tests to use 'build_test'

* Fix indenting
2016-05-14 18:42:58 +01:00
Roy Kokkelkoren 289948173d GreatestCommonFactor: Use Math::BigInt & change to text template (#2990)
* Removed custom GCD function replaced with library function

* Changed view to text template and updated tests

* Cleanup of tests and removed unnecessary code
2016-05-14 18:28:04 +01:00
Ben Moon 0d1c29d08c Add test for postfix form 2016-05-14 17:17:04 +01:00
Ben Moon 07dc434bf8 Ensure no triggering on empty remainder 2016-05-14 17:15:45 +01:00
Ben Moon ba3c840566 Ensure we don't trigger if we've nowt to shuffle
shuffle xs | length xs <= 1 = xs forall xs

That says it all.
2016-05-14 17:11:50 +01:00
Ben Moon 775c1e0f49 Add Shuffle Instant Answer
Allows shuffling of random inputs (mainly lists).
2016-05-14 17:10:31 +01:00
Naveen Karippai 6df517e87a Convert RandomNumbers to full template goodie (#3014)
* Convert RandomNumbers to full template
2016-05-14 12:17:47 +01:00
rgaul 0a05b287e7 Fixup regex with unit test validation 2016-05-14 02:29:50 +00:00
Ben Moon d115e04a95 Add check for IA page existence
We check to make sure that an IA page with the correct ID exists.
2016-05-13 18:28:31 +01:00
Zaahir Moolla 58eeb27ea5 Merge pull request #2811 from lamanh/fix_2771
Braille: fix for bad triggers #2771
2016-05-12 15:51:46 -07:00
Zach Thompson 1c7e2cca44 Merge pull request #2777 from duckduckgo/gd/cheatsheets-add-ignore
CheatSheets: Add 'ignore' attribute
2016-05-12 14:23:38 -06:00
Naveen Karippai a426dccaf5 Convert CountryCodes to full template goodie (#3037)
Goodies have full support for templates, and it'd be great
to make sure that all goodies use full templates.
The "simple structured_answer" was provided as a temporary
workaround.

* change to 'text' template for structured_answer object

* refactored test suite

See also: Updates CountryCodes Goodie Re: #2767
2016-05-12 14:23:28 +01:00
Ben Moon 3a0e90fb62 Merge pull request #3019 from duckduckgo/mintsoft/conversions/plurals
Conversions: Harmonise unit definitions
2016-05-11 20:42:26 +01:00
Rob Emery 10eac5a798 Conversions: Adding tests around singular for mmHg 2016-05-11 20:03:11 +01:00
Rob Emery 54ef078da5 Conversions: Singular test for ton of TNT 2016-05-11 18:54:16 +01:00
Rob Emery 3831d2bf71 Conversions: Fixing tnt vs TNT for @guiltydolphin 2016-05-11 18:45:02 +01:00
Rasika Pohankar 9b5d96c5c3 Update ValarMorghulis to use full template. (#3034) 2016-05-11 12:43:08 +01:00
Rasika Pohankar d2996bf4d5 Birthstone: Convert to full template (#2807)
* Added plaintext response.

* Removed id and name.

* Fixed alignment.

* Changed subtitle to Birthstone for month.

* Changed subtitle in test file.
2016-05-10 22:00:42 +01:00
Ben Moon a459531950 Remove trailing white space 2016-05-10 21:46:51 +01:00
Rasika Pohankar 16f3fd4599 Zapp Brannigan: Convert to full template (#2994)
* Change to full template, add handlebars file for new line in quote.

* Change data to -ANY- in test file.

* Replace regex with re().
2016-05-10 21:41:54 +01:00
Ben Moon 5e7d85e4a2 Update tests to include title_content 2016-05-10 17:52:26 +01:00
Ben Moon e194090d0c Update CalcRoots to use full template 2016-05-10 17:52:26 +01:00
Rob Emery 9517ba17ce Merge pull request #2980 from rkokkelk/rkokkelk/unixtime
UnixTime: Expanded trigger words
2016-05-09 22:29:38 +01:00
Rob Emery 3085cef17a Conversions: Again I think the intent behind the query `ml in gallons` is "how many ml are there in a gallon?" 2016-05-09 20:11:38 +01:00
Rob Emery a76e193f8d Conversions: I think the query how many cm in metres should return the answer "1 meter = 100cm" 2016-05-09 20:09:58 +01:00
Rob Emery e684a14a5f Conversions: TNT will always be returned as tnt now 2016-05-09 20:03:19 +01:00
Ben Moon dc299832d7 Ensure all invalid aliases are in test results
Only the first alias was showing, we ensure that *all* aliases that fail
the tests are shown.
2016-05-09 18:43:27 +01:00
Ben Moon a85b5352a6 Make ignore test critical 2016-05-09 18:43:27 +01:00
Ben Moon eefe68af55 Add tests for ignored phrases in aliases
Emit a warning if the user defines an alias that contains an ignored
phrase.
2016-05-09 18:43:27 +01:00
Ben Moon 0e1ff0e524 Ensure tests are *fully* alphabetically sorted
Issue with language cheat sheets being lexically sorted under 'l', and
thus being inserted halfway(ish) through the tests. Feexed.
2016-05-09 18:43:27 +01:00
Ben Moon d6785cb5ab Ensure tests are alphabetical
Easier to read and locate cheat sheets when tests are alphabetical.
2016-05-09 18:43:27 +01:00
Rob Emery 2540ff11b1 Mintsoft/conversions/squarefeet (#3006)
* Conversions: The plural of square foot is square feet NOT square foots

* Conversions: Fixing test for #3004
2016-05-08 11:25:12 +01:00
Rob Emery 0ea9f866e4 Merge pull request #2965 from dbech/HexToASCII
hex_to_ascii: Improved triggers
2016-05-04 08:10:42 +01:00
Daniel Bech 77a76939b0 Formatting
aligned some thingers
2016-05-01 23:00:53 +08:00
Daniel Bech 2273cc50a5 Updated to test with template
Updated to test full template instead of simple structured answer
2016-05-01 22:54:40 +08:00
Daniel Bech bc37677437 added new tests
More test cases for more triggers
2016-05-01 21:29:43 +08:00
Daniel Bech 33eb782ab9 Added new test cases
Added new test cases for coin flip and coin toss
2016-05-01 20:49:18 +08:00
rkokkelkoren 674368b2b4 Expanded trigger words 2016-04-30 20:23:56 +00:00
Rob Emery 2f507bb307 Merge pull request #2956 from zblair/master
Conversions: Add conversions for grains, carats, drams, cc's, cubic inches, mmHg, decades, centuries, millennia, and thousandths of an inch
2016-04-30 20:20:15 +01:00
zblair cced8f79d9 Add a trailing comma to the last element in a list 2016-04-30 16:43:12 +00:00
zblair ff1fd34b1b Added some additional unit tests 2016-04-30 08:59:03 +00:00
zblair 3c5fb4963e Make sure that existing unit tests pass, and add new unit tests for newly added units. 2016-04-30 08:32:09 +00:00
Zach Thompson e351aa79b1 Merge pull request #2959 from duckduckgo/gd/cheatsheets-no-test-data
CheatSheets: Have tests only check ID rather than all data
2016-04-29 14:16:37 -06:00
Ben Moon c2ecd68703 Have tests only check ID rather than all data
We don't need to check the data and it slows down the tests, it is
sufficient to check that it triggered and has the correct ID.
2016-04-29 14:34:49 +01:00
Laman 7316cc7290 NoteFrequency: Update to full template (#2838)
* NoteFrequency: Update to full template

* remove html_enc for frequency.
2016-04-28 19:32:23 +01:00
Hugo Thiessard c55ecbe885 Updates AspectRatio Goodie Re: #2767 (#2843) 2016-04-28 19:30:29 +01:00
Hugo Thiessard c54a2b94d8 Updates CalendarConversion Goodie Re #2767 (#2862) 2016-04-28 19:28:56 +01:00
Hugo Thiessard 1535f2117a Updates Base64 Goodie Re: #2767 (#2854) 2016-04-28 19:26:35 +01:00
Hugo Thiessard 1789d18039 Updates CallingCodes Goodie Re #2767 (#2864) 2016-04-28 19:25:14 +01:00
Hugo Thiessard 2b0d873016 Updates Base Goodie Re: #2767 (#2853) 2016-04-28 19:24:01 +01:00
Hugo Thiessard bb46c37055 Updates Bitsum Goodie Re #2767 (#2860) 2016-04-28 19:22:50 +01:00
Hugo Thiessard 578f496f6b Updates Chars Goodie Re #2767 (#2865) 2016-04-28 19:21:31 +01:00
Hugo Thiessard 34fb831587 Updates Binary Goodie Re #2767 (#2859) 2016-04-28 19:17:57 +01:00
Hugo Thiessard 59737a40f8 Updates Average Goodie Re #2767 (#2858) 2016-04-28 19:00:13 +01:00
David Wilkins f59b014114 ConvertLatLon: Replace minus sign with hyphen (#2920) (#2926) 2016-04-28 18:47:14 +01:00
Daniel Davis ccecdc2373 Constants: Increased display priority (#2939)
* Constants: Increased display priority

* Constants: Updated test file to reflect backend changes
2016-04-28 18:40:57 +01:00
Roysten 1dfa579beb Fix tests after changing Perl module 2016-04-26 19:32:38 +00:00
Ben Moon 04cc7aec06 Merge pull request #2925 from duckduckgo/mintsoft/potus-fix
POTUS: Fixes #1863
2016-04-24 21:08:54 +01:00
Rob Emery da43a1a55c Merge pull request #2791 from t2013anurag/independec-day-more-add
Independence Day: Add missing countries
2016-04-24 20:56:47 +01:00
Rob Emery aba6abf7f2 POTUS: adding failing tests for vice president queries (#1863) 2016-04-24 20:27:37 +01:00
rgaul 6e93004eb4 Leverage DateTime era in order to get AD/BC info 2016-04-23 18:18:08 +00:00
Roysten e74ba78732 Merge branch 'master' into 2048 2016-04-19 18:24:37 +00:00
Rob Emery f754a300e1 Merge pull request #2711 from swapagarwal/stardate
New Stardate Goodie
2016-04-17 21:34:02 +01:00
sagarwal c675032629 Return if datetime can't be parsed 2016-04-17 20:11:37 +00:00
rgaul 11e8b96ce9 Fixes per testing 2016-04-17 15:50:39 +00:00
rpohankar 5bc44dce2f Added invalid query example, moved variables inside subroutine. 2016-04-16 17:00:55 +00:00
rpohankar 8349c130f9 Added correct values in test file. 2016-04-16 15:20:05 +00:00
rpohankar 2847eb3e43 Added test file. 2016-04-16 08:22:29 +00:00
sagarwal bcc5c59dee Update tests to reflect new functionality (Dates GoodieRole) 2016-04-13 09:30:48 +00:00
Anurag Tiwari e10b44ace1 Update IndependenceDay.t 2016-04-13 00:13:47 +05:30
t2013anurag e88cc9a43a lativa fix 2016-04-13 00:08:41 +05:30
Anurag Tiwari 1b68511723 Update IndependenceDay.t 2016-04-12 23:58:51 +05:30
t2013anurag aeb77941f6 Tests 2016-04-12 23:52:42 +05:30
Rob Emery c562de44fa Timediff: Tabs to spaces 2016-04-11 21:23:48 +01:00
Rob Emery c6f2834ed4 Timediff: Relative date tests 2016-04-09 16:58:37 +01:00
Rob Emery 2312743391 Timediff: updating tests with title 2016-04-09 16:39:13 +01:00
Rob Emery 89e73e431e Timediff: Moar tests as requested! 2016-04-09 15:25:16 +01:00
Rob Emery aa4b771f86 Timediff: Updating tests with triggers and Role supported formats 2016-04-09 15:20:14 +01:00
Rob Emery b5756fe3ce Timediff: Record Template + NumberStyler integration 2016-04-08 20:58:23 +01:00
Rob Emery 997ba24bbc TimeDiff: difference is scalar 2016-04-08 20:30:39 +01:00
Rob Emery 3b3af464aa Timediff: Fixing copy-paste error from Conversions Tests 2016-04-08 20:25:02 +01:00
Rob Emery 405bf3f914 Timediff: Tests were failing due to being invalid; not because of unimplemented behaviour 2016-04-08 20:24:15 +01:00
Rob Emery 3fd35d5c97 TimeDiff: Adding failing test 2016-04-08 20:23:30 +01:00
Matthew Ramina fbbf262a97 Stopwatch: remove id and name 2016-04-07 21:53:39 -04:00
Matthew Ramina 6b71565d6e Port stopwatch to goodie
move all logic to an onShow
2016-04-07 19:53:55 -04:00
Zaahir Moolla 430a48d726 HTML Encode title/subtile for URLEncode and URLDecode 2016-04-06 21:14:54 -04:00
Zach Thompson ce74963b7b Values too?! 2016-04-06 14:57:43 -06:00
Zach Thompson a3fe248ac4 One more each on ref! 2016-04-06 14:35:07 -06:00
ehuang 59de6b6b1b Update subtitle string and add html_enc for input. 2016-04-06 06:35:47 +00:00
Rob Emery f2f4490e28 Conversions: Improving accuracy in definitions and fixing unit mistakes in test 2016-04-03 16:23:38 +01:00
Rob Emery fe06b4711d Conversions: Adding failing tests for accuracy around mph 2016-04-03 16:11:30 +01:00
Roysten 9266d44fdc Merge branch 'pr/1885' into 2048rewrite 2016-04-03 09:59:55 +00:00
Zaahir Moolla ed9ed29bba Merge pull request #2737 from duckduckgo/mintsoft/conversions/speed
Conversions: now supports speed!
2016-04-01 15:44:09 -04:00
Zaahir Moolla 4050a5dffc Merge pull request #1968 from cngarrison/day-of-week
New Day of Week Goodie
2016-04-01 11:47:57 -04:00
ehuang 4fcf581e30 Update CoffeeToWaterRatio to new template.
https://duck.co/ia/view/coffee_to_water_ratio
2016-04-01 08:19:10 +00:00
Zaahir Moolla b53e159c84 Merge pull request #2684 from amoraleda/amoraleda/WhereAmI
WhereAmI: Map template added
2016-04-01 00:01:20 -04:00
Ben Moon 7b183f5e65 Merge pull request #2816 from swapagarwal/2767/beam-me-up-scotty
Update Beam Me Up Scotty Goodie Re: #2767
2016-03-31 09:47:41 +01:00
sagarwal ee172f8986 Update Beam Me Up Scotty Goodie Re: #2767 2016-03-30 18:29:58 +00:00
ehuang 0ad0890f84 Structured Answer to Full Templates.
Update test as well.
2016-03-30 03:55:05 +00:00
Zaahir Moolla 621a5f4f71 Remove bignum from is_cached in PrimeFactors.t 2016-03-29 22:17:31 -04:00
Zaahir Moolla f92c75cf75 Merge pull request #2405 from swapagarwal/beam-me-up-scotty
New Star Trek Code Phrase
2016-03-29 15:36:32 -04:00
Ben Moon c50527c85c Allow after/before forms
So you can do things like '3 days before today'.
2016-03-27 10:31:15 +01:00
Ben Moon 5d99a64f72 Remove 'name' and 'id' from structured answer 2016-03-24 15:12:54 +00:00
Ben Moon 51094ce606 Update Anagrams to use a full template
Chose the 'text' template.

Although it sometimes returns a list of items, it doesn't seem like a
list template would fit here. I think the formatting would work out best
with the 'text' template. We'll find out on Beta I guess ;)
2016-03-24 14:53:47 +00:00
Zaahir Moolla 88d49758b6 Merge pull request #2773 from duckduckgo/zt/no-id-name
Remove id/name from Perl modules and tests
2016-03-23 14:23:52 -04:00
Zaahir Moolla 5a65e747dc Merge pull request #2759 from JoshuaRLi/master
New JohnCena Goodie
2016-03-21 21:36:39 -04:00
Joshua Li 4d75f0b3cb Update JohnCena.t
Test file updated to match structured answer in .pm file. Thanks for bringing this to my attention, moollaza!
2016-03-21 20:18:07 -04:00
Zach Thompson 77e7248442 Test for all multiple control character sequences failing
test for single control character conversions returning
2016-03-20 15:29:03 -06:00
Zach Thompson e3fa7ad6e1 Remove extra bracket from regex
Add test for control characters
2016-03-20 15:06:24 -06:00
Ben Moon b4d861a24d Replace hard-coded max_length with dynamic length 2016-03-19 14:42:59 +00:00
Ben Moon 7f94106afa Replace substitution delimiter with '/'
Highlighting issues!
2016-03-19 13:21:15 +00:00
Ben Moon af67e12223 Display both warnings and errors
Display WARNINGS, FAILURES, or both when reporting test results.
2016-03-19 10:16:20 +00:00
Ben Moon bf3b056862 Update 'val' tests to use appropriate 'val' type
For the particular template used; e.g, 'trn' with 'language'.
2016-03-19 10:16:20 +00:00
Ben Moon c0a64d13be Only check against base name for ID check
So that cheat sheets in folders don't hate on us.
2016-03-19 10:16:20 +00:00
Ben Moon 5c9e825328 Fix handling of arguments
This does two things:

1. Allows multiple cheat sheets to be passed as arguments.

2. As a result of implementing the above, this now allows testing of the
language cheat sheets, which were previously untested.
2016-03-19 10:16:20 +00:00
Ben Moon 2ea1cdc4e2 Improve test phrasing
Hopefully this should be easier to understand for average use!
2016-03-19 10:16:19 +00:00
Ben Moon 62a771f73f Update trailing whitespace tests 2016-03-19 10:16:19 +00:00
Ben Moon db035c8651 Add ID standards test
Ensure ID ends with '_cheat_sheet'
2016-03-19 10:16:19 +00:00
Ben Moon 1c1894d40d Update output to use a 'normalized' amount of dots
To make it read nicer!
2016-03-19 10:16:19 +00:00
Ben Moon 054eeb9ed2 Improve test output
* Do not print 'testing....' for each test

* Color actual test message based on pass/warn/critical

* Report number of failures

* Do not duplicate the initial print message

* Prevent (AFAICS) tests wrapping incorrectly
2016-03-19 10:16:19 +00:00
Ben Moon 3b164ffaf5 Fix valid JSON test
Would use results from previous tests - we don't want that! Would also
fail (completely) if the JSON was invalid.
2016-03-19 10:16:19 +00:00
Ben Moon a40bfc4ade Fix indent
Happy @zachthompson? ;)
2016-03-19 10:16:19 +00:00
Zach Thompson 73d8f72fc0 Remove id/name from Perl modules and tests 2016-03-18 11:49:33 -06:00
Zaahir Moolla 1f674496b6 Merge pull request #2241 from GuiltyDolphin/markdown-reference
Replace MarkdownCheatSheet Goodie with MarkdownReference
2016-03-17 14:57:02 -04:00
Zaahir Moolla 41efeea698 Merge pull request #2714 from duckduckgo/gd/datemath-expand-trigger
DateMath: Expand Triggers
2016-03-17 11:59:57 -04:00
amoraleda 424ef8d0c4 Change structured_answer id. Added display_name 2016-03-17 08:22:22 +00:00
Rob Emery 1558937ad1 SubnetCalc: Has the wrong id; which is why the stats aren't showing on duck.co 2016-03-16 20:23:39 +00:00
Joshua Li d21fe60448 Update JohnCena.t
>_> rip in copypaste
2016-03-16 14:09:39 -04:00
JoshuaRLi f3409a40fa added john cena 2016-03-16 17:58:22 +00:00
Zaahir Moolla 62d3c2c4d5 Merge pull request #2755 from duckduckgo/gd/zodiac-fix-images
Zodiac: Fix broken images
2016-03-15 17:52:24 -04:00
Ben Moon 3cec34feea Add version to path 2016-03-15 18:57:53 +00:00
Zaahir Moolla 58f82d6b97 Fix failing tests 2016-03-15 14:42:28 -04:00
Ben Moon 24bfc7acc9 Add support for 'add' and 'subtract' forms 2016-03-14 21:58:07 +00:00
Rob Emery 08d5cc587d Conversions: Failing tests for ft/s losing the s 2016-03-13 13:11:45 +00:00
Rob Emery 1454e826ac Conversions: Adding failing test for losing the s from m/s 2016-03-13 13:08:31 +00:00
Rob Emery 5b26e3a27c Conversions: Adding singular output test for speed 2016-03-13 13:06:03 +00:00
Rob Emery 90d43831c2 Conversions: Adding singular test for input 2016-03-13 13:04:18 +00:00
Rob Emery abb5640181 Conversions: now supports speed! Only mph,kph,m/s,ft/s,knots atm 2016-03-12 14:26:32 +00:00
amoraleda 8444ae4485 Change to JS maps render 2016-03-11 15:58:00 +00:00
Ben Moon 2c78f15d63 Add support for 'what will the date be' form 2016-03-10 20:01:42 +00:00
Zach Thompson d664839c44 Merge pull request #2723 from duckduckgo/gd/cheatsheets-fix-section-tests
CheatSheets: Fix section tests
2016-03-10 12:23:16 -07:00
Ben Moon 526c363e16 Update test output to show all critical failures
Rather than just one at the end.
2016-03-10 17:49:36 +00:00
Ben Moon 9a343e1e39 Fix assigned categories not being set correctly
Whoops!
2016-03-10 16:45:03 +00:00
Ben Moon 47834bd7d9 Ensure default triggers are always critical 2016-03-10 16:19:34 +00:00
Ben Moon 5f9fa76873 Merge section contents tests 2016-03-10 15:53:41 +00:00
Ben Moon 54d0b7faad Fix remaining section tests
They weren't accounting properly for invalid section values - this fixes
that.
2016-03-10 15:34:14 +00:00
Ben Moon b752d0d893 Remove redundant %order hash
Use %sections with delete to get a hash with the appropriate items.
2016-03-10 15:33:27 +00:00
Zaahir Moolla be7dbb3f63 Merge pull request #2333 from duckduckgo/gd/update-xs-libs
Update use of 'JSON' to 'JSON::MaybeXS'
2016-03-10 10:11:29 -05:00
Rob Emery fb2156a3c3 Conversions: Updating tests for 坪 with new structure 2016-03-09 21:36:45 +00:00
Rob Emery db7df67f0a Merge branch 'master' into mintsoft/conversions/template 2016-03-09 21:28:34 +00:00
Ben Moon e81f8f5bdb Move condition assignments into if 2016-03-09 15:29:06 +00:00
Ben Moon 6a45c21e94 Update section tests to report in bulk
I.e, they report all bad sections rather than failing on first one.
2016-03-09 15:17:24 +00:00
Ben Moon e090a9949d Make section tests case-sensitive 2016-03-09 14:56:50 +00:00
Ben Moon 570fcc8146 Make section tests critical 2016-03-09 14:49:29 +00:00
Ben Moon 064f17488c Fix section tests
Anything that didn't contain alpha chars (and thus have something to
lowercase) was being removed entirely from the sections (causing a
warning), this fixes that.
2016-03-09 14:27:15 +00:00
Rob Emery 954e627e73 Conversions: the ping unit no longer has s appended for values <> 1 2016-03-08 19:47:52 +00:00
Rob Emery 23e1008db0 Conversions: Adding failing test for plural ping(坪) 2016-03-08 19:46:30 +00:00
Rob Emery ea29a70e79 Merge remote-tracking branch 'heycam/conversions-ping' into mintsoft/conversions/ping 2016-03-08 19:45:22 +00:00
Ben Moon 3fba984c4b Merge pull request #2652 from marianosimone/support_dices_in_dice_trigger
support "dices" spelling for dice trigger
2016-03-08 16:59:49 +00:00
Ben Moon 509f94af2c Update CheatSheetsJSON to use JSON::MaybeXS 2016-03-08 16:35:34 +00:00
Rob Emery fea8dab8dc Merge pull request #2708 from duckduckgo/gd/gibberish-generator-french-fix
GibberishGenerator: Fix failing tests
2016-03-07 21:07:46 +00:00
Ben Moon 1e2b4448db Set signal to high
Sometimes it wasn't displaying when it should (was overridden).
2016-03-07 19:16:39 +00:00
Zach Thompson 7380c1c8c6 Merge pull request #2692 from duckduckgo/gd/cheatsheet-tests-aliases
CheatSheets: Add alias trigger tests
2016-03-07 11:51:00 -07:00
Ben Moon d17148be99 Add support for 'what was the...' forms 2016-03-07 18:46:42 +00:00
Ben Moon 19776b1c7c Improve triggering
Add a bunch more common forms that I've seen in the searches - also
supports a couple of forms that should've been supported before.
2016-03-07 18:42:40 +00:00
Ben Moon c59aece0e1 Combine tests that rely on ID being present 2016-03-07 17:26:03 +00:00
Ben Moon 5583f00e29 Merge pull request #2112 from tyleryasaka/UltimateAnswer
UltimateAnswer: Expand query space
2016-03-07 12:52:18 +00:00
Ben Moon 58859e4adf Update word regexes
Should hopefully include *all* characters now.
2016-03-07 12:37:44 +00:00
Ben Moon cfd48e73ff Add 'large' tests
To hopefully be more likely to catch weird lingo situations.
2016-03-07 12:28:08 +00:00
sagarwal 3245b6fdf5 Add stardate goodie 2016-03-07 05:01:22 +00:00
Charlie Garrison 8f48d86145 Additional trigger words, and tests
Ref: #1968
Signed-off-by: Charlie Garrison <cngarrison@gmail.com>
2016-03-05 14:43:59 +11:00
Ben Moon d8ff7c9ec4 Only warn if category not assigned to cheat sheet
For the alias-trigger tests.
2016-03-04 20:56:54 +00:00
Ben Moon 7b9c57d4b6 Remove 'any' trigger test 2016-03-04 19:52:57 +00:00
Rob Emery 3320873e6e Merge pull request #2699 from riqpe/timeszoneconverter
Fixes #2697: 12:00 now parsed as Noon if am not specified
2016-03-04 19:31:43 +00:00
Ben Moon a487995575 Whitelist 'duckduckgo-syntax' for category tests
I think this is the best option as it is the only case.
2016-03-04 19:06:00 +00:00
rsilvola f0f10e2428 Fixes #2697: 12:00 now parsed as Noon if am not specified 2016-03-04 14:07:39 +00:00
Ben Moon 8f8d49b5b2 Add test for aliases against custom triggers
Make sure aliases don't contain custom triggers defined in
'triggers.yaml'.
2016-03-03 20:41:44 +00:00
Ben Moon 2665cc33f0 Add test for triggers in aliases
Ensures aliases do not contain any of the triggers defined in
categories.
2016-03-03 20:26:51 +00:00
Zaahir Moolla 42a2f2e21c Merge pull request #1967 from GuiltyDolphin/gibberishgenerator
New GibberishGenerator Goodie
2016-03-03 12:13:51 -05:00
Zaahir Moolla f50b5ab74e Remove IsAwesome Tests 2016-03-03 10:33:08 -05:00
Zaahir Moolla 20387264e8 Merge pull request #1984 from GuiltyDolphin/improve-lorem
Improve LoremIpsum Goodie
2016-03-02 20:20:46 -05:00
Ben Moon 3d192eead4 Update ID file name test
Only use conversion from ID to file name.
2016-03-02 20:06:49 +00:00
Ben Moon 30b501eb0f Update trigger check to use more concise method 2016-03-02 19:37:33 +00:00
Ben Moon cd80f72d73 Update trigger map 2016-03-02 19:27:27 +00:00
Ben Moon a9d402b28f Make use of global %triggers hash 2016-03-02 19:22:38 +00:00
Ben Moon 77a908d514 Add test for valid template type 2016-03-02 18:48:39 +00:00
Ben Moon b6e806f36c Add 're-adding category' test 2016-03-02 18:32:07 +00:00
Ben Moon 0c6a320ce9 Add test for duplicate triggers 2016-03-02 18:20:44 +00:00
Ben Moon 3b4c36fdd9 Improve file name ID check 2016-03-02 18:08:37 +00:00
amoraleda 8e2741a3f2 Tests added 2016-03-02 11:44:25 +00:00
marianosimone c7e6041f0f support - and whitespace in number spelling 2016-03-01 19:56:27 +00:00
marianosimone b8c57b832f use Numericalize for dice trigger 2016-03-01 19:12:48 +00:00
Ben Moon c4e20d56d2 Update alias tests to critical 2016-02-29 21:12:55 +00:00
Ben Moon 128bc4a3dc Remove redundant sub 2016-02-29 21:11:06 +00:00
Ben Moon 5da5dbe3f7 Merge ID tests
Checking ID against file name and visa versa merged into one test.
2016-02-29 21:10:36 +00:00
Ben Moon af83848b8d Make uppercase check more explicit 2016-02-29 21:10:36 +00:00
Ben Moon 629d51f71d Remove code-style tests 2016-02-29 21:10:36 +00:00
Ben Moon 818b680906 Add test for uppercase aliases 2016-02-29 21:10:36 +00:00
Ben Moon 236b0dc0ac Clean up alias tests 2016-02-29 21:10:36 +00:00
Ben Moon db20061b6b Move alias tests into CheatSheets.t 2016-02-29 21:10:35 +00:00
Ben Moon 933cf80ef0 Add test for trailing whitespace 2016-02-29 21:10:35 +00:00
Ben Moon 0291a6c53e Add file name test
Ensures file name matches ID
2016-02-29 21:10:35 +00:00
Ben Moon 8980550aec Add test to make template_type mandatory 2016-02-29 21:10:35 +00:00
Ben Moon 3a5fcd5e21 Add ID tests
Checks the ID follows the expected naming conventions.
2016-02-29 21:10:35 +00:00
Ben Moon f581026a1e Add tests for indentation
1. Checks that tabs aren't used to indent.

2. Checks that indentation is a multiple of 4.
2016-02-29 21:10:35 +00:00
Ben Moon 8838f6ebc2 Add alias warnings to cheat sheet tests 2016-02-29 21:10:35 +00:00
marianosimone a2c3f19b9d support "dices" spelling for dice trigger
fixes #1255 (except for not converting "two" into 2)
2016-02-28 20:05:34 +00:00
Rob Emery 0ef3075361 Merge pull request #2642 from duckduckgo/gd/caesar-cipher-trigger-info
CaesarCipher: Add 'How to decode?' response
2016-02-28 12:36:45 +00:00
Ben Moon 716bae7baa Add Wikipedia as source 2016-02-27 11:14:20 +00:00
Ben Moon b79f825e81 Add more triggers for decode information 2016-02-27 11:05:36 +00:00
Ben Moon 43c739ad02 Ignore case when matching decode query 2016-02-27 11:02:40 +00:00
Ben Moon 32f18a8cc4 Add tests for decode information 2016-02-27 10:46:02 +00:00
Zaahir Moolla 8dab17c25e Merge pull request #1982 from Mailkov/diceissue1163
Issue #1163 - Convert Dice to use templates
2016-02-25 14:54:54 -05:00
Zaahir Moolla 032cc4fbd7 Merge pull request #1950 from Mailkov/issue1934
Fix #1934 - Rubiks Cube Patterns: Show all patterns for "rubics cube patterns", add images to results
2016-02-24 22:23:55 -05:00
Mailkov 8ea250489e fix tests 2016-02-24 16:57:15 +00:00
Zaahir Moolla 925c68a3fd Fix tests 2016-02-23 16:02:54 -05:00
Zaahir Moolla bf2ac7d27a resolve merge conflict 2016-02-23 15:01:47 -05:00