Sha256: e172ea9c65a5d34d0504dec8b8d773520d69e639a9a74eb5bd293a6515c8cd42
Contents?: true
Size: 787 Bytes
Versions: 46
Compression:
Stored size: 787 Bytes
Contents
require File.dirname(__FILE__) + '/../test_helper' class ArticlesTest < ActionDispatch::IntegrationTest def setup login_as_admin! end test 'list articles' do article = Article.create!(title: "Hello World") click_on('Articles') assert_equal 200, page.status_code assert page.assert_selector('a.resource_id_link', text: article.id.to_s) end test 'create article' do click_on('Articles') click_on('New Article') assert_equal('/lalala/articles/new', current_path) first('input[name="article[translations_writer][en][title]"]').set('My Article') click_on('Create Article') page.save_page assert_equal 200, page.status_code assert_equal('/lalala/articles/1', current_path) assert page.has_text?('My Article') end end
Version data entries
46 entries across 46 versions & 1 rubygems