diff --git a/spec/unit/attributes_spec.rb b/spec/unit/attributes_spec.rb index 8eb97e67b..678374780 100644 --- a/spec/unit/attributes_spec.rb +++ b/spec/unit/attributes_spec.rb @@ -171,10 +171,18 @@ class BarHistory3 < BarHistory2 expect(subject.duck).to eq ["Quack", "Peep"] end - it "should be able to track change status" do - expect { - subject.fubar = ["Meow"] - }.to change { subject.fubar_changed? }.from(false).to(true) + context "change tracking" do + it "should work for delegated attributes" do + expect { + subject.fubar = ["Meow"] + }.to change { subject.fubar_changed? }.from(false).to(true) + end + + it "should work for properties" do + expect { + subject.goose = ["honk!"] + }.to change { subject.goose_changed? }.from(false).to(true) + end end describe "array getters and setters" do