Sha256: 86f42df30e3156a3869d168fbdb889adccccb7dce3ca197e0fa71b24de6376e4

Contents?: true

Size: 972 Bytes

Versions: 13

Compression:

Stored size: 972 Bytes

Contents

require 'test_plugin_helper'
require 'integration_test_helper'

module ForemanSalt
  class SaltEnvironmentTest < ActionDispatch::IntegrationTest
    test 'index page' do
      FactoryGirl.create_list :salt_environment, 5
      assert_index_page(salt_environments_path, 'Salt Environment', 'New Salt Environment')
    end

    test 'create new page' do
      assert_new_button(salt_environments_path, 'New Salt Environment', new_salt_environment_path)
      fill_in 'foreman_salt_salt_environment_name', :with => 'common'
      assert_submit_button(salt_environments_path)
      assert page.has_link? 'common'
    end

    test 'edit page' do
      salt_environment = FactoryGirl.create :salt_environment
      visit salt_environments_path
      click_link salt_environment.name
      fill_in 'foreman_salt_salt_environment_name', :with => 'some_other_name'
      assert_submit_button(salt_environments_path)
      assert page.has_link? 'some_other_name'
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
foreman_salt-8.0.4 test/integration/salt_environment_test.rb
foreman_salt-9.0.1 test/integration/salt_environment_test.rb
foreman_salt-9.0.0 test/integration/salt_environment_test.rb
foreman_salt-8.0.3 test/integration/salt_environment_test.rb
foreman_salt-8.0.2 test/integration/salt_environment_test.rb
foreman_salt-8.0.1 test/integration/salt_environment_test.rb
foreman_salt-7.0.3 test/integration/salt_environment_test.rb
foreman_salt-8.0.0 test/integration/salt_environment_test.rb
foreman_salt-7.0.2 test/integration/salt_environment_test.rb
foreman_salt-6.0.1 test/integration/salt_environment_test.rb
foreman_salt-7.0.1 test/integration/salt_environment_test.rb
foreman_salt-7.0.0 test/integration/salt_environment_test.rb
foreman_salt-6.0.0 test/integration/salt_environment_test.rb