Sha256: 955ba8a17ac1e3f9e0aa52691051a8dcfd3bc13f621ceb2fe5543afafb6f46cc
Contents?: true
Size: 881 Bytes
Versions: 6
Compression:
Stored size: 881 Bytes
Contents
module TransactionHelpers def uploaded_file if DependencyHelper.rails_present? ActionDispatch::Http::UploadedFile.new(:tempfile => '/tmp') else ::Rack::Multipart::UploadedFile.new(File.join(fixtures_dir, '/uploaded_file.txt')) end end def background_job_transaction(args={}) Appsignal::Transaction.create( '1', Appsignal::Transaction::BACKGROUND_JOB, Appsignal::Transaction::GenericRequest.new({ 'SERVER_NAME' => 'localhost', 'action_dispatch.routes' => 'not_available' }.merge(args)) ) end def http_request_transaction(args={}) Appsignal::Transaction.create( '1', Appsignal::Transaction::HTTP_REQUEST, Appsignal::Transaction::GenericRequest.new({ 'SERVER_NAME' => 'localhost', 'action_dispatch.routes' => 'not_available' }.merge(args)) ) end end
Version data entries
6 entries across 6 versions & 1 rubygems