Sha256: 1e961b51e8640c32fb72c53d524e92b206419024b17e457f48cce9824fea98f1

Contents?: true

Size: 1.65 KB

Versions: 1

Compression:

Stored size: 1.65 KB

Contents

# frozen_string_literal: true

describe Zapata::Revolutionist do
  before(:all) do
    @generated = exec_generation('app/models/test_send.rb')
  end

  it '#another_method_as_arg' do
    has_block('#another_method_as_arg', %{
      expect(test_send.another_method_as_arg('Help method')).to eq('Help method')
    })
  end

  # it '#second_level_method_chain' do
  #   has_block('#second_level_method_chain', %Q{
  #     expect(test_send.second_level_method_chain('Help method')).to eq('Help method')
  #   })
  # end

  # it '#third_level_method_chain' do
  #   has_block('#third_level_method_chain', %Q{
  #     expect(test_send.third_level_method_chain('Help method')).to eq('Help method')
  #   })
  # end

  # it '#method_with_calculated_value' do
  #   has_block('#method_with_calculated_value', %Q{
  #     expect(test_send.method_with_calculated_value('Missing "calculated_value"')).to eq('Missing "calculated_value"')
  #   })
  # end

  it '#to_another_object' do
    has_block('#to_another_object', %{
      expect(test_send.to_another_object(AnotherObject.my_name)).to eq('Domas')
    })
  end

  it '#to_another_object_with_params' do
    has_block('#to_another_object_with_params', %{
      expect(test_send.to_another_object_with_params(AnotherObject.send_with_params(12))).to eq('Id was 12')
    })
  end

  it '#not_explicit_with_params' do
    has_block('#not_explicit_with_params', %{
      expect(test_send.not_explicit_with_params('Could you find it?')).to eq('Could you find it?')
    })
  end

  it '#fail_to_understand' do
    has_block('#fail_to_understand', %{
      expect(test_send.fail_to_understand('Missing "failure"')).to eq('Missing "failure"')
    })
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
zapata-1.0.0 spec/send_spec.rb