{"action":"opened","issue":{"url":"https://api.github.com/repos/zipmark/rspec_api_documentation/issues/239","labels_url":"https://api.github.com/repos/zipmark/rspec_api_documentation/issues/239/labels{/name}","comments_url":"https://api.github.com/repos/zipmark/rspec_api_documentation/issues/239/comments","events_url":"https://api.github.com/repos/zipmark/rspec_api_documentation/issues/239/events","html_url":"https://github.com/zipmark/rspec_api_documentation/issues/239","id":112236228,"number":239,"title":"Binary Data not being stripped out on multipart upload","user":{"login":"jeffutter","id":570037,"avatar_url":"https://avatars.githubusercontent.com/u/570037?v=3","gravatar_id":"","url":"https://api.github.com/users/jeffutter","html_url":"https://github.com/jeffutter","followers_url":"https://api.github.com/users/jeffutter/followers","following_url":"https://api.github.com/users/jeffutter/following{/other_user}","gists_url":"https://api.github.com/users/jeffutter/gists{/gist_id}","starred_url":"https://api.github.com/users/jeffutter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeffutter/subscriptions","organizations_url":"https://api.github.com/users/jeffutter/orgs","repos_url":"https://api.github.com/users/jeffutter/repos","events_url":"https://api.github.com/users/jeffutter/events{/privacy}","received_events_url":"https://api.github.com/users/jeffutter/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-10-19T21:24:29Z","updated_at":"2015-10-19T21:24:29Z","closed_at":null,"body":"I spent a few hours today trying to figure out why I was getting JSON encoding errors on my multipart-upload post doc specs. I eventually found an issue here: https://github.com/zipmark/rspec_api_documentation/issues/202 detailing that it should be stripped out and replaced with `[upload data]`. I am super glad that rspec_api_documentation handles this for me, as every attempt I tried to do on my own to strip the data out via regex was coming up short.\r\n\r\nNow that I know rspec_api_documentation was supposed to handle this form. I am still running into an issue where it is not properly stripping. I have have tracked it down to this line\r\n\r\nhttps://github.com/zipmark/rspec_api_documentation/blob/2c8f4df5cb6e3cc1d8022fc36cdef0d41b0cdfea/lib/rspec_api_documentation/rack_test_client.rb#L47\r\n\r\nWhen my test hits that line I have no `Content-Type` header, I have a `Content_type` header.\r\n\r\nMy spec looks roughly like this: \r\n\r\n```ruby\r\npost '/photo/create' do\r\n  let(:profile) { create(:profile) }\r\n  let(:basic) { \"Basic #{Base64.encode64(profile['token'])}:\" }\r\n  let(:event) { create(:event) }\r\n\r\n  header \"Authorization\", :basic\r\n  header \"Content-Type\", \"multipart/form-data\"\r\n\r\n  parameter :file, \"Photo File\"\r\n  parameter :original_filename, \"Original Photo Filename\"\r\n\r\n  let(:file) { Rack::Test::UploadedFile.new('spec/fixtures/files/file.jpg') }\r\n  let(:original_filename) { 'file.jpg' }\r\n\r\n  example_request \"Create a photo\" do\r\n    expect(status).to eq 200\r\n  end\r\nend\r\n```\r\n\r\nI can look into this more tomorrow. I wanted to drop the issue here though incase someone knew off hand what was going on.\r\n"}}