Sha256: 35cb56314097bbb05aefe48ce466241b3ea6898d8f299eac1a01fdad7a6328f1

Contents?: true

Size: 481 Bytes

Versions: 28

Compression:

Stored size: 481 Bytes

Contents

module AdminHelpers
  def sign_in
    visit '/admin/sessions/new'
    fill_in 'Email', with: 'zbigniew.humeniuk@motteq.com'
    fill_in 'Password', with: 'ubersecure!'
    click_button 'Sign In'
  end

  def update_article article
    article.title = 'AGtTRA'
    article.text = 'TESTING_SUPPORT...' * 6
    article.save!
    emit article, :updated, for: [:all]
  end

  def publish_article article
    article.publish
    emit article, :published, data: {id: article.id}
  end
end

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
loco-rails-1.4.0 test/support/admin_helpers.rb
loco-rails-1.3.3 test/support/admin_helpers.rb
loco-rails-1.3.2 test/support/admin_helpers.rb
loco-rails-1.3.1 test/support/admin_helpers.rb
loco-rails-1.3.0 test/support/admin_helpers.rb
loco-rails-1.0.2 test/support/admin_helpers.rb
loco-rails-1.0.1 test/support/admin_helpers.rb
loco-rails-1.0.0 test/support/admin_helpers.rb