-
-
Notifications
You must be signed in to change notification settings - Fork 478
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
4635: Comment is missing from purchase details #4642
Changes from 5 commits
4f96571
1731bfe
803a9dd
834f25f
83ee754
1364f82
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -264,7 +264,19 @@ | |
|
||
describe "GET #show" do | ||
let(:item) { create(:item) } | ||
let!(:purchase) { create(:purchase, :with_items, item: item) } | ||
let(:storage_location) { create(:storage_location, organization: organization, name: 'Some Storage') } | ||
let(:vendor) { create(:vendor, organization: organization, business_name: 'Another Business') } | ||
let!(:purchase) { create(:purchase, :with_items, comment: 'Fine day for diapers, it is.', created_at: 1.month.ago, issued_at: 1.day.ago, item: item, storage_location: storage_location, vendor: vendor) } | ||
|
||
it "shows the purchase info" do | ||
date_of_purchase = "#{1.day.ago.to_fs(:distribution_date)} (entered: #{1.month.ago.to_fs(:distribution_date)})" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think you might have to use the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I fixed here 1364f82 |
||
|
||
get purchase_path(id: purchase.id) | ||
expect(response.body).to include(date_of_purchase) | ||
expect(response.body).to include('Another Business') | ||
expect(response.body).to include('Some Storage') | ||
expect(response.body).to include('Fine day for diapers, it is.') | ||
end | ||
|
||
it "shows an enabled edit button" do | ||
get purchase_path(id: purchase.id) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you fix up the spacing here? Nested elements like
tr
andtd
should be indented more than the parent.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fixed here 834f25f
I also fixed the indentation of the
tr
andtd
tags from the table above