Sha256: 6038e881c91a624ee6e082e89381a14bda23e42466c162917a4790c27087fff2
Contents?: true
Size: 488 Bytes
Versions: 29
Compression:
Stored size: 488 Bytes
Contents
module Pacioli class JournalEntryValidator attr_accessor :journal_entry def self.for(journal_entry) validator = new validator.journal_entry = journal_entry validator end def execute unless self.journal_entry.balanced? raise Pacioli::AccountsNotBalancedException, "The aggregate balance of all accounts having positive balances must be equal to the aggregate balance of all accounts having negative balances." end end end end
Version data entries
29 entries across 29 versions & 1 rubygems