Groups are now workgroups. First part of moving groups-logic into admin-namespace.
This commit is contained in:
parent
461dfa8531
commit
2d5dc03b90
31 changed files with 616 additions and 37 deletions
2
test/fixtures/articles.yml
vendored
2
test/fixtures/articles.yml
vendored
|
|
@ -1,5 +1,5 @@
|
|||
# == Schema Information
|
||||
# Schema version: 20090102171850
|
||||
# Schema version: 20090113111624
|
||||
#
|
||||
# Table name: articles
|
||||
#
|
||||
|
|
|
|||
2
test/fixtures/suppliers.yml
vendored
2
test/fixtures/suppliers.yml
vendored
|
|
@ -1,5 +1,5 @@
|
|||
# == Schema Information
|
||||
# Schema version: 20090102171850
|
||||
# Schema version: 20090113111624
|
||||
#
|
||||
# Table name: suppliers
|
||||
#
|
||||
|
|
|
|||
7
test/fixtures/workgroups.yml
vendored
Normal file
7
test/fixtures/workgroups.yml
vendored
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
# Read about fixtures at http://ar.rubyonrails.org/classes/Fixtures.html
|
||||
|
||||
# one:
|
||||
# column: value
|
||||
#
|
||||
# two:
|
||||
# column: value
|
||||
8
test/functional/admin/groups_controller_test.rb
Normal file
8
test/functional/admin/groups_controller_test.rb
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
require 'test_helper'
|
||||
|
||||
class Admin::GroupsControllerTest < ActionController::TestCase
|
||||
# Replace this with your real tests.
|
||||
test "the truth" do
|
||||
assert true
|
||||
end
|
||||
end
|
||||
8
test/functional/admin/memberships_controller_test.rb
Normal file
8
test/functional/admin/memberships_controller_test.rb
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
require 'test_helper'
|
||||
|
||||
class Admin::MembershipsControllerTest < ActionController::TestCase
|
||||
# Replace this with your real tests.
|
||||
test "the truth" do
|
||||
assert true
|
||||
end
|
||||
end
|
||||
45
test/functional/workgroups_controller_test.rb
Normal file
45
test/functional/workgroups_controller_test.rb
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
require 'test_helper'
|
||||
|
||||
class WorkgroupsControllerTest < ActionController::TestCase
|
||||
test "should get index" do
|
||||
get :index
|
||||
assert_response :success
|
||||
assert_not_nil assigns(:workgroups)
|
||||
end
|
||||
|
||||
test "should get new" do
|
||||
get :new
|
||||
assert_response :success
|
||||
end
|
||||
|
||||
test "should create workgroup" do
|
||||
assert_difference('Workgroup.count') do
|
||||
post :create, :workgroup => { }
|
||||
end
|
||||
|
||||
assert_redirected_to workgroup_path(assigns(:workgroup))
|
||||
end
|
||||
|
||||
test "should show workgroup" do
|
||||
get :show, :id => workgroups(:one).id
|
||||
assert_response :success
|
||||
end
|
||||
|
||||
test "should get edit" do
|
||||
get :edit, :id => workgroups(:one).id
|
||||
assert_response :success
|
||||
end
|
||||
|
||||
test "should update workgroup" do
|
||||
put :update, :id => workgroups(:one).id, :workgroup => { }
|
||||
assert_redirected_to workgroup_path(assigns(:workgroup))
|
||||
end
|
||||
|
||||
test "should destroy workgroup" do
|
||||
assert_difference('Workgroup.count', -1) do
|
||||
delete :destroy, :id => workgroups(:one).id
|
||||
end
|
||||
|
||||
assert_redirected_to workgroups_path
|
||||
end
|
||||
end
|
||||
8
test/unit/workgroup_test.rb
Normal file
8
test/unit/workgroup_test.rb
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
require 'test_helper'
|
||||
|
||||
class WorkgroupTest < ActiveSupport::TestCase
|
||||
# Replace this with your real tests.
|
||||
test "the truth" do
|
||||
assert true
|
||||
end
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue