P3: assets' posted and scheduled depreciation, their bases, and the K-1 on the tax basis (defect 13, D-41)
check / check (push) Canceled after 0s
check / check (push) Canceled after 0s
Book value is cost less what the books posted; the schedule's figure is apart. An asset's acquired date comes from its entry. Contributed property keeps its section 723 carryover basis apart from its depreciable basis (the lower of value and adjusted basis), with its 704(c) built-in gain and method. The K-1 worksheet reports tax-basis capital (Form 1065 Item L) beside the book figures, leaving open what only the CPA knows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01T3gXMVt7XJPi6ens1or9Dj
This commit is contained in:
81 files changed
+9391
-2604
No files matched your search
@@ -461,4 +461,27 @@ proptest! {
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/// kernel::basis_figures at i64 (what Kani's basis_figures_laws
|
||||
/// proved) and at Decimal agree, rule by rule.
|
||||
#[test]
|
||||
fn basis_figures_agree(
|
||||
rule in prop_oneof![
|
||||
Just(ledger_core::BasisRule::Purchase),
|
||||
Just(ledger_core::BasisRule::Carryover723),
|
||||
Just(ledger_core::BasisRule::PersonalUseConversion),
|
||||
],
|
||||
cost in arb_cents(),
|
||||
adjusted in arb_cents(),
|
||||
fmv in arb_cents(),
|
||||
) {
|
||||
let i = kernel::basis_figures(rule, cost, adjusted, fmv);
|
||||
let d = kernel::basis_figures(rule, dec(cost), dec(adjusted), dec(fmv));
|
||||
prop_assert_eq!(i.is_some(), d.is_some());
|
||||
if let (Some(i), Some(d)) = (i, d) {
|
||||
prop_assert_eq!(i.tax_basis_723.map(dec), d.tax_basis_723);
|
||||
prop_assert_eq!(dec(i.depreciable_basis), d.depreciable_basis);
|
||||
prop_assert_eq!(i.built_in_gain_704c.map(dec), d.built_in_gain_704c);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user