私はこれが間違ったやり方であることを十分に承知していますが、私はルビーにそれほど精通していません。最善の選択肢はユースケースであると確信していますか?またはループ?
def addInfoToStory(idOfStory, storyTitle, storyPriority, storyEST, storySupporter, storyBugzilla, storyStatus, storyOutcome, storyCustomer, storyNotes)
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>1).div.double_click
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>1).div(:class => "formLib1").text_field(:id, 'input').set"#{storyTitle}"
@browser.send_keys :tab
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>2).div.double_click
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>2).div(:class => "formLib1").text_field(:id, 'input').set"#{storyPriority}"
@browser.send_keys :tab
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>3).div.double_click
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>3).div(:class => "formLib1").text_field(:id, 'input').set"#{storyEST}"
@browser.send_keys :tab
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>4).div.double_click
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>4).div(:class => "formLib1").text_field(:id, 'input').set"#{storySupporter}"
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>5).div.double_click
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>5).div(:class => "formLib1").text_field(:id, 'input').set"#{storyBugzilla}"
@browser.send_keys :tab
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>6).div.double_click
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>6).div(:class => "formLib1").text_field(:id, 'input').set"#{storyStatus}"
@browser.send_keys :tab
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>7).div.double_click
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>7).div(:class => "formLib1").text_field(:id, 'input').set"#{storyOutcome}"
@browser.send_keys :tab
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>8).div.double_click
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>8).div(:class => "formLib1").text_field(:id, 'input').set"#{storyCustomer}"
@browser.send_keys :tab
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>9).div.double_click
@browser.div(:id => "#{idOfStory}"+"_firstCol").div(:class => "tDetEntry", :index =>9).div(:class => "formLib1").text_field(:id, 'input').set"#{storyNotes}"
@browser.send_keys :tab
end
フォームに記入するこのプロセスを実行するための最も効率的な方法に関する提案はありますか?