mirror of
https://github.com/internetee/registry.git
synced 2025-06-11 23:24:48 +02:00
Remove useless specs
This commit is contained in:
parent
93a069648e
commit
3c96d3206f
1 changed files with 0 additions and 47 deletions
|
@ -1,47 +0,0 @@
|
|||
require 'rails_helper'
|
||||
|
||||
describe BankTransaction do
|
||||
context 'with invalid attribute' do
|
||||
before :all do
|
||||
@bank_transaction = BankTransaction.new
|
||||
end
|
||||
|
||||
it 'should not be valid' do
|
||||
@bank_transaction.valid?
|
||||
@bank_transaction.errors.full_messages.should match_array([
|
||||
])
|
||||
end
|
||||
|
||||
it 'should not have any versions' do
|
||||
@bank_transaction.versions.should == []
|
||||
end
|
||||
end
|
||||
|
||||
context 'with valid attributes' do
|
||||
before :all do
|
||||
@bank_transaction = create(:bank_transaction)
|
||||
create(:registrar)
|
||||
end
|
||||
|
||||
it 'should be valid' do
|
||||
@bank_transaction.valid?
|
||||
@bank_transaction.errors.full_messages.should match_array([])
|
||||
end
|
||||
|
||||
it 'should be valid twice' do
|
||||
@bank_transaction = create(:bank_statement)
|
||||
@bank_transaction.valid?
|
||||
@bank_transaction.errors.full_messages.should match_array([])
|
||||
end
|
||||
|
||||
it 'should have one version' do
|
||||
with_versioning do
|
||||
@bank_transaction.versions.should == []
|
||||
@bank_transaction.bank_reference = '123'
|
||||
@bank_transaction.save
|
||||
@bank_transaction.errors.full_messages.should match_array([])
|
||||
@bank_transaction.versions.size.should == 1
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue