From 6f75f7bb9eec1325cf3c1527c571fbe392b478ad Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Tue, 6 Feb 2018 12:15:02 -0300 Subject: [PATCH] Bug 20144: [sql_modes] Set default value for Itemtype fees in TestBuilder Fix for: Out of range value for column 'amount' t/db_dependent/Circulation/Chargelostitem.t Signed-off-by: Josef Moravec Signed-off-by: Julian Maurice Signed-off-by: Jonathan Druart --- t/db_dependent/Circulation/Chargelostitem.t | 5 ++++- t/lib/TestBuilder.pm | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/t/db_dependent/Circulation/Chargelostitem.t b/t/db_dependent/Circulation/Chargelostitem.t index 9d070b69c6..dfcee305bb 100644 --- a/t/db_dependent/Circulation/Chargelostitem.t +++ b/t/db_dependent/Circulation/Chargelostitem.t @@ -32,7 +32,10 @@ my $library = $builder->build({ my $branchcode = $library->{branchcode}; my $itemtype = $builder->build({ - source => 'Itemtype' + source => 'Itemtype', + value => { + processfee => 42, + } }); my %item_branch_infos = ( diff --git a/t/lib/TestBuilder.pm b/t/lib/TestBuilder.pm index 086635e104..1aa6de9762 100644 --- a/t/lib/TestBuilder.pm +++ b/t/lib/TestBuilder.pm @@ -479,6 +479,8 @@ sub _gen_default_values { }, Itemtype => { rentalcharge => 0, + defaultreplacecost => 0, + processfee => 0, }, Aqbookseller => { tax_rate => 0, -- 2.39.5