From e8fdac8d84e1dde57c26996ac55e1a9a532f4754 Mon Sep 17 00:00:00 2001 From: Andrew Moore Date: Fri, 23 May 2008 12:36:30 -0500 Subject: [PATCH] Bug 2047: some tests for C4::Biblio::get_biblio_authorised_values I had these tests laying around for a while. I just forgot to commit them. No functional or documentation changes needed. Signed-off-by: Joshua Ferraro --- .../Biblio/get_biblio_authorised_values.pm | 48 +++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 t/lib/KohaTest/Biblio/get_biblio_authorised_values.pm diff --git a/t/lib/KohaTest/Biblio/get_biblio_authorised_values.pm b/t/lib/KohaTest/Biblio/get_biblio_authorised_values.pm new file mode 100644 index 0000000000..aab03a0e55 --- /dev/null +++ b/t/lib/KohaTest/Biblio/get_biblio_authorised_values.pm @@ -0,0 +1,48 @@ +package KohaTest::Biblio::get_biblio_authorised_values; +use base qw( KohaTest::Biblio ); + +use strict; +use warnings; + +use Test::More; + +use C4::Biblio; + +=head2 STARTUP METHODS + +These get run once, before the main test methods in this module + +=head3 insert_test_data + +=cut + +sub insert_test_data : Test( startup => 71 ) { + my $self = shift; + + # I'm going to add a bunch of biblios so that I can search for them. + $self->add_biblios( count => 10, + add_items => 1 ); + + +} + +=head2 TEST METHODS + +standard test methods + +=head3 basic_test + +basic usage. + +=cut + +sub basic_test : Test( 1 ) { + my $self = shift; + + ok( $self->{'biblios'}[0], 'we have a biblionumber' ); + my $authorised_values = C4::Biblio::get_biblio_authorised_values( $self->{'biblios'}[0] ); + diag( Data::Dumper->Dump( [ $authorised_values ], [ 'authorised_values' ] ) ); + +} + +1; -- 2.39.5