Add wrapper class for importProcessor
authoreileen <emcnaughton@wikimedia.org>
Tue, 13 Aug 2019 10:46:49 +0000 (22:46 +1200)
committereileen <emcnaughton@wikimedia.org>
Tue, 13 Aug 2019 23:53:00 +0000 (11:53 +1200)
commit0b0285b17f05054a67b2264dfc55977c8086d886
tree668726020aafb3aad0cee343ad4c0a095dc12814
parentf39da48c4cc1aff2e99e80f20ea8f739172bd42a
Add wrapper class for importProcessor

With the export cleanup creating a new sensible class & migrating code to it turned out to be a good approach.

This adds a class that wraps around the Importer Object, taking the mapping_field db format of fields
as a format - this is also where we wound up with the Export - using that format as it is what is saed.

There is a gap as I noted in https://lab.civicrm.org/dev/core/issues/1172 around the schema's adequacy.

That is not such an issue for this - in that we are not dealing with Contribution import and
this is really just exposing the wrapper for the unit tests at this stage - the only change to
'live' code is a little less php v4 support - we have removed a bunch of these from the constructor of the
other objects already with no observed issues
CRM/Contact/Import/Parser/Contact.php
CRM/Import/ImportProcessor.php [new file with mode: 0644]
tests/phpunit/CRM/Contact/Import/Parser/ContactTest.php