Browse Source

feat: add hint text and update test (#1171)

pull/1195/head
natdeanlewissoftwire 2 years ago committed by GitHub
parent
commit
524172f260
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      app/models/form/lettings/questions/renewal.rb
  2. 2
      spec/models/form/lettings/questions/renewal_spec.rb

1
app/models/form/lettings/questions/renewal.rb

@ -6,6 +6,7 @@ class Form::Lettings::Questions::Renewal < ::Form::Question
@header = "Is this letting a renewal?"
@type = "radio"
@answer_options = ANSWER_OPTIONS
@hint_text = "A renewal is a letting to the same tenant in the same property"
end
ANSWER_OPTIONS = {

2
spec/models/form/lettings/questions/renewal_spec.rb

@ -28,7 +28,7 @@ RSpec.describe Form::Lettings::Questions::Renewal, type: :model do
end
it "has the correct hint_text" do
expect(question.hint_text).to be_nil
expect(question.hint_text).to eq("A renewal is a letting to the same tenant in the same property")
end
it "has the correct answer_options" do

Loading…
Cancel
Save