diff --git a/module/VuFind/tests/unit-tests/src/VuFindTest/ExportTest.php b/module/VuFind/tests/unit-tests/src/VuFindTest/ExportTest.php index 6726ecea62d3c978894c7f9cd4ab9d27fbfc2265..b7fd74d8e93d98dd4ec17af5fa7c0b5a9a780222 100644 --- a/module/VuFind/tests/unit-tests/src/VuFindTest/ExportTest.php +++ b/module/VuFind/tests/unit-tests/src/VuFindTest/ExportTest.php @@ -225,6 +225,24 @@ class ExportTest extends \PHPUnit_Framework_TestCase ); } + /** + * Test getLabelForFormat + * + * @ return void + */ + public function testGetLabel() + { + $config = [ + 'foo' => [], + 'bar' => ['label' => 'baz'], + ]; + $export = $this->getExport(array(), $config); + // test "use section label as default" + $this->assertEquals('foo', $export->getLabelForFormat('foo')); + // test "override with label setting" + $this->assertEquals('baz', $export->getLabelForFormat('bar')); + } + /** * Get a fake MARCXML record *