Lines 1-6
Link Here
|
1 |
use strict; |
1 |
use strict; |
2 |
use warnings; |
2 |
use warnings; |
3 |
use Test::More tests=>17; |
3 |
use Test::More tests=>18; |
4 |
|
4 |
|
5 |
BEGIN {use_ok('C4::Budgets') } |
5 |
BEGIN {use_ok('C4::Budgets') } |
6 |
use C4::Budgets; |
6 |
use C4::Budgets; |
Lines 86-91
ok($budget_id=AddBudget(
Link Here
|
86 |
#| budget_owner_id | int(11) | YES | | NULL | | |
86 |
#| budget_owner_id | int(11) | YES | | NULL | | |
87 |
#| budget_permission | int(1) | YES | | 0 | | |
87 |
#| budget_permission | int(1) | YES | | 0 | | |
88 |
|
88 |
|
|
|
89 |
C4::Context::dbh->do('INSERT INTO aqorders ( ordernumber, budget_id ) VALUES ( 987654321, ? )', {}, ( $budget_id ) ); |
90 |
ok( GetBudgetByOrderNumber( '987654321' )->{'budget_id'} eq $budget_id, "GetBudgetByOrderNumber returns valid data" ); |
91 |
C4::Context::dbh->do('DELETE FROM aqorders WHERE ordernumber = 987654321'); |
92 |
|
89 |
my $budget; |
93 |
my $budget; |
90 |
ok($budget=GetBudget($budget_id) ,"GetBudget OK"); |
94 |
ok($budget=GetBudget($budget_id) ,"GetBudget OK"); |
91 |
$$budget{budget_permission}=1; |
95 |
$$budget{budget_permission}=1; |
Lines 102-105
ok(GetBudgets({budget_period_id=>GetBudgetPeriod($bpid)->{budget_period_id}},[{"
Link Here
|
102 |
ok($del_status=DelBudget($budget_id), |
106 |
ok($del_status=DelBudget($budget_id), |
103 |
"DelBudget returned $del_status"); |
107 |
"DelBudget returned $del_status"); |
104 |
|
108 |
|
105 |
|
|
|
106 |
- |