Remove unused methods to attach files in tests
These methods aren't used since commitseef8ad1b7and2993ef87.
This commit is contained in:
@@ -134,12 +134,3 @@ shared_examples "documentable" do |documentable_factory_name, documentable_path,
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def attach_document(path, success = true)
|
||||
attach_file :document_attachment, path, make_visible: true
|
||||
if success
|
||||
expect(page).to have_css ".loading-bar.complete"
|
||||
else
|
||||
expect(page).to have_css ".loading-bar.errors"
|
||||
end
|
||||
end
|
||||
|
||||
@@ -30,14 +30,3 @@ shared_examples "imageable" do |imageable_factory_name, imageable_path, imageabl
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def attach_image(path, success = true)
|
||||
image = find(".image")
|
||||
image_input = image.find("input[type=file]", visible: false)
|
||||
attach_file image_input[:id], path, make_visible: true
|
||||
if success
|
||||
expect(page).to have_css ".loading-bar.complete"
|
||||
else
|
||||
expect(page).to have_css ".loading-bar.errors"
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user