[calc] Update unit tests to accept new format from WA.
[core] Improve command match regexp.

- Someone broke the command regexp by using prefix r"\.|\!". It didn't work
  as expected and instead split the whole regexp into two. Adding a
  non-capturing group around regexp should avoid this in the future.