@ -1,4 +1,11 @@
class Form::Sales::Pages::MortgageLength < ::Form::Page
def initialize(id, hsh, subsection)
super
@depends_on = [{
"mortgageused" => 1,
}]
end
def questions
@questions ||= [
Form::Sales::Questions::MortgageLength.new(nil, nil, self),
@ -28,6 +28,8 @@ RSpec.describe Form::Sales::Pages::MortgageLength, type: :model do
it "has correct depends_on" do
expect(page.depends_on).to be_nil
expect(page.depends_on).to eq([{
}])