From ef61b02c3e5d58efeed9702ad22759094f087d5b Mon Sep 17 00:00:00 2001 From: Srdjan Date: Mon, 31 Mar 2014 16:12:17 +1300 Subject: [PATCH] bug_11213: Include XSLT processing for searchResults() test * Added template paths to temp test dir, so XSLT templates can be picked up --- t/db_dependent/Search.t | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/t/db_dependent/Search.t b/t/db_dependent/Search.t index 240c3d4..e626dae 100644 --- a/t/db_dependent/Search.t +++ b/t/db_dependent/Search.t @@ -130,6 +130,8 @@ $contextmodule->mock('preference', sub { return 'en'; } elsif ($pref eq 'AlternateHoldingsField') { return '490av'; + } elsif ($pref =~ m/XSLTResultsDisplay/) { + return 'default'; } elsif ($pref eq 'AuthoritySeparator') { return '--'; } elsif ($pref eq 'DisplayLibraryFacets') { @@ -201,6 +203,15 @@ sub mock_GetMarcSubfieldStructure { sub run_marc21_search_tests { my $indexing_mode = shift; $datadir = tempdir(); + # Unix friendly, but so is the zebra_config.pl command below... + my $tpl_dir = File::Spec->rel2abs( dirname(__FILE__) ) . "/../../koha-tmpl"; + my $opac_dir = "$datadir/opac"; + mkdir $opac_dir; + symlink "$tpl_dir/opac-tmpl", "$opac_dir/templates"; + my $intranet_dir = "$datadir/intranet"; + mkdir $intranet_dir; + symlink "$tpl_dir/intranet-tmpl", "$intranet_dir/templates"; + system(dirname(__FILE__) . "/zebra_config.pl $datadir marc21 $indexing_mode"); Koha::Caches->get_instance('config')->flush_all; -- 2.7.4