X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=inline;f=t%2Fdb_helper%2Fconvert_invoice.t;h=5622961437b056733defb00bc84ed08b417477c5;hb=60b17b3058bee155d03921bb0dfdabee274e9719;hp=b1ac4c24f6948739a2e6f3a5678b70eabf740bf7;hpb=63410aa68c7c57655dc66eba4291592358d46cf2;p=kivitendo-erp.git
diff --git a/t/db_helper/convert_invoice.t b/t/db_helper/convert_invoice.t
index b1ac4c24f..562296143 100644
--- a/t/db_helper/convert_invoice.t
+++ b/t/db_helper/convert_invoice.t
@@ -157,48 +157,14 @@ ok ($invoice->notes eq '
- fett
- undclosed) , 'Delivery Order is closed after conversion');
is($invoice->payment_terms->description, "14Tage 2%Skonto, 30Tage netto", 'payment term description check');
-# some test data from original client invoice console (!)
-# my $invoice3 = SL::DB::Manager::Invoice->find_by( ordnumber => 'A16399' );
-# which will fail due to PTC Calculation differs from GUI-Calculation, see issue: http://redmine.kivitendo-premium.de/issues/82
-# pp $invoice3
-# values from gui should be:
-#ok($invoice->amount == 1354.20000, 'amount check');
-#ok($invoice->marge_percent == 50.88666, 'marge percent check');
-#ok($invoice->marge_total == 579.08000, 'marge total check');
-#ok($invoice->netamount == 1137.98000, 'netamount check');
-
-
-# the values change if one reloads the object
-# without reloading we get this failures
-#not ok 17 - amount check
-# Failed test 'amount check'
-# at t/db_helper/convert_invoice.t line 272.
-# got: '1354.17'
-# expected: '1354.17000'
-#not ok 18 - marge percent check
-# Failed test 'marge percent check'
-# at t/db_helper/convert_invoice.t line 273.
-# got: '50.8857956342929'
-# expected: '50.88580'
-#not ok 19 - marge total check
-# Failed test 'marge total check'
-# at t/db_helper/convert_invoice.t line 274.
-# got: '579.06'
-# expected: '579.06000'
-#not ok 20 - netamount check
-# Failed test 'netamount check'
-# at t/db_helper/convert_invoice.t line 275.
-# got: '1137.96'
-# expected: '1137.96000'
-
$invoice->load;
is($invoice->cusordnumber , 'b84da' , 'cusordnumber check');
is($invoice->department->description , "Test Department" , 'department description ok');
-is($invoice->amount , '1354.17000' , 'amount check');
-is($invoice->marge_percent , '50.88580' , 'marge percent check');
-is($invoice->marge_total , '579.06000' , 'marge total check');
-is($invoice->netamount , '1137.96000' , 'netamount check');
+is($invoice->amount , '1354.20000' , 'amount check');
+is($invoice->marge_percent , '50.88666' , 'marge percent check');
+is($invoice->marge_total , '579.08000' , 'marge total check');
+is($invoice->netamount , '1137.98000' , 'netamount check');
# some item checks
is($invoice->items_sorted->[0]->parts_id , $parts[0]->id , 'invoiceitem 1 linked with part');
@@ -267,3 +233,10 @@ foreach ( $do1_item1->id, $do1_item2->id ) {
clear_up();
1;
+
+
+# vim: ft=perl
+# set emacs to perl mode
+# Local Variables:
+# mode: perl
+# End: