Sha256: fc3571a09827e3358510469fe15df85fcd8dd7221cdc5f8c7ce009ebfe5ebdcd

Contents?: true

Size: 439 Bytes

Versions: 17

Compression:

Stored size: 439 Bytes

Contents

require "test_helper"

class PrivateOptionsTest < MiniTest::Spec # TODO: move me to separate file.
  representer!(decorator: true) do
  end

  options = {exclude: "name"}

  it "render: doesn't modify options" do
    representer.new(nil).to_hash(options)
    options.must_equal({exclude: "name"})
  end

  it "parse: doesn't modify options" do
    representer.new(nil).from_hash(options)
    options.must_equal({exclude: "name"})
  end
end

Version data entries

17 entries across 13 versions & 1 rubygems

Version Path
representable-3.0.4 test/private_options_test.rb
representable-3.0.3 test/private_options_test.rb
representable-3.0.2 test/private_options_test.rb
representable-3.0.1 test/private_options_test.rb
representable-3.0.0 test/private_options_test.rb
representable-2.4.1 test/private_options_test.rb
representable-2.4.1 test-with-deprecations/private_options_test.rb
representable-2.4.0 test/private_options_test.rb
representable-2.4.0 test-with-deprecations/private_options_test.rb
representable-2.4.0.rc5 test-with-deprecations/private_options_test.rb
representable-2.4.0.rc5 test/private_options_test.rb
representable-2.4.0.rc4 test/private_options_test.rb
representable-2.4.0.rc4 test-with-deprecations/private_options_test.rb
representable-2.4.0.rc3 test/private_options_test.rb
representable-2.4.0.rc2 test/private_options_test.rb
representable-2.4.0.rc1 test/private_options_test.rb
representable-2.3.0 test/private_options_test.rb