asciinema.org/spec/requests/asciicast_upload_spec.rb

14 lines
457 B
Ruby
Raw Normal View History

2013-08-08 13:41:57 +00:00
require 'spec_helper'
describe "Asciicast upload" do
it 'returns the URL to the uploaded asciicast' do
post '/api/asciicasts', :asciicast => {
2013-08-25 14:34:02 +00:00
:meta => fixture_file('meta.json', 'application/json'),
:stdout => fixture_file('stdout', 'application/octet-stream'),
:stdout_timing => fixture_file('stdout.time', 'application/octet-stream')
2013-08-08 13:41:57 +00:00
}
expect(response.body).to eq(asciicast_url(Asciicast.last))
end
end