Note that there are some explanatory texts on larger screens.

plurals
  1. POtesting with minitest capybara rails link not found
    text
    copied!<p>I'm currently testing with minitest capybara and I got an error on one of my tests</p> <pre><code>Unable to find link or button "Edit Profile" </code></pre> <p>here is my test</p> <pre><code>require "test_helper" feature "as a student I want a working user system so grade = good" do scenario "users can update profile" do dude_sign_up dude_log_in click_on "Edit Profile" click_on "Update" page.must_have_content "Profile was successfully updated" end end </code></pre> <p>the two helper methods for test helper</p> <pre><code>def dude_sign_up visit new_user_path fill_in "Name", with: 'thedude' fill_in "Email", with: "dude@dudecool.com" fill_in "Password", with: 'password' fill_in "Password confirmation", with: 'password' click_on "Sign Up" end def dude_log_in visit posts_path fill_in "Email", with: "dude@dudecool.com" fill_in "Password", with: 'password' click_on "Log In" end </code></pre> <p>and if its needed my here is my _nav that I have rendered in application.html.erb between and above the yield </p> <pre><code>&lt;nav class="navbar navbar-inverse navbar-fixed-top" role="navigation"&gt; &lt;div class="container"&gt; &lt;ul class="nav navbar-nav navbar-right"&gt; &lt;li&gt;&lt;%= link_to 'Home', root_path %&gt;&lt;/li&gt; &lt;li&gt;&lt;%= link_to 'About', about_path %&gt;&lt;/li&gt; &lt;li&gt;&lt;%= link_to "The Blog", posts_path %&gt;&lt;/li&gt; &lt;li class="dropdown"&gt; &lt;a href="#" class="dropdown-toggle" data-toggle="dropdown"&gt;Registration&lt;b class="caret"&gt;&lt;/b&gt;&lt;/a&gt; &lt;ul class="dropdown-menu"&gt; &lt;% if current_user %&gt; &lt;td&gt;&lt;%= link_to 'Edit Profile', edit_user_path(current_user) %&gt;&lt;/td&gt; &lt;li&gt;&lt;%= link_to "Users", users_path %&gt;&lt;/li&gt; &lt;li&gt;&lt;%= link_to "Log out", logout_path %&gt;&lt;/li&gt; &lt;% else %&gt; &lt;li&gt;&lt;%= link_to 'Sign Up', signup_path %&gt;&lt;/a&gt;&lt;/li&gt; &lt;li&gt;&lt;%= link_to 'Log In', login_path %&gt;&lt;/li&gt; &lt;% end %&gt; &lt;/ul&gt; &lt;/li&gt; &lt;/ul&gt; &lt;/div&gt; &lt;/nav&gt; </code></pre> <p>it works fine if I just click on everything and go through it. I was not using fixtures is that the cause of my problem?</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload