[dice] Add example tests.
[dice] Rewrite dice rolling.

-Do arithmetic locally, instead of using google.
-Don't call random unnecessarily.
-Add compressed view of the dice, for when there are too many to list.
-Limit number of dice to 1000. Fixes #309.
[test_tools] Make the assertion message for regexps more readable.