Sha256: 4b936a66f1037046d893305c2f15ff471e0664e51f7926e26cb4cf41b2c2f8f7
Contents?: true
Size: 1 KB
Versions: 5
Compression:
Stored size: 1 KB
Contents
require 'spec_helper' describe Clieop do it "should test basic invoice usage" do file = Clieop::File.new file.invoice_batch({:description => 'some description', :account_nr => 123, :account_owner => 'me'}) do |batch| batch << { :account_nr => 123456, :account_owner => 'you', :amount => 133.0, :description => "Testing a CLIEOP direct debt transaction\nCharging your bank account" } batch << { :account_nr => 654321, :account_owner => 'somebody else', :amount => 233.0, :description => 'Some description for the other guy' } end clieop_data = file.to_clieop clieop_data.class.should eql(String) end it "should format the checksum" do batch = Clieop::Batch.new({:description => "Description", :account_nr => "Account Nr", :account_owner => "Account Owner" } ) batch.account_checksum('1234567890123').should eql('4567890123') batch.account_checksum('7654321').should eql('7654321') end #TODO: more tests end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
clieop-0.2.2 | spec/clieop_spec.rb |
clieop-0.2.1 | spec/clieop_spec.rb |
clieop-0.2.0 | spec/clieop_spec.rb |
clieop-0.1.4 | spec/clieop_spec.rb |
clieop-0.1.3 | spec/clieop_spec.rb |