Add assurance vie to investment subtypes (#1665)

* add assurance vie in investment subtype

* add unit test for assurance vie subtype
This commit is contained in:
HugoleDino
2026-05-04 16:04:44 +02:00
committed by GitHub
parent 98df770547
commit ddaf42c96c
2 changed files with 5 additions and 0 deletions

View File

@@ -50,6 +50,7 @@ class Investment < ApplicationRecord
"smsf" => { short: "SMSF", long: "Self-Managed Super Fund", region: "au", tax_treatment: :tax_deferred },
# === Europe ===
"assurance_vie" => { short: "AV", long: "Assurance Vie", region: "eu", tax_treatment: :tax_advantaged },
"pea" => { short: "PEA", long: "Plan d'Épargne en Actions", region: "eu", tax_treatment: :tax_advantaged },
"pillar_3a" => { short: "Pillar 3a", long: "Private Pension (Pillar 3a)", region: "eu", tax_treatment: :tax_deferred },
"riester" => { short: "Riester", long: "Riester-Rente", region: "eu", tax_treatment: :tax_deferred },

View File

@@ -99,6 +99,10 @@ class InvestmentTest < ActiveSupport::TestCase
assert_equal :tax_advantaged, investment.tax_treatment
end
test "tax_treatment returns tax_advantaged for French AV" do
investment = Investment.new(subtype: "assurance_vie")
assert_equal :tax_advantaged, investment.tax_treatment
end
# Generic account types
test "tax_treatment returns tax_deferred for generic pension and retirement" do