Sha256: 1a944b8cc6c8a979c250c6bf68b93c60d907628b9e84cba89383bad69c7e0ff5

Contents?: true

Size: 757 Bytes

Versions: 6

Compression:

Stored size: 757 Bytes

Contents

require 'test_plugin_helper'

module ForemanDiscovery
  module Concerns
    class HostsControllerTest < ActionController::TestCase
      tests ::HostsController

      context 'hosts controller requests from discovered_hosts url' do
        test 'get "host" params from "discovered_hosts" params' do
          architecture = FactoryGirl.create(:architecture)
          discovered_host_params = {
            'discovered_host' => { 'architecture_id' => architecture.id }
          }

          @request.stubs(:path).
            returns(architecture_selected_discovered_hosts_path)

          post :architecture_selected, discovered_host_params, set_session_user
          assert assigns('architecture'), architecture
        end
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
foreman_discovery-9.1.5 test/functional/foreman_discovery/concerns/hosts_controller_extensions_test.rb
foreman_discovery-9.1.4 test/functional/foreman_discovery/concerns/hosts_controller_extensions_test.rb
foreman_discovery-9.1.3 test/functional/foreman_discovery/concerns/hosts_controller_extensions_test.rb
foreman_discovery-9.1.2 test/functional/foreman_discovery/concerns/hosts_controller_extensions_test.rb
foreman_discovery-9.1.1 test/functional/foreman_discovery/concerns/hosts_controller_extensions_test.rb
foreman_discovery-9.1.0 test/functional/foreman_discovery/concerns/hosts_controller_extensions_test.rb