Sha256: bcc5d7b0bbaaf567713cf593f681bb79536d0168eb86b0c390613d2eef8f7e8c

Contents?: true

Size: 720 Bytes

Versions: 22

Compression:

Stored size: 720 Bytes

Contents

# frozen_string_literal: true

require 'test_plugin_helper'
require 'nokogiri'

module ForemanAcd
  # Application Definitions Controller tests
  class AppDefinitionsControllerTest < ActionController::TestCase
    setup do
      as_admin { FactoryBot.create(:app_definition) }
      @model = ForemanAcd::AppDefinition.first
    end

    basic_index_test('app_definitions')
    basic_new_test
    basic_edit_test('app_definition')

    test 'should destroy app definition' do
      assert_difference('AppDefinition.count', -1) do
        delete :destroy,
               :params => { :id => @model.id },
               :session => set_session_user
      end
      assert_redirected_to app_definitions_url
    end
  end
end

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
foreman_acd-0.0.4 test/controllers/app_definitions_controller_test.rb
foreman_acd-0.0.3 test/controllers/app_definitions_controller_test.rb