Sha256: 457674d1450e7e82b49c52a80844ccc4779085f9307c7cf16c4e96e6fe4690b4
Contents?: true
Size: 528 Bytes
Versions: 11
Compression:
Stored size: 528 Bytes
Contents
module SharedRecordExamples def test_sets_up_id assert_instance_of(Fixnum, @record.id) assert_equal(@json['id'], @record.id) end def test_persisted? assert record_class.new(client, id: 123).persisted? assert !record_class.new(client, {}).persisted? assert !record_class.new(client).persisted? end def test_saving @client.adapter_for(record_class.demodulized_name).expects(:save).with(@record, {}) @record.save end def client @client ||= Gecko::Client.new('ABC', 'DEF') end end
Version data entries
11 entries across 11 versions & 1 rubygems