鉴于视图中的此 HTML:
<form id="new_merchant_user" method="post">
<fieldset>
<div id='legend'>
<legend>Recover Pasword</legend>
</div>
<input id="merchant_user_email" name="merchant_user[email]" type="text" value="" />
<input class="btn btn-success" name="commit" type="submit" value="Send Reset Instructions" />
</fieldset>
</form>
如何使用 assert_select 选择按钮的值?我试试
assert_select 'form input[type=submit]', "Send Reset Instructions"
但它失败了
<Send Reset Instructions> expected but was
<>..
Expected 0 to be >= 1.
基本上,什么都不选。
我在这里做错了什么?