Skip to content

Instantly share code, notes, and snippets.

@eitoball
Created August 6, 2013 05:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save eitoball/6162237 to your computer and use it in GitHub Desktop.
Save eitoball/6162237 to your computer and use it in GitHub Desktop.
context '納品書から' do
context '請求書を変換する場合' do
before do
@user = FactoryGirl.create(:user) do |u|
u.sender.bank_accounts.create(detail: 'Foo Bank')
end
end
it '請求元の銀行口座の情報をコピーする' do
invoice = described_class.from(@user.delivery_slips.first).to(:invoice)
invoice.save
@user.reload
invoice.reload
p @user.sender.bank_accounts
p invoice.invoice_body.bank_accounts
pending
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment