t/CORE: add mro and re tests

Tests and referenced googlecode issues prepared by cPanel
(Todd Rinaldo and Nicolas Rochelemagne)