Sha256: 5be89f231f46ae1c3c6c86e30ba784d2411e852f8614cef68ecc212619b40600

Contents?: true

Size: 390 Bytes

Versions: 1

Compression:

Stored size: 390 Bytes

Contents

require "spec_helper"

describe Mashed::StringyHash do
  let(:hash) {{ a: 1, b: 2, c: { three: 3 }}}

  describe "#stringify" do
    it { expect(hash.stringify).to eq("a" => 1, "b" => 2, "c" => { "three" => 3 }) }
  end

  describe "get and set" do
    let(:s) { hash.stringify }
    before { s[:a] = "A" }
    it { expect(s[:a]).to eq("A") }
    it { expect(s["a"]).to eq("A") }
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
mashed-0.5.1 spec/mashed/stringy_hash_spec.rb