server list looks like something

This commit is contained in:
Senad Uka
2016-02-20 12:36:50 +01:00
parent 3b213c855a
commit 91b72481da
25 changed files with 258 additions and 5 deletions

View File

@@ -0,0 +1,49 @@
require 'test_helper'
class OperatingSystemsControllerTest < ActionController::TestCase
setup do
@operating_system = operating_systems(:one)
end
test 'should get index' do
get :index
assert_response :success
assert_not_nil assigns(:operating_systems)
end
test 'should get new' do
get :new
assert_response :success
end
test 'should create operating_system' do
assert_difference('OperatingSystem.count') do
post :create, operating_system: {}
end
assert_redirected_to operating_system_path(assigns(:operating_system))
end
test 'should show operating_system' do
get :show, id: @operating_system
assert_response :success
end
test 'should get edit' do
get :edit, id: @operating_system
assert_response :success
end
test 'should update operating_system' do
patch :update, id: @operating_system, operating_system: {}
assert_redirected_to operating_system_path(assigns(:operating_system))
end
test 'should destroy operating_system' do
assert_difference('OperatingSystem.count', -1) do
delete :destroy, id: @operating_system
end
assert_redirected_to operating_systems_path
end
end