Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import static name.abuchen.portfolio.datatransfer.ExtractorMatchers.hasAmount;
import static name.abuchen.portfolio.datatransfer.ExtractorMatchers.hasCurrencyCode;
import static name.abuchen.portfolio.datatransfer.ExtractorMatchers.hasDate;
import static name.abuchen.portfolio.datatransfer.ExtractorMatchers.hasExDate;
import static name.abuchen.portfolio.datatransfer.ExtractorMatchers.hasFees;
import static name.abuchen.portfolio.datatransfer.ExtractorMatchers.hasForexGrossValue;
import static name.abuchen.portfolio.datatransfer.ExtractorMatchers.hasGrossValue;
Expand Down Expand Up @@ -603,7 +604,8 @@ public void testDividende01()

// check dividends transaction
assertThat(results, hasItem(dividend( //
hasDate("2024-02-15T00:00"), hasShares(248.00), //
hasDate("2024-02-15T00:00"), hasExDate(null), //
hasShares(248.00), //
hasSource("Dividende01.txt"), //
hasNote(null), //
hasAmount("EUR", 28.24), hasGrossValue("EUR", 40.33), //
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -280,16 +280,16 @@ private <T extends Transaction<?>> void addTaxesSectionsTransaction(T transactio
// TOTAL EUR 0,00 12,09 28,24 0,00 28,24
// @formatter:on
.section("currency", "tax").optional() //
.find("Revenus.*")
.find("Revenus.*") //
.match("^TOTAL (?<currency>[A-Z]{3}) [\\,\\d\\s]+ (?<tax>[\\,\\d\\s]+) [\\,\\d\\s]+ [\\,\\d\\s]+ [\\,\\d\\s]+$") //
.assign((t, v) -> processTaxEntries(t, v, type))

// @formatter:off
// Montant brut Commission Frais (¨) Montant net au débit de votre compte
// 10,99 EUR 2,02 EUR 3,03 EUR 16,04 EUR
// @formatter:on
.section("currency", "tax").optional() //
.find("Montant.*")
.find("Montant.*") //
.match("^[\\d\\s]+,[\\d]{2} [A-Z]{3} [\\d\\s]+,[\\d]{2} [A-Z]{3} (?<tax>[\\d\\s]+,[\\d]{2}) (?<currency>[A-Z]{3}) [\\d\\s]+,[\\d]{2} [A-Z]{3}$") //
.assign((t, v) -> processTaxEntries(t, v, type));
}
Expand All @@ -303,7 +303,7 @@ private <T extends Transaction<?>> void addFeesSectionsTransaction(T transaction
// 965,02 EUR 4,83 EUR 969,85 EU
// @formatter:on
.section("fee", "currency").optional() //
.find("Montant.*")
.find("Montant.*") //
.match("^[\\d\\s]+,[\\d]{2} [A-Z]{3} (?<fee>[\\d\\s]+,[\\d]{2}) (?<currency>[A-Z]{3}) [\\d\\s]+,[\\d]{2} [A-Z]{3}$") //
.assign((t, v) -> processFeeEntries(t, v, type))

Expand All @@ -312,16 +312,16 @@ private <T extends Transaction<?>> void addFeesSectionsTransaction(T transaction
// 6,95 EUR 0,00 EUR 6,95 EUR
// @formatter:on
.section("fee", "currency").optional() //
.find("Commission Frais divers.*")
.find("Commission Frais divers.*") //
.match("^(?<fee>[\\d\\s]+,[\\d]{2}) (?<currency>[A-Z]{3}) [\\d\\s]+,[\\d]{2} [A-Z]{3} [\\d\\s]+,[\\d]{2} [A-Z]{3}$") //
.assign((t, v) -> processFeeEntries(t, v, type))

// @formatter:off
// Montant brut Commission Frais (¨) Montant net au débit de votre compte
// 10,99 EUR 2,02 EUR 3,03 EUR 16,04 EUR
// @formatter:on
.section("fee", "currency").optional() //
.find("Montant.*")
.find("Montant.*") //
.match("^[\\d\\s]+,[\\d]{2} [A-Z]{3} (?<fee>[\\d\\s]+,[\\d]{2}) (?<currency>[A-Z]{3}) [\\d\\s]+,[\\d]{2} [A-Z]{3} [\\d\\s]+,[\\d]{2} [A-Z]{3}$") //
.assign((t, v) -> processFeeEntries(t, v, type));
}
Expand Down
Loading