Sha256: e09ab43db473fabe7d63a211b24014d4ece668bd0a5b1b675f46b3e90fd0ae96
Contents?: true
Size: 464 Bytes
Versions: 6
Compression:
Stored size: 464 Bytes
Contents
require 'spec_helper' RSpec.describe Yaks::FP::Updatable do let(:klz) do Class.new do include Equalizer.new(:aa, :bb, :cc) include Yaks::FP::Updatable.new(:aa, :bb, :cc) attr_reader :aa, :bb, :cc private :aa def initialize(aa, bb, cc) @aa, @bb, @cc = aa, bb, cc end end end it 'should only updated the selected fields' do expect(klz.new(1,2,3).update(bb: 7, cc: 9)).to eq klz.new(1,7,9) end end
Version data entries
6 entries across 6 versions & 2 rubygems