Sha256: 6afa1da496895f69ef9f076a2ea084a3dbf145f772ff510fb8aea01c12cb5ccb
Contents?: true
Size: 674 Bytes
Versions: 18
Compression:
Stored size: 674 Bytes
Contents
describe "FormController/SwitchRow" do tests Formotion::FormController # By default, `tests` uses @controller.init # this isn't ideal for our case, so override. def controller row_settings = { title: "Switch", key: :switch, type: :switch, value: false } @form ||= Formotion::Form.new( sections: [{ rows:[row_settings] }]) @controller ||= Formotion::FormController.alloc.initWithForm(@form) end it "should change row value when tapped" do tap("Switch Switch") @form.sections[0].rows[0].value.should == true tap("Switch Switch") @form.sections[0].rows[0].value.should == false end end
Version data entries
18 entries across 18 versions & 1 rubygems