adding Cpe Extractor and test
improved test cases, minor fixes.