0

そのように見えるフィールドをfill_inする方法はありますか...

<span id="you_cannot_see_me" style="display: none;">              
    <input id="hidey" name="hidey" type="text" value="">          
</span>

私が試してみました...

accessthis = find('#hidey').should_not be_visible
fill_in( accessthis , :with => 'desired text')

...そして次のエラーを受け取ります

Unable to find field false (Capybara::ElementNotFound)

何か案は?

4

1 に答える 1

4

Seleniumを使用すると、表示されていないWeb要素を操作できません。Seleniumは実際のユーザー操作を模倣するために使用されるため、手動で実行できないことはSeleniumでは実行できません。

于 2013-01-11T16:53:28.090 に答える