Twitter search method undefined

Hi Folks, I’m working through the “Interacting with 3rd party service” video around the 19 minute mark.

When I run the following test:

 feature 'search twitter for a term' do
  scenario 'searching by a hashtag' do
    visit root_path
    fill_in 'Search', with: 'Rails'
    click_button 'Search'
    expect(page).to have_css 'li.tweet', count: 15
  end
end

I’m getting the following error:

Failures:

  1) search twitter for a term searching by a hashtag
     Failure/Error: click_button 'Search'
     NoMethodError:
       undefined method `search' for Twitter:Module

Any idea what the problem might be? I’m a bit stuck.
Thanks, Mark

Someone? Anyone? :smile: