Lines 21-27
use C4::Context;
Link Here
|
21 |
use C4::Members; |
21 |
use C4::Members; |
22 |
use C4::Letters; |
22 |
use C4::Letters; |
23 |
|
23 |
|
24 |
use Test::More tests => 91; |
24 |
use Test::More tests => 93; |
25 |
use Test::Warn; |
25 |
use Test::Warn; |
26 |
|
26 |
|
27 |
BEGIN { |
27 |
BEGIN { |
Lines 78-83
is( $suggestion->{publishercode}, $my_suggestion->{publishercode}, 'NewSuggestio
Link Here
|
78 |
is( $suggestion->{suggestedby}, $my_suggestion->{suggestedby}, 'NewSuggestion stores the borrower number correctly' ); |
78 |
is( $suggestion->{suggestedby}, $my_suggestion->{suggestedby}, 'NewSuggestion stores the borrower number correctly' ); |
79 |
is( $suggestion->{biblionumber}, $my_suggestion->{biblionumber}, 'NewSuggestion stores the biblio number correctly' ); |
79 |
is( $suggestion->{biblionumber}, $my_suggestion->{biblionumber}, 'NewSuggestion stores the biblio number correctly' ); |
80 |
is( $suggestion->{STATUS}, 'ASKED', 'NewSuggestion stores a suggestion with the status ASKED by default' ); |
80 |
is( $suggestion->{STATUS}, 'ASKED', 'NewSuggestion stores a suggestion with the status ASKED by default' ); |
|
|
81 |
is( $suggestion->{budgetid}, undef, 'NewSuggestion should set budgetid to NULL if not given' ); |
81 |
|
82 |
|
82 |
is( CountSuggestion('ASKED'), 1, 'CountSuggestion returns the correct number of suggestions' ); |
83 |
is( CountSuggestion('ASKED'), 1, 'CountSuggestion returns the correct number of suggestions' ); |
83 |
|
84 |
|
Lines 98-103
$suggestion = GetSuggestion($my_suggestionid);
Link Here
|
98 |
is( $suggestion->{title}, $mod_suggestion1->{title}, 'ModSuggestion modifies the title correctly' ); |
99 |
is( $suggestion->{title}, $mod_suggestion1->{title}, 'ModSuggestion modifies the title correctly' ); |
99 |
is( $suggestion->{author}, $mod_suggestion1->{author}, 'ModSuggestion modifies the author correctly' ); |
100 |
is( $suggestion->{author}, $mod_suggestion1->{author}, 'ModSuggestion modifies the author correctly' ); |
100 |
is( $suggestion->{publishercode}, $mod_suggestion1->{publishercode}, 'ModSuggestion modifies the publishercode correctly' ); |
101 |
is( $suggestion->{publishercode}, $mod_suggestion1->{publishercode}, 'ModSuggestion modifies the publishercode correctly' ); |
|
|
102 |
is( $suggestion->{budgetid}, undef, 'ModSuggestion should set budgetid to NULL if not given' ); |
103 |
|
101 |
my $messages = C4::Letters::GetQueuedMessages({ |
104 |
my $messages = C4::Letters::GetQueuedMessages({ |
102 |
borrowernumber => $borrowernumber, |
105 |
borrowernumber => $borrowernumber, |
103 |
}); |
106 |
}); |
104 |
- |
|
|