add placeholder account attribute

This commit is contained in:
josh committed 2013-08-31 16:27:47 -04:00
1 parent 9ee49d949d
commit 4e882e60dc
2 files changed
+16

No files matched your search

+9
View File
@@ -3,7 +3,9 @@ module Gnucash
before(:all) do
# just read the file once
@book = Gnucash.open("spec/books/sample.gnucash")
@assets = @book.find_account_by_full_name("Assets")
@checking = @book.find_account_by_full_name("Assets::Current Assets::Checking Account")
@income = @book.find_account_by_full_name("Income")
@salary = @book.find_account_by_full_name("Income::Salary")
end
@@ -36,5 +38,12 @@ module Gnucash
@checking.balance_on("2007-03-27").should == Value.new(780000)
end
end
it "stores whether the account was a placeholder" do
@assets.placeholder.should be_true
@checking.placeholder.should be_false
@income.placeholder.should be_true
@salary.placeholder.should be_false
end
end
end