Sha256: c2cd651e00c720eb950742dd1c414c385160d6e3acf617e65e86021e15d28c2e

Contents?: true

Size: 687 Bytes

Versions: 10

Compression:

Stored size: 687 Bytes

Contents

require 'spec_helper'

describe Hash do
  describe 'markdownified!' do
    let(:hash) { { something: 'hello **world**', something_else: '`the code`', other: '_foo_' } }

    context 'without options' do
      before { hash.markdownified! :something, :something_else }
      it { expect(hash).to eq other: "_foo_", something: "<p>hello <strong>world</strong></p>\n", something_else: "<p><code>the code</code></p>\n" }
    end

    context 'with options' do
      before { hash.markdownified! :something, :something_else, one_liner: true }
      it { expect(hash).to eq other: "_foo_", something: "hello <strong>world</strong>", something_else: "<code>the code</code>" }
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
mumuki-laboratory-7.11.1 vendor/bundle/ruby/2.6.0/bundler/gems/mumuki-domain-c92f2a7212e2/spec/models/hash_spec.rb
mumuki-laboratory-7.11.0 vendor/bundle/ruby/2.6.0/bundler/gems/mumuki-domain-2e15c3330133/spec/models/hash_spec.rb
mumuki-laboratory-7.9.2 vendor/bundle/ruby/2.6.0/bundler/gems/mumuki-domain-7082a83493eb/spec/models/hash_spec.rb
mumuki-laboratory-7.9.1 vendor/bundle/ruby/2.6.0/bundler/gems/mumuki-domain-b162dc91aa77/spec/models/hash_spec.rb
mumuki-laboratory-7.9.0 vendor/bundle/ruby/2.6.0/bundler/gems/mumuki-domain-520f859ca8af/spec/models/hash_spec.rb
mumuki-laboratory-7.7.1 vendor/bundle/ruby/2.6.0/bundler/gems/mumuki-domain-cb7a9018bb94/spec/models/hash_spec.rb
mumuki-laboratory-7.7.0 vendor/bundle/ruby/2.6.0/bundler/gems/mumuki-domain-cb7a9018bb94/spec/models/hash_spec.rb
mumuki-laboratory-7.5.2 vendor/bundle/ruby/2.6.0/bundler/gems/mumuki-domain-ad16a5930cec/spec/models/hash_spec.rb
mumuki-laboratory-7.5.1 vendor/bundle/ruby/2.3.0/bundler/gems/mumuki-domain-a059418e5fd8/spec/models/hash_spec.rb
mumuki-laboratory-7.5.0 vendor/bundle/ruby/2.6.0/bundler/gems/mumuki-domain-acb12583b793/spec/models/hash_spec.rb