Bugzilla – Attachment 39804 Details for
Bug 12357
Enhancements to RIS and BibTeX exporting
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 12357 [QA Followup] - Unit Test
Bug-12357-QA-Followup---Unit-Test.patch (text/plain), 1.81 KB, created by
Jonathan Druart
on 2015-06-03 13:46:04 UTC
(
hide
)
Description:
Bug 12357 [QA Followup] - Unit Test
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2015-06-03 13:46:04 UTC
Size:
1.81 KB
patch
obsolete
>From 5ada458f8410f8e6998d1b44f91eba875e722416 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Tue, 28 Apr 2015 08:56:49 -0400 >Subject: [PATCH] Bug 12357 [QA Followup] - Unit Test > >Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> >This works with next patch > >Signed-off-by: Jonathan Druart <jonathan.druart@koha-community.org> >--- > t/db_dependent/Record.t | 27 ++++++++++++++++++++++----- > 1 file changed, 22 insertions(+), 5 deletions(-) > >diff --git a/t/db_dependent/Record.t b/t/db_dependent/Record.t >index e8d6094..5dfa36a 100755 >--- a/t/db_dependent/Record.t >+++ b/t/db_dependent/Record.t >@@ -1,18 +1,22 @@ > #!/usr/bin/perl >-# >-# This Koha test module is a stub! >-# Add more tests here!!! > > use Modern::Perl; > >-use Test::More tests => 11; >+use Test::More tests => 12; > use MARC::Record; > >+use C4::Context; >+ > BEGIN { > use_ok('C4::Record'); > } > >-#my ($marc,$to_flavour,$from_flavour,$encoding) = @_; >+my $dbh = C4::Context->dbh; >+# Start transaction >+$dbh->{AutoCommit} = 0; >+$dbh->{RaiseError} = 1; >+ >+C4::Context->set_preference( "BibtexExportAdditionalFields", q{} ); > > my @marcarray=marc2marc; > is ($marcarray[0],"Feature not yet implemented\n","error works"); >@@ -106,6 +110,19 @@ my $test5xml=qq(\@book{testID, > > is ($bibtex, $test5xml, "testing bibtex"); > >+C4::Context->set_preference( "BibtexExportAdditionalFields", "'\@': 260\$b\ntest: 260\$b" ); >+$bibtex = marc2bibtex( $marc, 'testID' ); >+my $test6xml = qq(\@Scholastic{testID, >+ author = {Rowling, J.K.}, >+ title = {Harry potter}, >+ publisher = {Scholastic}, >+ year = {2001}, >+ test = {Scholastic} >+} >+); >+is( $bibtex, $test6xml, "testing bibtex" ); >+C4::Context->set_preference( "BibtexExportAdditionalFields", q{} ); >+ > $marc->append_fields(MARC::Field->new( > '264', '3', '1', b => 'Reprints', c => '2011' > )); >-- >2.1.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 12357
:
28646
|
28647
|
28648
|
28649
|
28650
|
29291
|
29292
|
29293
|
29294
|
29295
|
29296
|
29297
|
31677
|
31678
|
31679
|
31680
|
33123
|
33124
|
33125
|
33126
|
35485
|
35487
|
35489
|
35826
|
35827
|
35828
|
38602
|
38604
|
39469
|
39471
|
39773
|
39774
|
39775
|
39776
|
39803
| 39804 |
39805
|
39806