Restructure omni services and add Chatwoot research snapshot
This commit is contained in:
9
research/chatwoot/spec/support/file_upload_helpers.rb
Normal file
9
research/chatwoot/spec/support/file_upload_helpers.rb
Normal file
@@ -0,0 +1,9 @@
|
||||
module FileUploadHelpers
|
||||
def get_blob_for(file_path, content_type)
|
||||
ActiveStorage::Blob.create_and_upload!(
|
||||
io: File.open(file_path, 'rb'),
|
||||
filename: File.basename(file_path),
|
||||
content_type: content_type
|
||||
)
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user