Added Unit tests. Fixed bug in regex mapper found during testing.