Bug 11319: Add specific UT for nonexistent field/subfield
authorJonathan Druart <jonathan.druart@biblibre.com>
Wed, 11 Dec 2013 14:53:37 +0000 (15:53 +0100)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Wed, 12 Nov 2014 15:04:17 +0000 (12:04 -0300)
commit2de657d4ec0b381d045559d18276f28917b12994
tree7aa6409ede33598aa81abbaff91b56c339de0d5d
parentc7d862bb7b98e854daa0bfd871f1e8f9f0f2eb39
Bug 11319: Add specific UT for nonexistent field/subfield

This patch only adds unit tests for the copy and move actions.
They test if the action does not create a field/subfield if the source
did not exist.

Also it adds a unit tests for the existing behavior (in order not to
lost it): we can use the '^' and the '$' character in regex for
substituing. For example: Copy 245$a to 245$a with the regex s/^/BEGIN /
This will add the string "BEGIN " at the beginning of the 245$a fields.

To test: prove t/SimpleMARC.t

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
t/SimpleMARC.t