Closed mjordan closed 7 years ago
Woops, forgot to add PHPUnit tests. Please hold off on merging until I do so.
Tests added: phpunit --exclude-group inputvalidators --bootstrap vendor/autoload.php tests
.
Note running --checkconfig all
will result in an error as mapping _csv_path setting is expected with the provided test files. We'll need to adjust the checkconfig logic.
@mjordan Works as expected, thank you. The only issue is that --checkconfig
expects a mappings path. I'm good with merging this code and then addressing that as a separate issue. What do you think @mjordan?
Yes, sorry about that, we need to update --checkconfig
. Open a separate issue and assign it to me if you want.
Github issue: (#363)
What does this Pull Request do?
Adds a new metadata parser class that generates output from Twig templates.
What's new?
A new metadata parser class that generates its output from Twig templates. It is a drop-in replacement for existing metadata parsers. This parser does not use field mappings; instead, source field values from the fetcher are interpolated directly into the templates.
How should this be tested?
composer dump-autoload
.phpunit --exclude-group inputvalidators --bootstrap vendor/autoload.php tests
. There should be no failures../mik -c templated.ini
.template = templated_mods_twig.xml
and uncomment; template = templated_dc_twig.xml
.To test the accompanying metadata manipulator:
[LOGGING] path_to_manipulator_log = /tmp/templated_output/manipulator.log