View | Details | Raw Unified | Return to bug 12167
Collapse All | Expand All

(-)a/t/db_dependent/NewsChannels.t (-6 / +7 lines)
Lines 3-9 Link Here
3
use Modern::Perl;
3
use Modern::Perl;
4
use C4::Dates qw(format_date);
4
use C4::Dates qw(format_date);
5
use C4::Branch qw(GetBranchName);
5
use C4::Branch qw(GetBranchName);
6
use Test::More tests => 11;
6
use Test::More tests => 12;
7
7
8
BEGIN {
8
BEGIN {
9
    use_ok('C4::NewsChannels');
9
    use_ok('C4::NewsChannels');
Lines 132-142 my ( $opac_news_count, $arrayref_opac_news ) = get_opac_news( 0, q{}, 'LIB1' ); Link Here
132
ok( $opac_news_count >= 2, 'Successfully tested get_opac_news for LIB1!' );
132
ok( $opac_news_count >= 2, 'Successfully tested get_opac_news for LIB1!' );
133
133
134
# Test GetNewsToDisplay
134
# Test GetNewsToDisplay
135
( $opac_news_count, $arrayref_opac_news ) = GetNewsToDisplay( q{}, 'LIB1' );
135
( $arrayref_opac_news ) = GetNewsToDisplay( q{}, 'LIB1' );
136
ok( !$arrayref_opac_news, 'Second parameter is ' .
136
ok( $arrayref_opac_news, '$arrayref_opac_news is ' .
137
                          ( defined($arrayref_opac_news) ?
137
                          ( defined($arrayref_opac_news) ?
138
                              ("Defined as '$arrayref_opac_news'") : "UNDEFINED")
138
                              ('Defined') : 'UNDEFINED')
139
  );
139
  );
140
ok( $opac_news_count >= 2, 'Successfully tested GetNewsToDisplay for LIB1!' );
140
ok( ref $arrayref_opac_news eq 'ARRAY',
141
    '$arrayref_opac_news is an array reference.' );
142
ok( (scalar @$arrayref_opac_news) >= 2, 'Successfully tested GetNewsToDisplay for LIB1!' );
141
143
142
$dbh->rollback;
144
$dbh->rollback;
143
- 

Return to bug 12167