Add spec about #touch not saving changes

This commit is contained in:
fukayatsu 2018-05-14 18:45:11 +09:00
parent b0a16a33aa
commit 269f32bb22
1 changed files with 6 additions and 0 deletions

View File

@ -20,6 +20,12 @@ module On
)
expect(record.versions.last.event).to eq("update")
end
it "saves a object" do
record = described_class.create(name: "Alice")
record.touch
expect(record.versions.last.reify.name).to eq("Alice")
end
end
describe "#update" do