Bugzilla – Attachment 127089 Details for
Bug 29368
Zebra index not correctly mocked from tests
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 29368: Fix remove_from_cart
Bug-29368-Fix-removefromcart.patch (text/plain), 2.48 KB, created by
Jonathan Druart
on 2021-10-29 10:37:56 UTC
(
hide
)
Description:
Bug 29368: Fix remove_from_cart
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2021-10-29 10:37:56 UTC
Size:
2.48 KB
patch
obsolete
>From 1021a01a2ef67e67e20f07317f2344240edcfd1b Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Fri, 29 Oct 2021 12:27:32 +0200 >Subject: [PATCH] Bug 29368: Fix remove_from_cart > >Reusing what has been done previously >--- > t/db_dependent/selenium/remove_from_cart.t | 29 ++++++---------------- > 1 file changed, 8 insertions(+), 21 deletions(-) > >diff --git a/t/db_dependent/selenium/remove_from_cart.t b/t/db_dependent/selenium/remove_from_cart.t >index 02ce186b399..57396c92ae7 100755 >--- a/t/db_dependent/selenium/remove_from_cart.t >+++ b/t/db_dependent/selenium/remove_from_cart.t >@@ -39,37 +39,25 @@ my $opac_base_url = $s->opac_base_url; > my $base_url = $s->base_url; > my $builder = t::lib::TestBuilder->new; > >+my $marcflavour = C4::Context->preference('marcflavour') || 'MARC21'; >+ > my $SearchEngine_value = C4::Context->preference('SearchEngine'); > C4::Context->set_preference('SearchEngine', 'Zebra'); > > my $mock_zebra = t::lib::Mocks::Zebra->new( > { >- koha_conf => $ENV{KOHA_CONF}, >- user => $ENV{KOHA_USER}, >- password => $ENV{KOHA_PASS}, >- intranet => $ENV{KOHA_INTRANET_URL}, >- opac => $ENV{KOHA_OPAC_URL}, >+ marcflavour => $marcflavour, > } > ); > > subtest 'OPAC - Remove from cart' => sub { >- plan tests => 22; >+ plan tests => 4; > >- #-------------------------------- Test with greek and corean chars; >- # launch the zebra saerch process >+ my $sourcedir = dirname(__FILE__) . "/../data"; >+ $mock_zebra->load_records( >+ sprintf( "%s/%s/zebraexport/biblio", $sourcedir, lc($marcflavour) ), >+ 'iso2709', 'biblios', 1 ); > $mock_zebra->launch_zebra; >- # launch the zebra index process >- $mock_zebra->launch_indexer; >- >- my $marcflavour = C4::Context->preference('marcflavour') || 'MARC21'; >- >- my $testdir = File::Spec->rel2abs( dirname(__FILE__) . '/../www/'); >- my $file = >- $marcflavour eq 'UNIMARC' >- ? "$testdir/data/unimarcutf8record.mrc" >- : "$testdir/data/marc21utf8record.mrc"; >- >- my $batch_id = $mock_zebra->load_records($file); > > # We need to prevent scrolling to prevent the floating toolbar from overlapping buttons we are testing > my $window_size = $driver->get_window_size(); >@@ -107,7 +95,6 @@ subtest 'OPAC - Remove from cart' => sub { > # Reset window size > $driver->set_window_size($window_size->{'height'}, $window_size->{'width'}); > >- $mock_zebra->clean_records($batch_id); > $mock_zebra->cleanup; > }; > >-- >2.25.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 29368
:
127087
|
127088
|
127089
|
127097
|
127099