File: form_spec.rb

package info (click to toggle)
ruby-http 0.6.1-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 404 kB
  • ctags: 213
  • sloc: ruby: 2,397; makefile: 7
file content (17 lines) | stat: -rw-r--r-- 329 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
require 'spec_helper'

describe HTTP::Options, 'form' do

  let(:opts) { HTTP::Options.new }

  it 'defaults to nil' do
    expect(opts.form).to be nil
  end

  it 'may be specified with with_form_data' do
    opts2 = opts.with_form(:foo => 42)
    expect(opts.form).to be nil
    expect(opts2.form).to eq(:foo => 42)
  end

end