Bugzilla – Attachment 191929 Details for
Bug 41695
Suggestion->refuser returns the manager
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 41695: Unit tests
Bug-41695-Unit-tests.patch (text/plain), 2.09 KB, created by
Baptiste Wojtkowski (bwoj)
on 2026-01-23 13:39:54 UTC
(
hide
)
Description:
Bug 41695: Unit tests
Filename:
MIME Type:
Creator:
Baptiste Wojtkowski (bwoj)
Created:
2026-01-23 13:39:54 UTC
Size:
2.09 KB
patch
obsolete
>From 748e560876a1c791bf4769e2c9ee372564dd7776 Mon Sep 17 00:00:00 2001 >From: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com> >Date: Fri, 23 Jan 2026 13:36:08 +0000 >Subject: [PATCH] Bug 41695: Unit tests > >--- > t/db_dependent/Koha/Suggestions.t | 17 +++++++++++++---- > 1 file changed, 13 insertions(+), 4 deletions(-) > >diff --git a/t/db_dependent/Koha/Suggestions.t b/t/db_dependent/Koha/Suggestions.t >index bc28cec484b..e4488fbc378 100755 >--- a/t/db_dependent/Koha/Suggestions.t >+++ b/t/db_dependent/Koha/Suggestions.t >@@ -273,7 +273,7 @@ subtest 'constraints' => sub { > }; > > subtest 'manager, suggester, accepter, rejecter, last_modifier' => sub { >- plan tests => 11; >+ plan tests => 14; > $schema->storage->txn_begin; > > my $suggestion = $builder->build_object( { class => 'Koha::Suggestions' } ); >@@ -336,13 +336,22 @@ subtest 'manager, suggester, accepter, rejecter, last_modifier' => sub { > '->last_modifier should have returned undef if no last_modifier set' > ); > >- my $accepter = $builder->build_object( { class => 'Koha::Patrons' } ); >+ my $suggester = $builder->build_object( { class => 'Koha::Patrons' } ); >+ my $accepter = $builder->build_object( { class => 'Koha::Patrons' } ); >+ my $rejecter = $builder->build_object( { class => 'Koha::Patrons' } ); >+ my $manager = $builder->build_object( { class => 'Koha::Patrons' } ); > $suggestion->set( > { >- acceptedby => $accepter->id, >+ suggestedby => $suggester->id, >+ acceptedby => $accepter->id, >+ rejectedby => $rejecter->id, >+ managedby => $manager->id > } > ); >- is( $suggestion->accepter->id, $accepter->id, 'Accepter correctly retrieved' ); >+ is( $suggestion->suggester->id, $suggester->id, 'Suggester correctly retrieved' ); >+ is( $suggestion->accepter->id, $accepter->id, 'Accepter correctly retrieved' ); >+ is( $suggestion->rejecter->id, $rejecter->id, 'Rejecter correctly retrieved' ); >+ is( $suggestion->manager->id, $manager->id, 'Manager correctly retrieved' ); > $schema->storage->txn_rollback; > }; > >-- >2.43.0
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 41695
: 191929 |
191930
|
191936