Bugzilla – Attachment 87429 Details for
Bug 22644
Some tests in Upload.t are not testing the right thing
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 22644: Highlight the problem
Bug-22644-Highlight-the-problem.patch (text/plain), 1.46 KB, created by
Jonathan Druart
on 2019-04-05 01:00:54 UTC
(
hide
)
Description:
Bug 22644: Highlight the problem
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2019-04-05 01:00:54 UTC
Size:
1.46 KB
patch
obsolete
>From e5f50de02d9071b8c658fab2bc9b3f6a39488712 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Thu, 4 Apr 2019 12:34:25 -0300 >Subject: [PATCH] Bug 22644: Highlight the problem > >--- > t/db_dependent/Upload.t | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > >diff --git a/t/db_dependent/Upload.t b/t/db_dependent/Upload.t >index 802dc58da0..162b5dfb32 100644 >--- a/t/db_dependent/Upload.t >+++ b/t/db_dependent/Upload.t >@@ -149,7 +149,7 @@ subtest 'Add same file in same category' => sub { > }; > > subtest 'Test delete via UploadedFile as well as UploadedFiles' => sub { >- plan tests => 10; >+ plan tests => 12; > > # add temporary file with same name and contents (file4) > my $upl = Koha::Uploader->new({ tmp => 1 }); >@@ -186,9 +186,12 @@ subtest 'Test delete via UploadedFile as well as UploadedFiles' => sub { > # add another one with TestBuilder and delete twice (file does not exist) > $upload01 = $builder->build({ source => 'UploadedFile' }); > $kohaobj = Koha::UploadedFiles->find( $upload01->{id} ); >+ $path = $kohaobj->full_path; >+ is( -e $path, 1, 'File exists after creation'); > $delete = $kohaobj->delete({ keep_file => 1 }); > $delete = $kohaobj->delete({ keep_file => 1 }); > ok( $delete =~ /^(0E0|-1)$/, 'Repeated delete unsuccessful' ); >+ is( -e $path, 1, 'File exists if keep_file is passed on deleting' ); > # NOTE: Koha::Object->delete does not return 0E0 (yet?) > }; > >-- >2.11.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 22644
: 87429