spec/lib/hyperion/formats_spec.rb in hyperion_http-0.1.6 vs spec/lib/hyperion/formats_spec.rb in hyperion_http-0.1.7
- old
+ new
@@ -80,9 +80,16 @@
expect(read('{"a":1}', :json)).to eql({'a' => 1})
end
it 'allows protobuf format but just passes it through' do
expect(read('x', :protobuf)).to eql 'x'
end
+ it 'allows multipart format data format but just passes it through' do
+ data = '--------------------------0bf18f00cf53ec0e' +
+ 'Content-Disposition: form-data; name="file"; filename="test"' +
+ 'Content-Type: application/octet-stream' +
+ '--------------------------0bf18f00cf53ec0e--'
+ expect(read(data, Multipart.format)).to eql data
+ end
end
end
end
end