diff options
-rw-r--r-- | src/xact.cc | 3 | ||||
-rw-r--r-- | test/regress/1127.test | 15 |
2 files changed, 17 insertions, 1 deletions
diff --git a/src/xact.cc b/src/xact.cc index c62974df..5df9ebc5 100644 --- a/src/xact.cc +++ b/src/xact.cc @@ -806,8 +806,9 @@ void auto_xact_t::extend_xact(xact_base_t& xact, parse_context_t& context) xact.add_post(new_post); new_post->account->add_post(new_post); - // Add flag so this post updates the account balance + // Add flags so this post updates the account balance new_post->xdata().add_flags(POST_EXT_VISITED); + new_post->account->xdata().add_flags(ACCOUNT_EXT_VISITED); if (new_post->must_balance()) needs_further_verification = true; diff --git a/test/regress/1127.test b/test/regress/1127.test new file mode 100644 index 00000000..905401f8 --- /dev/null +++ b/test/regress/1127.test @@ -0,0 +1,15 @@ +; Test that automated transactions are added to accounts soon enough +; for assertions to work. + += expr account =~ /^Assets/ + (Foo) 1 + +2018-06-09 Something + Assets $100 + Equity + +2018-06-09 Assert amount added by automated transaction + [Foo] = $100 +test bal Foo + $100 Foo +end test |