Sha256: c88ab6c32a6ff7e3098faebf4ad141e91635d7c92d1c664a7028c0ef364398f4
Contents?: true
Size: 957 Bytes
Versions: 17
Compression:
Stored size: 957 Bytes
Contents
require 'spec_helper' describe 'Tumblr API example', type: :feature, js: true do before do proxy.stub('http://blog.howmanyleft.co.uk/api/read/json').and_return( jsonp: { posts: [ { 'regular-title' => 'News Item 1', 'url-with-slug' => 'http://example.com/news/1', 'regular-body' => 'News item 1 content here' }, { 'regular-title' => 'News Item 2', 'url-with-slug' => 'http://example.com/news/2', 'regular-body' => 'News item 2 content here' } ] }) end it 'should show news stories' do visit '/tumblr_api.html' expect(page).to have_link('News Item 1', href: 'http://example.com/news/1') expect(page).to have_content('News item 1 content here') expect(page).to have_link('News Item 2', href: 'http://example.com/news/2') expect(page).to have_content('News item 2 content here') end end
Version data entries
17 entries across 17 versions & 1 rubygems