X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/d0b6af4dcb0e4b0ff1c34fa6e07e6a8a926ec366..975a63bb889dcf4d18ba3c6be7374aa744a962f3:/t/datev/datev_format_2018.t diff --git a/t/datev/datev_format_2018.t b/t/datev/datev_format_2018.t index 4e43b3c0b..77a800ef8 100644 --- a/t/datev/datev_format_2018.t +++ b/t/datev/datev_format_2018.t @@ -19,6 +19,10 @@ Support::TestSetup::login(); my $dbh = SL::DB->client->dbh; clear_up(); + +my $d = SL::DB::Default->get; +$d->update_attributes(datev_export_format => 'cp1252'); + my $buchungsgruppe7 = SL::DB::Manager::Buchungsgruppe->find_by(description => 'Standard 7%') || die "No accounting group for 7\%"; my $date = DateTime->new(year => 2017, month => 7, day => 19); my $department = create_department(description => 'Kästchenweiße heiße Preise'); @@ -145,7 +149,7 @@ ok(scalar @{ $datev_csv4->warnings } == 0, 'no warnings'); my @sorted = sort { $a->[0] cmp $b->[0] } @{ $lines_aref }; cmp_deeply $sorted[0], [ '1963,5', 'S', 'EUR', '', '', '', '1400', '8400', '', '1907', 'meine muh', - '', '', '', '', '', '', '', '', '', + '', '', 'Test customer', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', "K\x{e4}stchen", '299', '','DE12345678', '', '', '', @@ -161,7 +165,7 @@ cmp_deeply $sorted[0], [ '1963,5', 'S', 'EUR', '', '', '', ]; cmp_deeply $sorted[1], [ '535', 'S', 'EUR', '', '', '', '1400', '8300', '', '1907','meine muh', - '', '', '', '', '', '', '', '', '', + '', '', 'Test customer', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', "K\x{e4}stchen", '299', '','DE12345678', '', '', '', @@ -235,7 +239,6 @@ my $datev2 = SL::DATEV->new( $datev2->from($startdate); $datev2->to($enddate); $datev2->generate_datev_data; -$datev2->generate_datev_lines; my $datev_csv3 = SL::DATEV::CSV->new(datev_lines => $datev2->generate_datev_lines, from => $startdate, @@ -244,8 +247,8 @@ my $datev_csv3 = SL::DATEV::CSV->new(datev_lines => $datev2->generate_datev_li ); my @data_csv = sort { $a->[0] cmp $b->[0] } @{ $datev_csv3->lines }; -cmp_deeply($data_csv[0], [ 100, 'H', 'EUR', '', '', '', '4660', '1000', 9, '1703', 'Reise März 2', - '', '', '', '', '', '', '', '', '', '', '', +cmp_deeply($data_csv[0], [ '100', 'S', 'EUR', '', '', '', '4660', '1000', 9, '1703', 'Reise März 2', + '', '', 'Reisekonsten März 2018 / Ma Schmidt', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '',