From 94a5654371812905c154f29cef393d42f13c5eaa Mon Sep 17 00:00:00 2001 From: AndrewMurrell Date: Tue, 18 Feb 2014 18:16:28 -0500 Subject: Added the generate shell command. Please do not commit the generated files. --- test/controllers/matches_controller_test.rb | 49 +++++++++++++++++++++++++ test/controllers/servers_controller_test.rb | 49 +++++++++++++++++++++++++ test/controllers/teams_controller_test.rb | 49 +++++++++++++++++++++++++ test/controllers/tournaments_controller_test.rb | 49 +++++++++++++++++++++++++ test/controllers/users_controller_test.rb | 49 +++++++++++++++++++++++++ test/fixtures/matches.yml | 11 ++++++ test/fixtures/servers.yml | 11 ++++++ test/fixtures/teams.yml | 11 ++++++ test/fixtures/tournaments.yml | 11 ++++++ test/fixtures/users.yml | 11 ++++++ test/helpers/matches_helper_test.rb | 4 ++ test/helpers/servers_helper_test.rb | 4 ++ test/helpers/teams_helper_test.rb | 4 ++ test/helpers/tournaments_helper_test.rb | 4 ++ test/helpers/users_helper_test.rb | 4 ++ test/models/match_test.rb | 7 ++++ test/models/server_test.rb | 7 ++++ test/models/team_test.rb | 7 ++++ test/models/tournament_test.rb | 7 ++++ test/models/user_test.rb | 7 ++++ 20 files changed, 355 insertions(+) create mode 100644 test/controllers/matches_controller_test.rb create mode 100644 test/controllers/servers_controller_test.rb create mode 100644 test/controllers/teams_controller_test.rb create mode 100644 test/controllers/tournaments_controller_test.rb create mode 100644 test/controllers/users_controller_test.rb create mode 100644 test/fixtures/matches.yml create mode 100644 test/fixtures/servers.yml create mode 100644 test/fixtures/teams.yml create mode 100644 test/fixtures/tournaments.yml create mode 100644 test/fixtures/users.yml create mode 100644 test/helpers/matches_helper_test.rb create mode 100644 test/helpers/servers_helper_test.rb create mode 100644 test/helpers/teams_helper_test.rb create mode 100644 test/helpers/tournaments_helper_test.rb create mode 100644 test/helpers/users_helper_test.rb create mode 100644 test/models/match_test.rb create mode 100644 test/models/server_test.rb create mode 100644 test/models/team_test.rb create mode 100644 test/models/tournament_test.rb create mode 100644 test/models/user_test.rb (limited to 'test') diff --git a/test/controllers/matches_controller_test.rb b/test/controllers/matches_controller_test.rb new file mode 100644 index 0000000..353ff4b --- /dev/null +++ b/test/controllers/matches_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class MatchesControllerTest < ActionController::TestCase + setup do + @match = matches(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:matches) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create match" do + assert_difference('Match.count') do + post :create, match: { } + end + + assert_redirected_to match_path(assigns(:match)) + end + + test "should show match" do + get :show, id: @match + assert_response :success + end + + test "should get edit" do + get :edit, id: @match + assert_response :success + end + + test "should update match" do + patch :update, id: @match, match: { } + assert_redirected_to match_path(assigns(:match)) + end + + test "should destroy match" do + assert_difference('Match.count', -1) do + delete :destroy, id: @match + end + + assert_redirected_to matches_path + end +end diff --git a/test/controllers/servers_controller_test.rb b/test/controllers/servers_controller_test.rb new file mode 100644 index 0000000..5891bb0 --- /dev/null +++ b/test/controllers/servers_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class ServersControllerTest < ActionController::TestCase + setup do + @server = servers(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:servers) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create server" do + assert_difference('Server.count') do + post :create, server: { } + end + + assert_redirected_to server_path(assigns(:server)) + end + + test "should show server" do + get :show, id: @server + assert_response :success + end + + test "should get edit" do + get :edit, id: @server + assert_response :success + end + + test "should update server" do + patch :update, id: @server, server: { } + assert_redirected_to server_path(assigns(:server)) + end + + test "should destroy server" do + assert_difference('Server.count', -1) do + delete :destroy, id: @server + end + + assert_redirected_to servers_path + end +end diff --git a/test/controllers/teams_controller_test.rb b/test/controllers/teams_controller_test.rb new file mode 100644 index 0000000..8bf60be --- /dev/null +++ b/test/controllers/teams_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class TeamsControllerTest < ActionController::TestCase + setup do + @team = teams(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:teams) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create team" do + assert_difference('Team.count') do + post :create, team: { } + end + + assert_redirected_to team_path(assigns(:team)) + end + + test "should show team" do + get :show, id: @team + assert_response :success + end + + test "should get edit" do + get :edit, id: @team + assert_response :success + end + + test "should update team" do + patch :update, id: @team, team: { } + assert_redirected_to team_path(assigns(:team)) + end + + test "should destroy team" do + assert_difference('Team.count', -1) do + delete :destroy, id: @team + end + + assert_redirected_to teams_path + end +end diff --git a/test/controllers/tournaments_controller_test.rb b/test/controllers/tournaments_controller_test.rb new file mode 100644 index 0000000..9363bdf --- /dev/null +++ b/test/controllers/tournaments_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class TournamentsControllerTest < ActionController::TestCase + setup do + @tournament = tournaments(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:tournaments) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create tournament" do + assert_difference('Tournament.count') do + post :create, tournament: { } + end + + assert_redirected_to tournament_path(assigns(:tournament)) + end + + test "should show tournament" do + get :show, id: @tournament + assert_response :success + end + + test "should get edit" do + get :edit, id: @tournament + assert_response :success + end + + test "should update tournament" do + patch :update, id: @tournament, tournament: { } + assert_redirected_to tournament_path(assigns(:tournament)) + end + + test "should destroy tournament" do + assert_difference('Tournament.count', -1) do + delete :destroy, id: @tournament + end + + assert_redirected_to tournaments_path + end +end diff --git a/test/controllers/users_controller_test.rb b/test/controllers/users_controller_test.rb new file mode 100644 index 0000000..846e74c --- /dev/null +++ b/test/controllers/users_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class UsersControllerTest < ActionController::TestCase + setup do + @user = users(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:users) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create user" do + assert_difference('User.count') do + post :create, user: { } + end + + assert_redirected_to user_path(assigns(:user)) + end + + test "should show user" do + get :show, id: @user + assert_response :success + end + + test "should get edit" do + get :edit, id: @user + assert_response :success + end + + test "should update user" do + patch :update, id: @user, user: { } + assert_redirected_to user_path(assigns(:user)) + end + + test "should destroy user" do + assert_difference('User.count', -1) do + delete :destroy, id: @user + end + + assert_redirected_to users_path + end +end diff --git a/test/fixtures/matches.yml b/test/fixtures/matches.yml new file mode 100644 index 0000000..937a0c0 --- /dev/null +++ b/test/fixtures/matches.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +# This model initially had no columns defined. If you add columns to the +# model remove the '{}' from the fixture names and add the columns immediately +# below each fixture, per the syntax in the comments below +# +one: {} +# column: value +# +two: {} +# column: value diff --git a/test/fixtures/servers.yml b/test/fixtures/servers.yml new file mode 100644 index 0000000..937a0c0 --- /dev/null +++ b/test/fixtures/servers.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +# This model initially had no columns defined. If you add columns to the +# model remove the '{}' from the fixture names and add the columns immediately +# below each fixture, per the syntax in the comments below +# +one: {} +# column: value +# +two: {} +# column: value diff --git a/test/fixtures/teams.yml b/test/fixtures/teams.yml new file mode 100644 index 0000000..937a0c0 --- /dev/null +++ b/test/fixtures/teams.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +# This model initially had no columns defined. If you add columns to the +# model remove the '{}' from the fixture names and add the columns immediately +# below each fixture, per the syntax in the comments below +# +one: {} +# column: value +# +two: {} +# column: value diff --git a/test/fixtures/tournaments.yml b/test/fixtures/tournaments.yml new file mode 100644 index 0000000..937a0c0 --- /dev/null +++ b/test/fixtures/tournaments.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +# This model initially had no columns defined. If you add columns to the +# model remove the '{}' from the fixture names and add the columns immediately +# below each fixture, per the syntax in the comments below +# +one: {} +# column: value +# +two: {} +# column: value diff --git a/test/fixtures/users.yml b/test/fixtures/users.yml new file mode 100644 index 0000000..937a0c0 --- /dev/null +++ b/test/fixtures/users.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +# This model initially had no columns defined. If you add columns to the +# model remove the '{}' from the fixture names and add the columns immediately +# below each fixture, per the syntax in the comments below +# +one: {} +# column: value +# +two: {} +# column: value diff --git a/test/helpers/matches_helper_test.rb b/test/helpers/matches_helper_test.rb new file mode 100644 index 0000000..4cc472f --- /dev/null +++ b/test/helpers/matches_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class MatchesHelperTest < ActionView::TestCase +end diff --git a/test/helpers/servers_helper_test.rb b/test/helpers/servers_helper_test.rb new file mode 100644 index 0000000..8fddf34 --- /dev/null +++ b/test/helpers/servers_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class ServersHelperTest < ActionView::TestCase +end diff --git a/test/helpers/teams_helper_test.rb b/test/helpers/teams_helper_test.rb new file mode 100644 index 0000000..b736483 --- /dev/null +++ b/test/helpers/teams_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class TeamsHelperTest < ActionView::TestCase +end diff --git a/test/helpers/tournaments_helper_test.rb b/test/helpers/tournaments_helper_test.rb new file mode 100644 index 0000000..1cf5269 --- /dev/null +++ b/test/helpers/tournaments_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class TournamentsHelperTest < ActionView::TestCase +end diff --git a/test/helpers/users_helper_test.rb b/test/helpers/users_helper_test.rb new file mode 100644 index 0000000..96af37a --- /dev/null +++ b/test/helpers/users_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class UsersHelperTest < ActionView::TestCase +end diff --git a/test/models/match_test.rb b/test/models/match_test.rb new file mode 100644 index 0000000..14436b1 --- /dev/null +++ b/test/models/match_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class MatchTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/server_test.rb b/test/models/server_test.rb new file mode 100644 index 0000000..125ffc9 --- /dev/null +++ b/test/models/server_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class ServerTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/team_test.rb b/test/models/team_test.rb new file mode 100644 index 0000000..8b101cb --- /dev/null +++ b/test/models/team_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class TeamTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/tournament_test.rb b/test/models/tournament_test.rb new file mode 100644 index 0000000..24a7e5f --- /dev/null +++ b/test/models/tournament_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class TournamentTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/user_test.rb b/test/models/user_test.rb new file mode 100644 index 0000000..82f61e0 --- /dev/null +++ b/test/models/user_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class UserTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end -- cgit v1.2.3-2-g168b From 96b97d691f6889004c38bef15411bc27e448fda1 Mon Sep 17 00:00:00 2001 From: AndrewMurrell Date: Tue, 18 Feb 2014 20:42:51 -0500 Subject: Changes to generate.sh --- test/controllers/alerts_controller_test.rb | 49 +++++++++++++++++++++++++++++ test/controllers/main_controller_test.rb | 7 +++++ test/controllers/matches_controller_test.rb | 4 +-- test/controllers/pms_controller_test.rb | 49 +++++++++++++++++++++++++++++ test/controllers/search_controller_test.rb | 7 +++++ test/controllers/users_controller_test.rb | 4 +-- test/fixtures/alerts.yml | 9 ++++++ test/fixtures/matches.yml | 14 +++------ test/fixtures/pms.yml | 11 +++++++ test/fixtures/server_settings.yml | 11 +++++++ test/fixtures/team_match_pairs.yml | 9 ++++++ test/fixtures/user_team_pairs.yml | 9 ++++++ test/fixtures/users.yml | 18 +++++------ test/helpers/alerts_helper_test.rb | 4 +++ test/helpers/main_helper_test.rb | 4 +++ test/helpers/pms_helper_test.rb | 4 +++ test/helpers/search_helper_test.rb | 4 +++ test/models/alert_test.rb | 7 +++++ test/models/pm_test.rb | 7 +++++ test/models/server_settings_test.rb | 7 +++++ test/models/team_match_pair_test.rb | 7 +++++ test/models/user_team_pair_test.rb | 7 +++++ 22 files changed, 230 insertions(+), 22 deletions(-) create mode 100644 test/controllers/alerts_controller_test.rb create mode 100644 test/controllers/main_controller_test.rb create mode 100644 test/controllers/pms_controller_test.rb create mode 100644 test/controllers/search_controller_test.rb create mode 100644 test/fixtures/alerts.yml create mode 100644 test/fixtures/pms.yml create mode 100644 test/fixtures/server_settings.yml create mode 100644 test/fixtures/team_match_pairs.yml create mode 100644 test/fixtures/user_team_pairs.yml create mode 100644 test/helpers/alerts_helper_test.rb create mode 100644 test/helpers/main_helper_test.rb create mode 100644 test/helpers/pms_helper_test.rb create mode 100644 test/helpers/search_helper_test.rb create mode 100644 test/models/alert_test.rb create mode 100644 test/models/pm_test.rb create mode 100644 test/models/server_settings_test.rb create mode 100644 test/models/team_match_pair_test.rb create mode 100644 test/models/user_team_pair_test.rb (limited to 'test') diff --git a/test/controllers/alerts_controller_test.rb b/test/controllers/alerts_controller_test.rb new file mode 100644 index 0000000..29e58e9 --- /dev/null +++ b/test/controllers/alerts_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class AlertsControllerTest < ActionController::TestCase + setup do + @alert = alerts(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:alerts) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create alert" do + assert_difference('Alert.count') do + post :create, alert: { author: @alert.author, message: @alert.message } + end + + assert_redirected_to alert_path(assigns(:alert)) + end + + test "should show alert" do + get :show, id: @alert + assert_response :success + end + + test "should get edit" do + get :edit, id: @alert + assert_response :success + end + + test "should update alert" do + patch :update, id: @alert, alert: { author: @alert.author, message: @alert.message } + assert_redirected_to alert_path(assigns(:alert)) + end + + test "should destroy alert" do + assert_difference('Alert.count', -1) do + delete :destroy, id: @alert + end + + assert_redirected_to alerts_path + end +end diff --git a/test/controllers/main_controller_test.rb b/test/controllers/main_controller_test.rb new file mode 100644 index 0000000..b7ec6bf --- /dev/null +++ b/test/controllers/main_controller_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class MainControllerTest < ActionController::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/controllers/matches_controller_test.rb b/test/controllers/matches_controller_test.rb index 353ff4b..629622b 100644 --- a/test/controllers/matches_controller_test.rb +++ b/test/controllers/matches_controller_test.rb @@ -18,7 +18,7 @@ class MatchesControllerTest < ActionController::TestCase test "should create match" do assert_difference('Match.count') do - post :create, match: { } + post :create, match: { tournament: @match.tournament } end assert_redirected_to match_path(assigns(:match)) @@ -35,7 +35,7 @@ class MatchesControllerTest < ActionController::TestCase end test "should update match" do - patch :update, id: @match, match: { } + patch :update, id: @match, match: { tournament: @match.tournament } assert_redirected_to match_path(assigns(:match)) end diff --git a/test/controllers/pms_controller_test.rb b/test/controllers/pms_controller_test.rb new file mode 100644 index 0000000..ccbe7b1 --- /dev/null +++ b/test/controllers/pms_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class PmsControllerTest < ActionController::TestCase + setup do + @pm = pms(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:pms) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create pm" do + assert_difference('Pm.count') do + post :create, pm: { author: @pm.author, message: @pm.message, recipient: @pm.recipient } + end + + assert_redirected_to pm_path(assigns(:pm)) + end + + test "should show pm" do + get :show, id: @pm + assert_response :success + end + + test "should get edit" do + get :edit, id: @pm + assert_response :success + end + + test "should update pm" do + patch :update, id: @pm, pm: { author: @pm.author, message: @pm.message, recipient: @pm.recipient } + assert_redirected_to pm_path(assigns(:pm)) + end + + test "should destroy pm" do + assert_difference('Pm.count', -1) do + delete :destroy, id: @pm + end + + assert_redirected_to pms_path + end +end diff --git a/test/controllers/search_controller_test.rb b/test/controllers/search_controller_test.rb new file mode 100644 index 0000000..bfbf22d --- /dev/null +++ b/test/controllers/search_controller_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class SearchControllerTest < ActionController::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/controllers/users_controller_test.rb b/test/controllers/users_controller_test.rb index 846e74c..8bcd10b 100644 --- a/test/controllers/users_controller_test.rb +++ b/test/controllers/users_controller_test.rb @@ -18,7 +18,7 @@ class UsersControllerTest < ActionController::TestCase test "should create user" do assert_difference('User.count') do - post :create, user: { } + post :create, user: { groups: @user.groups, name: @user.name, pw_hash: @user.pw_hash } end assert_redirected_to user_path(assigns(:user)) @@ -35,7 +35,7 @@ class UsersControllerTest < ActionController::TestCase end test "should update user" do - patch :update, id: @user, user: { } + patch :update, id: @user, user: { groups: @user.groups, name: @user.name, pw_hash: @user.pw_hash } assert_redirected_to user_path(assigns(:user)) end diff --git a/test/fixtures/alerts.yml b/test/fixtures/alerts.yml new file mode 100644 index 0000000..92ee1b0 --- /dev/null +++ b/test/fixtures/alerts.yml @@ -0,0 +1,9 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + author: + message: MyText + +two: + author: + message: MyText diff --git a/test/fixtures/matches.yml b/test/fixtures/matches.yml index 937a0c0..48c08a5 100644 --- a/test/fixtures/matches.yml +++ b/test/fixtures/matches.yml @@ -1,11 +1,7 @@ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html -# This model initially had no columns defined. If you add columns to the -# model remove the '{}' from the fixture names and add the columns immediately -# below each fixture, per the syntax in the comments below -# -one: {} -# column: value -# -two: {} -# column: value +one: + tournament: + +two: + tournament: diff --git a/test/fixtures/pms.yml b/test/fixtures/pms.yml new file mode 100644 index 0000000..4ad9af3 --- /dev/null +++ b/test/fixtures/pms.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + author: + recipient: + message: MyText + +two: + author: + recipient: + message: MyText diff --git a/test/fixtures/server_settings.yml b/test/fixtures/server_settings.yml new file mode 100644 index 0000000..937a0c0 --- /dev/null +++ b/test/fixtures/server_settings.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +# This model initially had no columns defined. If you add columns to the +# model remove the '{}' from the fixture names and add the columns immediately +# below each fixture, per the syntax in the comments below +# +one: {} +# column: value +# +two: {} +# column: value diff --git a/test/fixtures/team_match_pairs.yml b/test/fixtures/team_match_pairs.yml new file mode 100644 index 0000000..1a81ab4 --- /dev/null +++ b/test/fixtures/team_match_pairs.yml @@ -0,0 +1,9 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + team: + match: + +two: + team: + match: diff --git a/test/fixtures/user_team_pairs.yml b/test/fixtures/user_team_pairs.yml new file mode 100644 index 0000000..bda8bd3 --- /dev/null +++ b/test/fixtures/user_team_pairs.yml @@ -0,0 +1,9 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + user: + team: + +two: + user: + team: diff --git a/test/fixtures/users.yml b/test/fixtures/users.yml index 937a0c0..02ffdbb 100644 --- a/test/fixtures/users.yml +++ b/test/fixtures/users.yml @@ -1,11 +1,11 @@ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html -# This model initially had no columns defined. If you add columns to the -# model remove the '{}' from the fixture names and add the columns immediately -# below each fixture, per the syntax in the comments below -# -one: {} -# column: value -# -two: {} -# column: value +one: + name: MyText + pw_hash: + groups: + +two: + name: MyText + pw_hash: + groups: diff --git a/test/helpers/alerts_helper_test.rb b/test/helpers/alerts_helper_test.rb new file mode 100644 index 0000000..1d9079d --- /dev/null +++ b/test/helpers/alerts_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class AlertsHelperTest < ActionView::TestCase +end diff --git a/test/helpers/main_helper_test.rb b/test/helpers/main_helper_test.rb new file mode 100644 index 0000000..22da3c4 --- /dev/null +++ b/test/helpers/main_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class MainHelperTest < ActionView::TestCase +end diff --git a/test/helpers/pms_helper_test.rb b/test/helpers/pms_helper_test.rb new file mode 100644 index 0000000..af80f10 --- /dev/null +++ b/test/helpers/pms_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class PmsHelperTest < ActionView::TestCase +end diff --git a/test/helpers/search_helper_test.rb b/test/helpers/search_helper_test.rb new file mode 100644 index 0000000..3034163 --- /dev/null +++ b/test/helpers/search_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class SearchHelperTest < ActionView::TestCase +end diff --git a/test/models/alert_test.rb b/test/models/alert_test.rb new file mode 100644 index 0000000..b59c65e --- /dev/null +++ b/test/models/alert_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class AlertTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/pm_test.rb b/test/models/pm_test.rb new file mode 100644 index 0000000..e7f6b8f --- /dev/null +++ b/test/models/pm_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class PmTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/server_settings_test.rb b/test/models/server_settings_test.rb new file mode 100644 index 0000000..470b316 --- /dev/null +++ b/test/models/server_settings_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class ServerSettingsTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/team_match_pair_test.rb b/test/models/team_match_pair_test.rb new file mode 100644 index 0000000..c250b3c --- /dev/null +++ b/test/models/team_match_pair_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class TeamMatchPairTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/user_team_pair_test.rb b/test/models/user_team_pair_test.rb new file mode 100644 index 0000000..55f5c58 --- /dev/null +++ b/test/models/user_team_pair_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class UserTeamPairTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end -- cgit v1.2.3-2-g168b From cd1fabe40ca4d290df33a2590f3a1f2072103972 Mon Sep 17 00:00:00 2001 From: DavisLWebb Date: Thu, 20 Feb 2014 17:13:51 -0500 Subject: fix datatype names in generate.sh --- test/controllers/alerts_controller_test.rb | 4 ++-- test/controllers/matches_controller_test.rb | 4 ++-- test/controllers/pms_controller_test.rb | 4 ++-- test/fixtures/alerts.yml | 4 ++-- test/fixtures/matches.yml | 4 ++-- test/fixtures/pms.yml | 8 ++++---- test/fixtures/team_match_pairs.yml | 8 ++++---- test/fixtures/user_team_pairs.yml | 8 ++++---- test/fixtures/users.yml | 8 ++++---- 9 files changed, 26 insertions(+), 26 deletions(-) (limited to 'test') diff --git a/test/controllers/alerts_controller_test.rb b/test/controllers/alerts_controller_test.rb index 29e58e9..4a5d911 100644 --- a/test/controllers/alerts_controller_test.rb +++ b/test/controllers/alerts_controller_test.rb @@ -18,7 +18,7 @@ class AlertsControllerTest < ActionController::TestCase test "should create alert" do assert_difference('Alert.count') do - post :create, alert: { author: @alert.author, message: @alert.message } + post :create, alert: { author_id: @alert.author_id, message: @alert.message } end assert_redirected_to alert_path(assigns(:alert)) @@ -35,7 +35,7 @@ class AlertsControllerTest < ActionController::TestCase end test "should update alert" do - patch :update, id: @alert, alert: { author: @alert.author, message: @alert.message } + patch :update, id: @alert, alert: { author_id: @alert.author_id, message: @alert.message } assert_redirected_to alert_path(assigns(:alert)) end diff --git a/test/controllers/matches_controller_test.rb b/test/controllers/matches_controller_test.rb index 629622b..75c9dcf 100644 --- a/test/controllers/matches_controller_test.rb +++ b/test/controllers/matches_controller_test.rb @@ -18,7 +18,7 @@ class MatchesControllerTest < ActionController::TestCase test "should create match" do assert_difference('Match.count') do - post :create, match: { tournament: @match.tournament } + post :create, match: { tournament_id: @match.tournament_id } end assert_redirected_to match_path(assigns(:match)) @@ -35,7 +35,7 @@ class MatchesControllerTest < ActionController::TestCase end test "should update match" do - patch :update, id: @match, match: { tournament: @match.tournament } + patch :update, id: @match, match: { tournament_id: @match.tournament_id } assert_redirected_to match_path(assigns(:match)) end diff --git a/test/controllers/pms_controller_test.rb b/test/controllers/pms_controller_test.rb index ccbe7b1..18b2449 100644 --- a/test/controllers/pms_controller_test.rb +++ b/test/controllers/pms_controller_test.rb @@ -18,7 +18,7 @@ class PmsControllerTest < ActionController::TestCase test "should create pm" do assert_difference('Pm.count') do - post :create, pm: { author: @pm.author, message: @pm.message, recipient: @pm.recipient } + post :create, pm: { author_id: @pm.author_id, message: @pm.message, recipient_id: @pm.recipient_id } end assert_redirected_to pm_path(assigns(:pm)) @@ -35,7 +35,7 @@ class PmsControllerTest < ActionController::TestCase end test "should update pm" do - patch :update, id: @pm, pm: { author: @pm.author, message: @pm.message, recipient: @pm.recipient } + patch :update, id: @pm, pm: { author_id: @pm.author_id, message: @pm.message, recipient_id: @pm.recipient_id } assert_redirected_to pm_path(assigns(:pm)) end diff --git a/test/fixtures/alerts.yml b/test/fixtures/alerts.yml index 92ee1b0..52959af 100644 --- a/test/fixtures/alerts.yml +++ b/test/fixtures/alerts.yml @@ -1,9 +1,9 @@ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html one: - author: + author_id: message: MyText two: - author: + author_id: message: MyText diff --git a/test/fixtures/matches.yml b/test/fixtures/matches.yml index 48c08a5..0356cee 100644 --- a/test/fixtures/matches.yml +++ b/test/fixtures/matches.yml @@ -1,7 +1,7 @@ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html one: - tournament: + tournament_id: two: - tournament: + tournament_id: diff --git a/test/fixtures/pms.yml b/test/fixtures/pms.yml index 4ad9af3..f77e727 100644 --- a/test/fixtures/pms.yml +++ b/test/fixtures/pms.yml @@ -1,11 +1,11 @@ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html one: - author: - recipient: + author_id: + recipient_id: message: MyText two: - author: - recipient: + author_id: + recipient_id: message: MyText diff --git a/test/fixtures/team_match_pairs.yml b/test/fixtures/team_match_pairs.yml index 1a81ab4..5f9cf2f 100644 --- a/test/fixtures/team_match_pairs.yml +++ b/test/fixtures/team_match_pairs.yml @@ -1,9 +1,9 @@ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html one: - team: - match: + team_id: + match_id: two: - team: - match: + team_id: + match_id: diff --git a/test/fixtures/user_team_pairs.yml b/test/fixtures/user_team_pairs.yml index bda8bd3..a76036f 100644 --- a/test/fixtures/user_team_pairs.yml +++ b/test/fixtures/user_team_pairs.yml @@ -1,9 +1,9 @@ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html one: - user: - team: + user_id: + team_id: two: - user: - team: + user_id: + team_id: diff --git a/test/fixtures/users.yml b/test/fixtures/users.yml index 02ffdbb..9f593bc 100644 --- a/test/fixtures/users.yml +++ b/test/fixtures/users.yml @@ -2,10 +2,10 @@ one: name: MyText - pw_hash: - groups: + pw_hash: MyText + groups: 1 two: name: MyText - pw_hash: - groups: + pw_hash: MyText + groups: 1 -- cgit v1.2.3-2-g168b From 8e3e88f52c1f2d73acdcb7fdf60326b5f7717068 Mon Sep 17 00:00:00 2001 From: AndrewMurrell Date: Wed, 26 Feb 2014 20:07:42 -0500 Subject: Possibly broke everything. Added another model for populating tournament options. --- test/fixtures/tournament_options.yml | 11 +++++++++++ test/models/tournament_options_test.rb | 7 +++++++ 2 files changed, 18 insertions(+) create mode 100644 test/fixtures/tournament_options.yml create mode 100644 test/models/tournament_options_test.rb (limited to 'test') diff --git a/test/fixtures/tournament_options.yml b/test/fixtures/tournament_options.yml new file mode 100644 index 0000000..937a0c0 --- /dev/null +++ b/test/fixtures/tournament_options.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +# This model initially had no columns defined. If you add columns to the +# model remove the '{}' from the fixture names and add the columns immediately +# below each fixture, per the syntax in the comments below +# +one: {} +# column: value +# +two: {} +# column: value diff --git a/test/models/tournament_options_test.rb b/test/models/tournament_options_test.rb new file mode 100644 index 0000000..7677fae --- /dev/null +++ b/test/models/tournament_options_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class TournamentOptionsTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end -- cgit v1.2.3-2-g168b From 3a7b14f4a51c0fdb8b71720f361a0a8ccf080325 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Thu, 27 Feb 2014 16:59:04 -0500 Subject: add game types --- test/controllers/games_controller_test.rb | 49 +++++++++++++++++++++++++++++++ test/fixtures/game_attributes.yml | 11 +++++++ test/fixtures/games.yml | 7 +++++ test/helpers/games_helper_test.rb | 4 +++ test/models/game_attribute_test.rb | 7 +++++ test/models/game_test.rb | 7 +++++ 6 files changed, 85 insertions(+) create mode 100644 test/controllers/games_controller_test.rb create mode 100644 test/fixtures/game_attributes.yml create mode 100644 test/fixtures/games.yml create mode 100644 test/helpers/games_helper_test.rb create mode 100644 test/models/game_attribute_test.rb create mode 100644 test/models/game_test.rb (limited to 'test') diff --git a/test/controllers/games_controller_test.rb b/test/controllers/games_controller_test.rb new file mode 100644 index 0000000..420758e --- /dev/null +++ b/test/controllers/games_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class GamesControllerTest < ActionController::TestCase + setup do + @game = games(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:games) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create game" do + assert_difference('Game.count') do + post :create, game: { name: @game.name } + end + + assert_redirected_to game_path(assigns(:game)) + end + + test "should show game" do + get :show, id: @game + assert_response :success + end + + test "should get edit" do + get :edit, id: @game + assert_response :success + end + + test "should update game" do + patch :update, id: @game, game: { name: @game.name } + assert_redirected_to game_path(assigns(:game)) + end + + test "should destroy game" do + assert_difference('Game.count', -1) do + delete :destroy, id: @game + end + + assert_redirected_to games_path + end +end diff --git a/test/fixtures/game_attributes.yml b/test/fixtures/game_attributes.yml new file mode 100644 index 0000000..eff7212 --- /dev/null +++ b/test/fixtures/game_attributes.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + game_id: + key: MyText + type: 1 + +two: + game_id: + key: MyText + type: 1 diff --git a/test/fixtures/games.yml b/test/fixtures/games.yml new file mode 100644 index 0000000..ce6f466 --- /dev/null +++ b/test/fixtures/games.yml @@ -0,0 +1,7 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + name: MyText + +two: + name: MyText diff --git a/test/helpers/games_helper_test.rb b/test/helpers/games_helper_test.rb new file mode 100644 index 0000000..449a85c --- /dev/null +++ b/test/helpers/games_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class GamesHelperTest < ActionView::TestCase +end diff --git a/test/models/game_attribute_test.rb b/test/models/game_attribute_test.rb new file mode 100644 index 0000000..13c6e65 --- /dev/null +++ b/test/models/game_attribute_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class GameAttributeTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/game_test.rb b/test/models/game_test.rb new file mode 100644 index 0000000..2cab36e --- /dev/null +++ b/test/models/game_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class GameTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end -- cgit v1.2.3-2-g168b From de40ec53e8b80d8d880214183f19ea93172a0026 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Thu, 27 Feb 2014 17:02:10 -0500 Subject: give tournaments a game type --- test/controllers/tournaments_controller_test.rb | 4 ++-- test/fixtures/tournaments.yml | 14 +++++--------- 2 files changed, 7 insertions(+), 11 deletions(-) (limited to 'test') diff --git a/test/controllers/tournaments_controller_test.rb b/test/controllers/tournaments_controller_test.rb index 9363bdf..bdbbfac 100644 --- a/test/controllers/tournaments_controller_test.rb +++ b/test/controllers/tournaments_controller_test.rb @@ -18,7 +18,7 @@ class TournamentsControllerTest < ActionController::TestCase test "should create tournament" do assert_difference('Tournament.count') do - post :create, tournament: { } + post :create, tournament: { game_id: @tournament.game_id } end assert_redirected_to tournament_path(assigns(:tournament)) @@ -35,7 +35,7 @@ class TournamentsControllerTest < ActionController::TestCase end test "should update tournament" do - patch :update, id: @tournament, tournament: { } + patch :update, id: @tournament, tournament: { game_id: @tournament.game_id } assert_redirected_to tournament_path(assigns(:tournament)) end diff --git a/test/fixtures/tournaments.yml b/test/fixtures/tournaments.yml index 937a0c0..4cba7ca 100644 --- a/test/fixtures/tournaments.yml +++ b/test/fixtures/tournaments.yml @@ -1,11 +1,7 @@ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html -# This model initially had no columns defined. If you add columns to the -# model remove the '{}' from the fixture names and add the columns immediately -# below each fixture, per the syntax in the comments below -# -one: {} -# column: value -# -two: {} -# column: value +one: + game_id: + +two: + game_id: -- cgit v1.2.3-2-g168b From f3f17dcd9755020276062caae7c0677eff88cb2f Mon Sep 17 00:00:00 2001 From: AndrewMurrell Date: Thu, 27 Feb 2014 17:41:59 -0500 Subject: Added the Games Attributes stuff. --- test/controllers/games_controller_test.rb | 4 ++-- test/fixtures/games.yml | 8 ++++++++ 2 files changed, 10 insertions(+), 2 deletions(-) (limited to 'test') diff --git a/test/controllers/games_controller_test.rb b/test/controllers/games_controller_test.rb index 420758e..95c3145 100644 --- a/test/controllers/games_controller_test.rb +++ b/test/controllers/games_controller_test.rb @@ -18,7 +18,7 @@ class GamesControllerTest < ActionController::TestCase test "should create game" do assert_difference('Game.count') do - post :create, game: { name: @game.name } + post :create, game: { name: @game.name, players_per_team: @game.players_per_team, randomized_teams: @game.randomized_teams, set_rounds: @game.set_rounds, teams_per_match: @game.teams_per_match } end assert_redirected_to game_path(assigns(:game)) @@ -35,7 +35,7 @@ class GamesControllerTest < ActionController::TestCase end test "should update game" do - patch :update, id: @game, game: { name: @game.name } + patch :update, id: @game, game: { name: @game.name, players_per_team: @game.players_per_team, randomized_teams: @game.randomized_teams, set_rounds: @game.set_rounds, teams_per_match: @game.teams_per_match } assert_redirected_to game_path(assigns(:game)) end diff --git a/test/fixtures/games.yml b/test/fixtures/games.yml index ce6f466..3068527 100644 --- a/test/fixtures/games.yml +++ b/test/fixtures/games.yml @@ -2,6 +2,14 @@ one: name: MyText + players_per_team: 1 + teams_per_match: 1 + set_rounds: 1 + randomized_teams: 1 two: name: MyText + players_per_team: 1 + teams_per_match: 1 + set_rounds: 1 + randomized_teams: 1 -- cgit v1.2.3-2-g168b From 2eb242f3e5b1f1ab66d84556cabcad965fe387aa Mon Sep 17 00:00:00 2001 From: DavisLWebb Date: Sat, 1 Mar 2014 20:23:29 -0500 Subject: changed the user section of the generate --- test/controllers/users_controller_test.rb | 48 ++----------------------------- test/fixtures/users.yml | 12 ++++---- test/models/tournament_option_test.rb | 7 +++++ test/models/tournament_options_test.rb | 7 ----- 4 files changed, 16 insertions(+), 58 deletions(-) create mode 100644 test/models/tournament_option_test.rb delete mode 100644 test/models/tournament_options_test.rb (limited to 'test') diff --git a/test/controllers/users_controller_test.rb b/test/controllers/users_controller_test.rb index 8bcd10b..d23f182 100644 --- a/test/controllers/users_controller_test.rb +++ b/test/controllers/users_controller_test.rb @@ -1,49 +1,7 @@ require 'test_helper' class UsersControllerTest < ActionController::TestCase - setup do - @user = users(:one) - end - - test "should get index" do - get :index - assert_response :success - assert_not_nil assigns(:users) - end - - test "should get new" do - get :new - assert_response :success - end - - test "should create user" do - assert_difference('User.count') do - post :create, user: { groups: @user.groups, name: @user.name, pw_hash: @user.pw_hash } - end - - assert_redirected_to user_path(assigns(:user)) - end - - test "should show user" do - get :show, id: @user - assert_response :success - end - - test "should get edit" do - get :edit, id: @user - assert_response :success - end - - test "should update user" do - patch :update, id: @user, user: { groups: @user.groups, name: @user.name, pw_hash: @user.pw_hash } - assert_redirected_to user_path(assigns(:user)) - end - - test "should destroy user" do - assert_difference('User.count', -1) do - delete :destroy, id: @user - end - - assert_redirected_to users_path - end + # test "the truth" do + # assert true + # end end diff --git a/test/fixtures/users.yml b/test/fixtures/users.yml index 9f593bc..ea3e874 100644 --- a/test/fixtures/users.yml +++ b/test/fixtures/users.yml @@ -1,11 +1,11 @@ # Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html one: - name: MyText - pw_hash: MyText - groups: 1 + name: MyString + email: MyString + user_name: MyString two: - name: MyText - pw_hash: MyText - groups: 1 + name: MyString + email: MyString + user_name: MyString diff --git a/test/models/tournament_option_test.rb b/test/models/tournament_option_test.rb new file mode 100644 index 0000000..8fa9628 --- /dev/null +++ b/test/models/tournament_option_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class TournamentOptionTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/tournament_options_test.rb b/test/models/tournament_options_test.rb deleted file mode 100644 index 7677fae..0000000 --- a/test/models/tournament_options_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class TournamentOptionsTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end -- cgit v1.2.3-2-g168b From 11be92e4bac671852fd03922049ca592ae4c9f4e Mon Sep 17 00:00:00 2001 From: DavisLWebb Date: Sat, 1 Mar 2014 20:24:43 -0500 Subject: changed the gemfile to include rspecy testing and a security name i cant remember the name of --- test/controllers/alerts_controller_test.rb | 49 ------------------------- test/controllers/games_controller_test.rb | 49 ------------------------- test/controllers/main_controller_test.rb | 7 ---- test/controllers/matches_controller_test.rb | 49 ------------------------- test/controllers/pms_controller_test.rb | 49 ------------------------- test/controllers/search_controller_test.rb | 7 ---- test/controllers/servers_controller_test.rb | 49 ------------------------- test/controllers/teams_controller_test.rb | 49 ------------------------- test/controllers/tournaments_controller_test.rb | 49 ------------------------- test/controllers/users_controller_test.rb | 7 ---- test/fixtures/alerts.yml | 9 ----- test/fixtures/game_attributes.yml | 11 ------ test/fixtures/games.yml | 15 -------- test/fixtures/matches.yml | 7 ---- test/fixtures/pms.yml | 11 ------ test/fixtures/server_settings.yml | 11 ------ test/fixtures/servers.yml | 11 ------ test/fixtures/team_match_pairs.yml | 9 ----- test/fixtures/teams.yml | 11 ------ test/fixtures/tournament_options.yml | 11 ------ test/fixtures/tournaments.yml | 7 ---- test/fixtures/user_team_pairs.yml | 9 ----- test/fixtures/users.yml | 11 ------ test/helpers/alerts_helper_test.rb | 4 -- test/helpers/games_helper_test.rb | 4 -- test/helpers/main_helper_test.rb | 4 -- test/helpers/matches_helper_test.rb | 4 -- test/helpers/pms_helper_test.rb | 4 -- test/helpers/search_helper_test.rb | 4 -- test/helpers/servers_helper_test.rb | 4 -- test/helpers/teams_helper_test.rb | 4 -- test/helpers/tournaments_helper_test.rb | 4 -- test/helpers/users_helper_test.rb | 4 -- test/models/alert_test.rb | 7 ---- test/models/game_attribute_test.rb | 7 ---- test/models/game_test.rb | 7 ---- test/models/match_test.rb | 7 ---- test/models/pm_test.rb | 7 ---- test/models/server_settings_test.rb | 7 ---- test/models/server_test.rb | 7 ---- test/models/team_match_pair_test.rb | 7 ---- test/models/team_test.rb | 7 ---- test/models/tournament_option_test.rb | 7 ---- test/models/tournament_test.rb | 7 ---- test/models/user_team_pair_test.rb | 7 ---- test/models/user_test.rb | 7 ---- 46 files changed, 628 deletions(-) delete mode 100644 test/controllers/alerts_controller_test.rb delete mode 100644 test/controllers/games_controller_test.rb delete mode 100644 test/controllers/main_controller_test.rb delete mode 100644 test/controllers/matches_controller_test.rb delete mode 100644 test/controllers/pms_controller_test.rb delete mode 100644 test/controllers/search_controller_test.rb delete mode 100644 test/controllers/servers_controller_test.rb delete mode 100644 test/controllers/teams_controller_test.rb delete mode 100644 test/controllers/tournaments_controller_test.rb delete mode 100644 test/controllers/users_controller_test.rb delete mode 100644 test/fixtures/alerts.yml delete mode 100644 test/fixtures/game_attributes.yml delete mode 100644 test/fixtures/games.yml delete mode 100644 test/fixtures/matches.yml delete mode 100644 test/fixtures/pms.yml delete mode 100644 test/fixtures/server_settings.yml delete mode 100644 test/fixtures/servers.yml delete mode 100644 test/fixtures/team_match_pairs.yml delete mode 100644 test/fixtures/teams.yml delete mode 100644 test/fixtures/tournament_options.yml delete mode 100644 test/fixtures/tournaments.yml delete mode 100644 test/fixtures/user_team_pairs.yml delete mode 100644 test/fixtures/users.yml delete mode 100644 test/helpers/alerts_helper_test.rb delete mode 100644 test/helpers/games_helper_test.rb delete mode 100644 test/helpers/main_helper_test.rb delete mode 100644 test/helpers/matches_helper_test.rb delete mode 100644 test/helpers/pms_helper_test.rb delete mode 100644 test/helpers/search_helper_test.rb delete mode 100644 test/helpers/servers_helper_test.rb delete mode 100644 test/helpers/teams_helper_test.rb delete mode 100644 test/helpers/tournaments_helper_test.rb delete mode 100644 test/helpers/users_helper_test.rb delete mode 100644 test/models/alert_test.rb delete mode 100644 test/models/game_attribute_test.rb delete mode 100644 test/models/game_test.rb delete mode 100644 test/models/match_test.rb delete mode 100644 test/models/pm_test.rb delete mode 100644 test/models/server_settings_test.rb delete mode 100644 test/models/server_test.rb delete mode 100644 test/models/team_match_pair_test.rb delete mode 100644 test/models/team_test.rb delete mode 100644 test/models/tournament_option_test.rb delete mode 100644 test/models/tournament_test.rb delete mode 100644 test/models/user_team_pair_test.rb delete mode 100644 test/models/user_test.rb (limited to 'test') diff --git a/test/controllers/alerts_controller_test.rb b/test/controllers/alerts_controller_test.rb deleted file mode 100644 index 4a5d911..0000000 --- a/test/controllers/alerts_controller_test.rb +++ /dev/null @@ -1,49 +0,0 @@ -require 'test_helper' - -class AlertsControllerTest < ActionController::TestCase - setup do - @alert = alerts(:one) - end - - test "should get index" do - get :index - assert_response :success - assert_not_nil assigns(:alerts) - end - - test "should get new" do - get :new - assert_response :success - end - - test "should create alert" do - assert_difference('Alert.count') do - post :create, alert: { author_id: @alert.author_id, message: @alert.message } - end - - assert_redirected_to alert_path(assigns(:alert)) - end - - test "should show alert" do - get :show, id: @alert - assert_response :success - end - - test "should get edit" do - get :edit, id: @alert - assert_response :success - end - - test "should update alert" do - patch :update, id: @alert, alert: { author_id: @alert.author_id, message: @alert.message } - assert_redirected_to alert_path(assigns(:alert)) - end - - test "should destroy alert" do - assert_difference('Alert.count', -1) do - delete :destroy, id: @alert - end - - assert_redirected_to alerts_path - end -end diff --git a/test/controllers/games_controller_test.rb b/test/controllers/games_controller_test.rb deleted file mode 100644 index 95c3145..0000000 --- a/test/controllers/games_controller_test.rb +++ /dev/null @@ -1,49 +0,0 @@ -require 'test_helper' - -class GamesControllerTest < ActionController::TestCase - setup do - @game = games(:one) - end - - test "should get index" do - get :index - assert_response :success - assert_not_nil assigns(:games) - end - - test "should get new" do - get :new - assert_response :success - end - - test "should create game" do - assert_difference('Game.count') do - post :create, game: { name: @game.name, players_per_team: @game.players_per_team, randomized_teams: @game.randomized_teams, set_rounds: @game.set_rounds, teams_per_match: @game.teams_per_match } - end - - assert_redirected_to game_path(assigns(:game)) - end - - test "should show game" do - get :show, id: @game - assert_response :success - end - - test "should get edit" do - get :edit, id: @game - assert_response :success - end - - test "should update game" do - patch :update, id: @game, game: { name: @game.name, players_per_team: @game.players_per_team, randomized_teams: @game.randomized_teams, set_rounds: @game.set_rounds, teams_per_match: @game.teams_per_match } - assert_redirected_to game_path(assigns(:game)) - end - - test "should destroy game" do - assert_difference('Game.count', -1) do - delete :destroy, id: @game - end - - assert_redirected_to games_path - end -end diff --git a/test/controllers/main_controller_test.rb b/test/controllers/main_controller_test.rb deleted file mode 100644 index b7ec6bf..0000000 --- a/test/controllers/main_controller_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class MainControllerTest < ActionController::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/controllers/matches_controller_test.rb b/test/controllers/matches_controller_test.rb deleted file mode 100644 index 75c9dcf..0000000 --- a/test/controllers/matches_controller_test.rb +++ /dev/null @@ -1,49 +0,0 @@ -require 'test_helper' - -class MatchesControllerTest < ActionController::TestCase - setup do - @match = matches(:one) - end - - test "should get index" do - get :index - assert_response :success - assert_not_nil assigns(:matches) - end - - test "should get new" do - get :new - assert_response :success - end - - test "should create match" do - assert_difference('Match.count') do - post :create, match: { tournament_id: @match.tournament_id } - end - - assert_redirected_to match_path(assigns(:match)) - end - - test "should show match" do - get :show, id: @match - assert_response :success - end - - test "should get edit" do - get :edit, id: @match - assert_response :success - end - - test "should update match" do - patch :update, id: @match, match: { tournament_id: @match.tournament_id } - assert_redirected_to match_path(assigns(:match)) - end - - test "should destroy match" do - assert_difference('Match.count', -1) do - delete :destroy, id: @match - end - - assert_redirected_to matches_path - end -end diff --git a/test/controllers/pms_controller_test.rb b/test/controllers/pms_controller_test.rb deleted file mode 100644 index 18b2449..0000000 --- a/test/controllers/pms_controller_test.rb +++ /dev/null @@ -1,49 +0,0 @@ -require 'test_helper' - -class PmsControllerTest < ActionController::TestCase - setup do - @pm = pms(:one) - end - - test "should get index" do - get :index - assert_response :success - assert_not_nil assigns(:pms) - end - - test "should get new" do - get :new - assert_response :success - end - - test "should create pm" do - assert_difference('Pm.count') do - post :create, pm: { author_id: @pm.author_id, message: @pm.message, recipient_id: @pm.recipient_id } - end - - assert_redirected_to pm_path(assigns(:pm)) - end - - test "should show pm" do - get :show, id: @pm - assert_response :success - end - - test "should get edit" do - get :edit, id: @pm - assert_response :success - end - - test "should update pm" do - patch :update, id: @pm, pm: { author_id: @pm.author_id, message: @pm.message, recipient_id: @pm.recipient_id } - assert_redirected_to pm_path(assigns(:pm)) - end - - test "should destroy pm" do - assert_difference('Pm.count', -1) do - delete :destroy, id: @pm - end - - assert_redirected_to pms_path - end -end diff --git a/test/controllers/search_controller_test.rb b/test/controllers/search_controller_test.rb deleted file mode 100644 index bfbf22d..0000000 --- a/test/controllers/search_controller_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class SearchControllerTest < ActionController::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/controllers/servers_controller_test.rb b/test/controllers/servers_controller_test.rb deleted file mode 100644 index 5891bb0..0000000 --- a/test/controllers/servers_controller_test.rb +++ /dev/null @@ -1,49 +0,0 @@ -require 'test_helper' - -class ServersControllerTest < ActionController::TestCase - setup do - @server = servers(:one) - end - - test "should get index" do - get :index - assert_response :success - assert_not_nil assigns(:servers) - end - - test "should get new" do - get :new - assert_response :success - end - - test "should create server" do - assert_difference('Server.count') do - post :create, server: { } - end - - assert_redirected_to server_path(assigns(:server)) - end - - test "should show server" do - get :show, id: @server - assert_response :success - end - - test "should get edit" do - get :edit, id: @server - assert_response :success - end - - test "should update server" do - patch :update, id: @server, server: { } - assert_redirected_to server_path(assigns(:server)) - end - - test "should destroy server" do - assert_difference('Server.count', -1) do - delete :destroy, id: @server - end - - assert_redirected_to servers_path - end -end diff --git a/test/controllers/teams_controller_test.rb b/test/controllers/teams_controller_test.rb deleted file mode 100644 index 8bf60be..0000000 --- a/test/controllers/teams_controller_test.rb +++ /dev/null @@ -1,49 +0,0 @@ -require 'test_helper' - -class TeamsControllerTest < ActionController::TestCase - setup do - @team = teams(:one) - end - - test "should get index" do - get :index - assert_response :success - assert_not_nil assigns(:teams) - end - - test "should get new" do - get :new - assert_response :success - end - - test "should create team" do - assert_difference('Team.count') do - post :create, team: { } - end - - assert_redirected_to team_path(assigns(:team)) - end - - test "should show team" do - get :show, id: @team - assert_response :success - end - - test "should get edit" do - get :edit, id: @team - assert_response :success - end - - test "should update team" do - patch :update, id: @team, team: { } - assert_redirected_to team_path(assigns(:team)) - end - - test "should destroy team" do - assert_difference('Team.count', -1) do - delete :destroy, id: @team - end - - assert_redirected_to teams_path - end -end diff --git a/test/controllers/tournaments_controller_test.rb b/test/controllers/tournaments_controller_test.rb deleted file mode 100644 index bdbbfac..0000000 --- a/test/controllers/tournaments_controller_test.rb +++ /dev/null @@ -1,49 +0,0 @@ -require 'test_helper' - -class TournamentsControllerTest < ActionController::TestCase - setup do - @tournament = tournaments(:one) - end - - test "should get index" do - get :index - assert_response :success - assert_not_nil assigns(:tournaments) - end - - test "should get new" do - get :new - assert_response :success - end - - test "should create tournament" do - assert_difference('Tournament.count') do - post :create, tournament: { game_id: @tournament.game_id } - end - - assert_redirected_to tournament_path(assigns(:tournament)) - end - - test "should show tournament" do - get :show, id: @tournament - assert_response :success - end - - test "should get edit" do - get :edit, id: @tournament - assert_response :success - end - - test "should update tournament" do - patch :update, id: @tournament, tournament: { game_id: @tournament.game_id } - assert_redirected_to tournament_path(assigns(:tournament)) - end - - test "should destroy tournament" do - assert_difference('Tournament.count', -1) do - delete :destroy, id: @tournament - end - - assert_redirected_to tournaments_path - end -end diff --git a/test/controllers/users_controller_test.rb b/test/controllers/users_controller_test.rb deleted file mode 100644 index d23f182..0000000 --- a/test/controllers/users_controller_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class UsersControllerTest < ActionController::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/fixtures/alerts.yml b/test/fixtures/alerts.yml deleted file mode 100644 index 52959af..0000000 --- a/test/fixtures/alerts.yml +++ /dev/null @@ -1,9 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -one: - author_id: - message: MyText - -two: - author_id: - message: MyText diff --git a/test/fixtures/game_attributes.yml b/test/fixtures/game_attributes.yml deleted file mode 100644 index eff7212..0000000 --- a/test/fixtures/game_attributes.yml +++ /dev/null @@ -1,11 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -one: - game_id: - key: MyText - type: 1 - -two: - game_id: - key: MyText - type: 1 diff --git a/test/fixtures/games.yml b/test/fixtures/games.yml deleted file mode 100644 index 3068527..0000000 --- a/test/fixtures/games.yml +++ /dev/null @@ -1,15 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -one: - name: MyText - players_per_team: 1 - teams_per_match: 1 - set_rounds: 1 - randomized_teams: 1 - -two: - name: MyText - players_per_team: 1 - teams_per_match: 1 - set_rounds: 1 - randomized_teams: 1 diff --git a/test/fixtures/matches.yml b/test/fixtures/matches.yml deleted file mode 100644 index 0356cee..0000000 --- a/test/fixtures/matches.yml +++ /dev/null @@ -1,7 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -one: - tournament_id: - -two: - tournament_id: diff --git a/test/fixtures/pms.yml b/test/fixtures/pms.yml deleted file mode 100644 index f77e727..0000000 --- a/test/fixtures/pms.yml +++ /dev/null @@ -1,11 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -one: - author_id: - recipient_id: - message: MyText - -two: - author_id: - recipient_id: - message: MyText diff --git a/test/fixtures/server_settings.yml b/test/fixtures/server_settings.yml deleted file mode 100644 index 937a0c0..0000000 --- a/test/fixtures/server_settings.yml +++ /dev/null @@ -1,11 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -# This model initially had no columns defined. If you add columns to the -# model remove the '{}' from the fixture names and add the columns immediately -# below each fixture, per the syntax in the comments below -# -one: {} -# column: value -# -two: {} -# column: value diff --git a/test/fixtures/servers.yml b/test/fixtures/servers.yml deleted file mode 100644 index 937a0c0..0000000 --- a/test/fixtures/servers.yml +++ /dev/null @@ -1,11 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -# This model initially had no columns defined. If you add columns to the -# model remove the '{}' from the fixture names and add the columns immediately -# below each fixture, per the syntax in the comments below -# -one: {} -# column: value -# -two: {} -# column: value diff --git a/test/fixtures/team_match_pairs.yml b/test/fixtures/team_match_pairs.yml deleted file mode 100644 index 5f9cf2f..0000000 --- a/test/fixtures/team_match_pairs.yml +++ /dev/null @@ -1,9 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -one: - team_id: - match_id: - -two: - team_id: - match_id: diff --git a/test/fixtures/teams.yml b/test/fixtures/teams.yml deleted file mode 100644 index 937a0c0..0000000 --- a/test/fixtures/teams.yml +++ /dev/null @@ -1,11 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -# This model initially had no columns defined. If you add columns to the -# model remove the '{}' from the fixture names and add the columns immediately -# below each fixture, per the syntax in the comments below -# -one: {} -# column: value -# -two: {} -# column: value diff --git a/test/fixtures/tournament_options.yml b/test/fixtures/tournament_options.yml deleted file mode 100644 index 937a0c0..0000000 --- a/test/fixtures/tournament_options.yml +++ /dev/null @@ -1,11 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -# This model initially had no columns defined. If you add columns to the -# model remove the '{}' from the fixture names and add the columns immediately -# below each fixture, per the syntax in the comments below -# -one: {} -# column: value -# -two: {} -# column: value diff --git a/test/fixtures/tournaments.yml b/test/fixtures/tournaments.yml deleted file mode 100644 index 4cba7ca..0000000 --- a/test/fixtures/tournaments.yml +++ /dev/null @@ -1,7 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -one: - game_id: - -two: - game_id: diff --git a/test/fixtures/user_team_pairs.yml b/test/fixtures/user_team_pairs.yml deleted file mode 100644 index a76036f..0000000 --- a/test/fixtures/user_team_pairs.yml +++ /dev/null @@ -1,9 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -one: - user_id: - team_id: - -two: - user_id: - team_id: diff --git a/test/fixtures/users.yml b/test/fixtures/users.yml deleted file mode 100644 index ea3e874..0000000 --- a/test/fixtures/users.yml +++ /dev/null @@ -1,11 +0,0 @@ -# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html - -one: - name: MyString - email: MyString - user_name: MyString - -two: - name: MyString - email: MyString - user_name: MyString diff --git a/test/helpers/alerts_helper_test.rb b/test/helpers/alerts_helper_test.rb deleted file mode 100644 index 1d9079d..0000000 --- a/test/helpers/alerts_helper_test.rb +++ /dev/null @@ -1,4 +0,0 @@ -require 'test_helper' - -class AlertsHelperTest < ActionView::TestCase -end diff --git a/test/helpers/games_helper_test.rb b/test/helpers/games_helper_test.rb deleted file mode 100644 index 449a85c..0000000 --- a/test/helpers/games_helper_test.rb +++ /dev/null @@ -1,4 +0,0 @@ -require 'test_helper' - -class GamesHelperTest < ActionView::TestCase -end diff --git a/test/helpers/main_helper_test.rb b/test/helpers/main_helper_test.rb deleted file mode 100644 index 22da3c4..0000000 --- a/test/helpers/main_helper_test.rb +++ /dev/null @@ -1,4 +0,0 @@ -require 'test_helper' - -class MainHelperTest < ActionView::TestCase -end diff --git a/test/helpers/matches_helper_test.rb b/test/helpers/matches_helper_test.rb deleted file mode 100644 index 4cc472f..0000000 --- a/test/helpers/matches_helper_test.rb +++ /dev/null @@ -1,4 +0,0 @@ -require 'test_helper' - -class MatchesHelperTest < ActionView::TestCase -end diff --git a/test/helpers/pms_helper_test.rb b/test/helpers/pms_helper_test.rb deleted file mode 100644 index af80f10..0000000 --- a/test/helpers/pms_helper_test.rb +++ /dev/null @@ -1,4 +0,0 @@ -require 'test_helper' - -class PmsHelperTest < ActionView::TestCase -end diff --git a/test/helpers/search_helper_test.rb b/test/helpers/search_helper_test.rb deleted file mode 100644 index 3034163..0000000 --- a/test/helpers/search_helper_test.rb +++ /dev/null @@ -1,4 +0,0 @@ -require 'test_helper' - -class SearchHelperTest < ActionView::TestCase -end diff --git a/test/helpers/servers_helper_test.rb b/test/helpers/servers_helper_test.rb deleted file mode 100644 index 8fddf34..0000000 --- a/test/helpers/servers_helper_test.rb +++ /dev/null @@ -1,4 +0,0 @@ -require 'test_helper' - -class ServersHelperTest < ActionView::TestCase -end diff --git a/test/helpers/teams_helper_test.rb b/test/helpers/teams_helper_test.rb deleted file mode 100644 index b736483..0000000 --- a/test/helpers/teams_helper_test.rb +++ /dev/null @@ -1,4 +0,0 @@ -require 'test_helper' - -class TeamsHelperTest < ActionView::TestCase -end diff --git a/test/helpers/tournaments_helper_test.rb b/test/helpers/tournaments_helper_test.rb deleted file mode 100644 index 1cf5269..0000000 --- a/test/helpers/tournaments_helper_test.rb +++ /dev/null @@ -1,4 +0,0 @@ -require 'test_helper' - -class TournamentsHelperTest < ActionView::TestCase -end diff --git a/test/helpers/users_helper_test.rb b/test/helpers/users_helper_test.rb deleted file mode 100644 index 96af37a..0000000 --- a/test/helpers/users_helper_test.rb +++ /dev/null @@ -1,4 +0,0 @@ -require 'test_helper' - -class UsersHelperTest < ActionView::TestCase -end diff --git a/test/models/alert_test.rb b/test/models/alert_test.rb deleted file mode 100644 index b59c65e..0000000 --- a/test/models/alert_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class AlertTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/game_attribute_test.rb b/test/models/game_attribute_test.rb deleted file mode 100644 index 13c6e65..0000000 --- a/test/models/game_attribute_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class GameAttributeTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/game_test.rb b/test/models/game_test.rb deleted file mode 100644 index 2cab36e..0000000 --- a/test/models/game_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class GameTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/match_test.rb b/test/models/match_test.rb deleted file mode 100644 index 14436b1..0000000 --- a/test/models/match_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class MatchTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/pm_test.rb b/test/models/pm_test.rb deleted file mode 100644 index e7f6b8f..0000000 --- a/test/models/pm_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class PmTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/server_settings_test.rb b/test/models/server_settings_test.rb deleted file mode 100644 index 470b316..0000000 --- a/test/models/server_settings_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class ServerSettingsTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/server_test.rb b/test/models/server_test.rb deleted file mode 100644 index 125ffc9..0000000 --- a/test/models/server_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class ServerTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/team_match_pair_test.rb b/test/models/team_match_pair_test.rb deleted file mode 100644 index c250b3c..0000000 --- a/test/models/team_match_pair_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class TeamMatchPairTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/team_test.rb b/test/models/team_test.rb deleted file mode 100644 index 8b101cb..0000000 --- a/test/models/team_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class TeamTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/tournament_option_test.rb b/test/models/tournament_option_test.rb deleted file mode 100644 index 8fa9628..0000000 --- a/test/models/tournament_option_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class TournamentOptionTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/tournament_test.rb b/test/models/tournament_test.rb deleted file mode 100644 index 24a7e5f..0000000 --- a/test/models/tournament_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class TournamentTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/user_team_pair_test.rb b/test/models/user_team_pair_test.rb deleted file mode 100644 index 55f5c58..0000000 --- a/test/models/user_team_pair_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class UserTeamPairTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end diff --git a/test/models/user_test.rb b/test/models/user_test.rb deleted file mode 100644 index 82f61e0..0000000 --- a/test/models/user_test.rb +++ /dev/null @@ -1,7 +0,0 @@ -require 'test_helper' - -class UserTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end -end -- cgit v1.2.3-2-g168b From 4e682a9a8596326a2d1faab6c44e5a54918c5ba0 Mon Sep 17 00:00:00 2001 From: DavisLWebb Date: Sun, 2 Mar 2014 15:04:26 -0500 Subject: Gemfile.lock --- test/controllers/.keep | 0 test/fixtures/.keep | 0 test/helpers/.keep | 0 test/integration/.keep | 0 test/mailers/.keep | 0 test/models/.keep | 0 test/test_helper.rb | 15 --------------- 7 files changed, 15 deletions(-) delete mode 100644 test/controllers/.keep delete mode 100644 test/fixtures/.keep delete mode 100644 test/helpers/.keep delete mode 100644 test/integration/.keep delete mode 100644 test/mailers/.keep delete mode 100644 test/models/.keep delete mode 100644 test/test_helper.rb (limited to 'test') diff --git a/test/controllers/.keep b/test/controllers/.keep deleted file mode 100644 index e69de29..0000000 diff --git a/test/fixtures/.keep b/test/fixtures/.keep deleted file mode 100644 index e69de29..0000000 diff --git a/test/helpers/.keep b/test/helpers/.keep deleted file mode 100644 index e69de29..0000000 diff --git a/test/integration/.keep b/test/integration/.keep deleted file mode 100644 index e69de29..0000000 diff --git a/test/mailers/.keep b/test/mailers/.keep deleted file mode 100644 index e69de29..0000000 diff --git a/test/models/.keep b/test/models/.keep deleted file mode 100644 index e69de29..0000000 diff --git a/test/test_helper.rb b/test/test_helper.rb deleted file mode 100644 index bc7e05d..0000000 --- a/test/test_helper.rb +++ /dev/null @@ -1,15 +0,0 @@ -ENV["RAILS_ENV"] ||= "test" -require File.expand_path('../../config/environment', __FILE__) -require 'rails/test_help' - -class ActiveSupport::TestCase - ActiveRecord::Migration.check_pending! - - # Setup all fixtures in test/fixtures/*.yml for all tests in alphabetical order. - # - # Note: You'll currently still have to declare fixtures explicitly in integration tests - # -- they do not yet inherit this setting - fixtures :all - - # Add more helper methods to be used by all tests here... -end -- cgit v1.2.3-2-g168b From 423d0e5a440d8d66407522bc842ef273196173bc Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Mon, 3 Mar 2014 22:20:02 -0500 Subject: run ./generate.sh --- test/controllers/.keep | 0 test/controllers/alerts_controller_test.rb | 49 +++++++++++++++++++++++++ test/controllers/games_controller_test.rb | 49 +++++++++++++++++++++++++ test/controllers/main_controller_test.rb | 7 ++++ test/controllers/matches_controller_test.rb | 49 +++++++++++++++++++++++++ test/controllers/pms_controller_test.rb | 49 +++++++++++++++++++++++++ test/controllers/search_controller_test.rb | 7 ++++ test/controllers/servers_controller_test.rb | 49 +++++++++++++++++++++++++ test/controllers/sessions_controller_test.rb | 7 ++++ test/controllers/static_controller_test.rb | 7 ++++ test/controllers/teams_controller_test.rb | 49 +++++++++++++++++++++++++ test/controllers/tournaments_controller_test.rb | 49 +++++++++++++++++++++++++ test/controllers/users_controller_test.rb | 49 +++++++++++++++++++++++++ test/fixtures/.keep | 0 test/fixtures/alerts.yml | 9 +++++ test/fixtures/game_attributes.yml | 11 ++++++ test/fixtures/games.yml | 15 ++++++++ test/fixtures/matches.yml | 9 +++++ test/fixtures/pms.yml | 11 ++++++ test/fixtures/server_settings.yml | 11 ++++++ test/fixtures/servers.yml | 11 ++++++ test/fixtures/team_match_pairs.yml | 9 +++++ test/fixtures/teams.yml | 11 ++++++ test/fixtures/tournament_options.yml | 11 ++++++ test/fixtures/tournaments.yml | 7 ++++ test/fixtures/user_team_pairs.yml | 9 +++++ test/fixtures/users.yml | 11 ++++++ test/helpers/.keep | 0 test/helpers/alerts_helper_test.rb | 4 ++ test/helpers/games_helper_test.rb | 4 ++ test/helpers/main_helper_test.rb | 4 ++ test/helpers/matches_helper_test.rb | 4 ++ test/helpers/pms_helper_test.rb | 4 ++ test/helpers/search_helper_test.rb | 4 ++ test/helpers/servers_helper_test.rb | 4 ++ test/helpers/sessions_helper_test.rb | 4 ++ test/helpers/static_helper_test.rb | 4 ++ test/helpers/teams_helper_test.rb | 4 ++ test/helpers/tournaments_helper_test.rb | 4 ++ test/helpers/users_helper_test.rb | 4 ++ test/integration/.keep | 0 test/mailers/.keep | 0 test/models/.keep | 0 test/models/alert_test.rb | 7 ++++ test/models/game_attribute_test.rb | 7 ++++ test/models/game_test.rb | 7 ++++ test/models/match_test.rb | 7 ++++ test/models/pm_test.rb | 7 ++++ test/models/server_settings_test.rb | 7 ++++ test/models/server_test.rb | 7 ++++ test/models/team_match_pair_test.rb | 7 ++++ test/models/team_test.rb | 7 ++++ test/models/tournament_option_test.rb | 7 ++++ test/models/tournament_test.rb | 7 ++++ test/models/user_team_pair_test.rb | 7 ++++ test/models/user_test.rb | 7 ++++ test/test_helper.rb | 15 ++++++++ 57 files changed, 709 insertions(+) create mode 100644 test/controllers/.keep create mode 100644 test/controllers/alerts_controller_test.rb create mode 100644 test/controllers/games_controller_test.rb create mode 100644 test/controllers/main_controller_test.rb create mode 100644 test/controllers/matches_controller_test.rb create mode 100644 test/controllers/pms_controller_test.rb create mode 100644 test/controllers/search_controller_test.rb create mode 100644 test/controllers/servers_controller_test.rb create mode 100644 test/controllers/sessions_controller_test.rb create mode 100644 test/controllers/static_controller_test.rb create mode 100644 test/controllers/teams_controller_test.rb create mode 100644 test/controllers/tournaments_controller_test.rb create mode 100644 test/controllers/users_controller_test.rb create mode 100644 test/fixtures/.keep create mode 100644 test/fixtures/alerts.yml create mode 100644 test/fixtures/game_attributes.yml create mode 100644 test/fixtures/games.yml create mode 100644 test/fixtures/matches.yml create mode 100644 test/fixtures/pms.yml create mode 100644 test/fixtures/server_settings.yml create mode 100644 test/fixtures/servers.yml create mode 100644 test/fixtures/team_match_pairs.yml create mode 100644 test/fixtures/teams.yml create mode 100644 test/fixtures/tournament_options.yml create mode 100644 test/fixtures/tournaments.yml create mode 100644 test/fixtures/user_team_pairs.yml create mode 100644 test/fixtures/users.yml create mode 100644 test/helpers/.keep create mode 100644 test/helpers/alerts_helper_test.rb create mode 100644 test/helpers/games_helper_test.rb create mode 100644 test/helpers/main_helper_test.rb create mode 100644 test/helpers/matches_helper_test.rb create mode 100644 test/helpers/pms_helper_test.rb create mode 100644 test/helpers/search_helper_test.rb create mode 100644 test/helpers/servers_helper_test.rb create mode 100644 test/helpers/sessions_helper_test.rb create mode 100644 test/helpers/static_helper_test.rb create mode 100644 test/helpers/teams_helper_test.rb create mode 100644 test/helpers/tournaments_helper_test.rb create mode 100644 test/helpers/users_helper_test.rb create mode 100644 test/integration/.keep create mode 100644 test/mailers/.keep create mode 100644 test/models/.keep create mode 100644 test/models/alert_test.rb create mode 100644 test/models/game_attribute_test.rb create mode 100644 test/models/game_test.rb create mode 100644 test/models/match_test.rb create mode 100644 test/models/pm_test.rb create mode 100644 test/models/server_settings_test.rb create mode 100644 test/models/server_test.rb create mode 100644 test/models/team_match_pair_test.rb create mode 100644 test/models/team_test.rb create mode 100644 test/models/tournament_option_test.rb create mode 100644 test/models/tournament_test.rb create mode 100644 test/models/user_team_pair_test.rb create mode 100644 test/models/user_test.rb create mode 100644 test/test_helper.rb (limited to 'test') diff --git a/test/controllers/.keep b/test/controllers/.keep new file mode 100644 index 0000000..e69de29 diff --git a/test/controllers/alerts_controller_test.rb b/test/controllers/alerts_controller_test.rb new file mode 100644 index 0000000..4a5d911 --- /dev/null +++ b/test/controllers/alerts_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class AlertsControllerTest < ActionController::TestCase + setup do + @alert = alerts(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:alerts) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create alert" do + assert_difference('Alert.count') do + post :create, alert: { author_id: @alert.author_id, message: @alert.message } + end + + assert_redirected_to alert_path(assigns(:alert)) + end + + test "should show alert" do + get :show, id: @alert + assert_response :success + end + + test "should get edit" do + get :edit, id: @alert + assert_response :success + end + + test "should update alert" do + patch :update, id: @alert, alert: { author_id: @alert.author_id, message: @alert.message } + assert_redirected_to alert_path(assigns(:alert)) + end + + test "should destroy alert" do + assert_difference('Alert.count', -1) do + delete :destroy, id: @alert + end + + assert_redirected_to alerts_path + end +end diff --git a/test/controllers/games_controller_test.rb b/test/controllers/games_controller_test.rb new file mode 100644 index 0000000..95c3145 --- /dev/null +++ b/test/controllers/games_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class GamesControllerTest < ActionController::TestCase + setup do + @game = games(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:games) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create game" do + assert_difference('Game.count') do + post :create, game: { name: @game.name, players_per_team: @game.players_per_team, randomized_teams: @game.randomized_teams, set_rounds: @game.set_rounds, teams_per_match: @game.teams_per_match } + end + + assert_redirected_to game_path(assigns(:game)) + end + + test "should show game" do + get :show, id: @game + assert_response :success + end + + test "should get edit" do + get :edit, id: @game + assert_response :success + end + + test "should update game" do + patch :update, id: @game, game: { name: @game.name, players_per_team: @game.players_per_team, randomized_teams: @game.randomized_teams, set_rounds: @game.set_rounds, teams_per_match: @game.teams_per_match } + assert_redirected_to game_path(assigns(:game)) + end + + test "should destroy game" do + assert_difference('Game.count', -1) do + delete :destroy, id: @game + end + + assert_redirected_to games_path + end +end diff --git a/test/controllers/main_controller_test.rb b/test/controllers/main_controller_test.rb new file mode 100644 index 0000000..b7ec6bf --- /dev/null +++ b/test/controllers/main_controller_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class MainControllerTest < ActionController::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/controllers/matches_controller_test.rb b/test/controllers/matches_controller_test.rb new file mode 100644 index 0000000..50675d8 --- /dev/null +++ b/test/controllers/matches_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class MatchesControllerTest < ActionController::TestCase + setup do + @match = matches(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:matches) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create match" do + assert_difference('Match.count') do + post :create, match: { name: @match.name, tournament_id: @match.tournament_id } + end + + assert_redirected_to match_path(assigns(:match)) + end + + test "should show match" do + get :show, id: @match + assert_response :success + end + + test "should get edit" do + get :edit, id: @match + assert_response :success + end + + test "should update match" do + patch :update, id: @match, match: { name: @match.name, tournament_id: @match.tournament_id } + assert_redirected_to match_path(assigns(:match)) + end + + test "should destroy match" do + assert_difference('Match.count', -1) do + delete :destroy, id: @match + end + + assert_redirected_to matches_path + end +end diff --git a/test/controllers/pms_controller_test.rb b/test/controllers/pms_controller_test.rb new file mode 100644 index 0000000..18b2449 --- /dev/null +++ b/test/controllers/pms_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class PmsControllerTest < ActionController::TestCase + setup do + @pm = pms(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:pms) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create pm" do + assert_difference('Pm.count') do + post :create, pm: { author_id: @pm.author_id, message: @pm.message, recipient_id: @pm.recipient_id } + end + + assert_redirected_to pm_path(assigns(:pm)) + end + + test "should show pm" do + get :show, id: @pm + assert_response :success + end + + test "should get edit" do + get :edit, id: @pm + assert_response :success + end + + test "should update pm" do + patch :update, id: @pm, pm: { author_id: @pm.author_id, message: @pm.message, recipient_id: @pm.recipient_id } + assert_redirected_to pm_path(assigns(:pm)) + end + + test "should destroy pm" do + assert_difference('Pm.count', -1) do + delete :destroy, id: @pm + end + + assert_redirected_to pms_path + end +end diff --git a/test/controllers/search_controller_test.rb b/test/controllers/search_controller_test.rb new file mode 100644 index 0000000..bfbf22d --- /dev/null +++ b/test/controllers/search_controller_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class SearchControllerTest < ActionController::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/controllers/servers_controller_test.rb b/test/controllers/servers_controller_test.rb new file mode 100644 index 0000000..5891bb0 --- /dev/null +++ b/test/controllers/servers_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class ServersControllerTest < ActionController::TestCase + setup do + @server = servers(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:servers) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create server" do + assert_difference('Server.count') do + post :create, server: { } + end + + assert_redirected_to server_path(assigns(:server)) + end + + test "should show server" do + get :show, id: @server + assert_response :success + end + + test "should get edit" do + get :edit, id: @server + assert_response :success + end + + test "should update server" do + patch :update, id: @server, server: { } + assert_redirected_to server_path(assigns(:server)) + end + + test "should destroy server" do + assert_difference('Server.count', -1) do + delete :destroy, id: @server + end + + assert_redirected_to servers_path + end +end diff --git a/test/controllers/sessions_controller_test.rb b/test/controllers/sessions_controller_test.rb new file mode 100644 index 0000000..d30ebc3 --- /dev/null +++ b/test/controllers/sessions_controller_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class SessionsControllerTest < ActionController::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/controllers/static_controller_test.rb b/test/controllers/static_controller_test.rb new file mode 100644 index 0000000..e62ae2a --- /dev/null +++ b/test/controllers/static_controller_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class StaticControllerTest < ActionController::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/controllers/teams_controller_test.rb b/test/controllers/teams_controller_test.rb new file mode 100644 index 0000000..8bf60be --- /dev/null +++ b/test/controllers/teams_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class TeamsControllerTest < ActionController::TestCase + setup do + @team = teams(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:teams) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create team" do + assert_difference('Team.count') do + post :create, team: { } + end + + assert_redirected_to team_path(assigns(:team)) + end + + test "should show team" do + get :show, id: @team + assert_response :success + end + + test "should get edit" do + get :edit, id: @team + assert_response :success + end + + test "should update team" do + patch :update, id: @team, team: { } + assert_redirected_to team_path(assigns(:team)) + end + + test "should destroy team" do + assert_difference('Team.count', -1) do + delete :destroy, id: @team + end + + assert_redirected_to teams_path + end +end diff --git a/test/controllers/tournaments_controller_test.rb b/test/controllers/tournaments_controller_test.rb new file mode 100644 index 0000000..bdbbfac --- /dev/null +++ b/test/controllers/tournaments_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class TournamentsControllerTest < ActionController::TestCase + setup do + @tournament = tournaments(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:tournaments) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create tournament" do + assert_difference('Tournament.count') do + post :create, tournament: { game_id: @tournament.game_id } + end + + assert_redirected_to tournament_path(assigns(:tournament)) + end + + test "should show tournament" do + get :show, id: @tournament + assert_response :success + end + + test "should get edit" do + get :edit, id: @tournament + assert_response :success + end + + test "should update tournament" do + patch :update, id: @tournament, tournament: { game_id: @tournament.game_id } + assert_redirected_to tournament_path(assigns(:tournament)) + end + + test "should destroy tournament" do + assert_difference('Tournament.count', -1) do + delete :destroy, id: @tournament + end + + assert_redirected_to tournaments_path + end +end diff --git a/test/controllers/users_controller_test.rb b/test/controllers/users_controller_test.rb new file mode 100644 index 0000000..79a5700 --- /dev/null +++ b/test/controllers/users_controller_test.rb @@ -0,0 +1,49 @@ +require 'test_helper' + +class UsersControllerTest < ActionController::TestCase + setup do + @user = users(:one) + end + + test "should get index" do + get :index + assert_response :success + assert_not_nil assigns(:users) + end + + test "should get new" do + get :new + assert_response :success + end + + test "should create user" do + assert_difference('User.count') do + post :create, user: { email: @user.email, name: @user.name, user_name: @user.user_name } + end + + assert_redirected_to user_path(assigns(:user)) + end + + test "should show user" do + get :show, id: @user + assert_response :success + end + + test "should get edit" do + get :edit, id: @user + assert_response :success + end + + test "should update user" do + patch :update, id: @user, user: { email: @user.email, name: @user.name, user_name: @user.user_name } + assert_redirected_to user_path(assigns(:user)) + end + + test "should destroy user" do + assert_difference('User.count', -1) do + delete :destroy, id: @user + end + + assert_redirected_to users_path + end +end diff --git a/test/fixtures/.keep b/test/fixtures/.keep new file mode 100644 index 0000000..e69de29 diff --git a/test/fixtures/alerts.yml b/test/fixtures/alerts.yml new file mode 100644 index 0000000..52959af --- /dev/null +++ b/test/fixtures/alerts.yml @@ -0,0 +1,9 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + author_id: + message: MyText + +two: + author_id: + message: MyText diff --git a/test/fixtures/game_attributes.yml b/test/fixtures/game_attributes.yml new file mode 100644 index 0000000..eff7212 --- /dev/null +++ b/test/fixtures/game_attributes.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + game_id: + key: MyText + type: 1 + +two: + game_id: + key: MyText + type: 1 diff --git a/test/fixtures/games.yml b/test/fixtures/games.yml new file mode 100644 index 0000000..3068527 --- /dev/null +++ b/test/fixtures/games.yml @@ -0,0 +1,15 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + name: MyText + players_per_team: 1 + teams_per_match: 1 + set_rounds: 1 + randomized_teams: 1 + +two: + name: MyText + players_per_team: 1 + teams_per_match: 1 + set_rounds: 1 + randomized_teams: 1 diff --git a/test/fixtures/matches.yml b/test/fixtures/matches.yml new file mode 100644 index 0000000..089fc65 --- /dev/null +++ b/test/fixtures/matches.yml @@ -0,0 +1,9 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + tournament_id: + name: MyString + +two: + tournament_id: + name: MyString diff --git a/test/fixtures/pms.yml b/test/fixtures/pms.yml new file mode 100644 index 0000000..f77e727 --- /dev/null +++ b/test/fixtures/pms.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + author_id: + recipient_id: + message: MyText + +two: + author_id: + recipient_id: + message: MyText diff --git a/test/fixtures/server_settings.yml b/test/fixtures/server_settings.yml new file mode 100644 index 0000000..937a0c0 --- /dev/null +++ b/test/fixtures/server_settings.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +# This model initially had no columns defined. If you add columns to the +# model remove the '{}' from the fixture names and add the columns immediately +# below each fixture, per the syntax in the comments below +# +one: {} +# column: value +# +two: {} +# column: value diff --git a/test/fixtures/servers.yml b/test/fixtures/servers.yml new file mode 100644 index 0000000..937a0c0 --- /dev/null +++ b/test/fixtures/servers.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +# This model initially had no columns defined. If you add columns to the +# model remove the '{}' from the fixture names and add the columns immediately +# below each fixture, per the syntax in the comments below +# +one: {} +# column: value +# +two: {} +# column: value diff --git a/test/fixtures/team_match_pairs.yml b/test/fixtures/team_match_pairs.yml new file mode 100644 index 0000000..5f9cf2f --- /dev/null +++ b/test/fixtures/team_match_pairs.yml @@ -0,0 +1,9 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + team_id: + match_id: + +two: + team_id: + match_id: diff --git a/test/fixtures/teams.yml b/test/fixtures/teams.yml new file mode 100644 index 0000000..937a0c0 --- /dev/null +++ b/test/fixtures/teams.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +# This model initially had no columns defined. If you add columns to the +# model remove the '{}' from the fixture names and add the columns immediately +# below each fixture, per the syntax in the comments below +# +one: {} +# column: value +# +two: {} +# column: value diff --git a/test/fixtures/tournament_options.yml b/test/fixtures/tournament_options.yml new file mode 100644 index 0000000..937a0c0 --- /dev/null +++ b/test/fixtures/tournament_options.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +# This model initially had no columns defined. If you add columns to the +# model remove the '{}' from the fixture names and add the columns immediately +# below each fixture, per the syntax in the comments below +# +one: {} +# column: value +# +two: {} +# column: value diff --git a/test/fixtures/tournaments.yml b/test/fixtures/tournaments.yml new file mode 100644 index 0000000..4cba7ca --- /dev/null +++ b/test/fixtures/tournaments.yml @@ -0,0 +1,7 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + game_id: + +two: + game_id: diff --git a/test/fixtures/user_team_pairs.yml b/test/fixtures/user_team_pairs.yml new file mode 100644 index 0000000..a76036f --- /dev/null +++ b/test/fixtures/user_team_pairs.yml @@ -0,0 +1,9 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + user_id: + team_id: + +two: + user_id: + team_id: diff --git a/test/fixtures/users.yml b/test/fixtures/users.yml new file mode 100644 index 0000000..ea3e874 --- /dev/null +++ b/test/fixtures/users.yml @@ -0,0 +1,11 @@ +# Read about fixtures at http://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + name: MyString + email: MyString + user_name: MyString + +two: + name: MyString + email: MyString + user_name: MyString diff --git a/test/helpers/.keep b/test/helpers/.keep new file mode 100644 index 0000000..e69de29 diff --git a/test/helpers/alerts_helper_test.rb b/test/helpers/alerts_helper_test.rb new file mode 100644 index 0000000..1d9079d --- /dev/null +++ b/test/helpers/alerts_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class AlertsHelperTest < ActionView::TestCase +end diff --git a/test/helpers/games_helper_test.rb b/test/helpers/games_helper_test.rb new file mode 100644 index 0000000..449a85c --- /dev/null +++ b/test/helpers/games_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class GamesHelperTest < ActionView::TestCase +end diff --git a/test/helpers/main_helper_test.rb b/test/helpers/main_helper_test.rb new file mode 100644 index 0000000..22da3c4 --- /dev/null +++ b/test/helpers/main_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class MainHelperTest < ActionView::TestCase +end diff --git a/test/helpers/matches_helper_test.rb b/test/helpers/matches_helper_test.rb new file mode 100644 index 0000000..4cc472f --- /dev/null +++ b/test/helpers/matches_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class MatchesHelperTest < ActionView::TestCase +end diff --git a/test/helpers/pms_helper_test.rb b/test/helpers/pms_helper_test.rb new file mode 100644 index 0000000..af80f10 --- /dev/null +++ b/test/helpers/pms_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class PmsHelperTest < ActionView::TestCase +end diff --git a/test/helpers/search_helper_test.rb b/test/helpers/search_helper_test.rb new file mode 100644 index 0000000..3034163 --- /dev/null +++ b/test/helpers/search_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class SearchHelperTest < ActionView::TestCase +end diff --git a/test/helpers/servers_helper_test.rb b/test/helpers/servers_helper_test.rb new file mode 100644 index 0000000..8fddf34 --- /dev/null +++ b/test/helpers/servers_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class ServersHelperTest < ActionView::TestCase +end diff --git a/test/helpers/sessions_helper_test.rb b/test/helpers/sessions_helper_test.rb new file mode 100644 index 0000000..7d44e09 --- /dev/null +++ b/test/helpers/sessions_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class SessionsHelperTest < ActionView::TestCase +end diff --git a/test/helpers/static_helper_test.rb b/test/helpers/static_helper_test.rb new file mode 100644 index 0000000..3b96f2b --- /dev/null +++ b/test/helpers/static_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class StaticHelperTest < ActionView::TestCase +end diff --git a/test/helpers/teams_helper_test.rb b/test/helpers/teams_helper_test.rb new file mode 100644 index 0000000..b736483 --- /dev/null +++ b/test/helpers/teams_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class TeamsHelperTest < ActionView::TestCase +end diff --git a/test/helpers/tournaments_helper_test.rb b/test/helpers/tournaments_helper_test.rb new file mode 100644 index 0000000..1cf5269 --- /dev/null +++ b/test/helpers/tournaments_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class TournamentsHelperTest < ActionView::TestCase +end diff --git a/test/helpers/users_helper_test.rb b/test/helpers/users_helper_test.rb new file mode 100644 index 0000000..96af37a --- /dev/null +++ b/test/helpers/users_helper_test.rb @@ -0,0 +1,4 @@ +require 'test_helper' + +class UsersHelperTest < ActionView::TestCase +end diff --git a/test/integration/.keep b/test/integration/.keep new file mode 100644 index 0000000..e69de29 diff --git a/test/mailers/.keep b/test/mailers/.keep new file mode 100644 index 0000000..e69de29 diff --git a/test/models/.keep b/test/models/.keep new file mode 100644 index 0000000..e69de29 diff --git a/test/models/alert_test.rb b/test/models/alert_test.rb new file mode 100644 index 0000000..b59c65e --- /dev/null +++ b/test/models/alert_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class AlertTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/game_attribute_test.rb b/test/models/game_attribute_test.rb new file mode 100644 index 0000000..13c6e65 --- /dev/null +++ b/test/models/game_attribute_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class GameAttributeTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/game_test.rb b/test/models/game_test.rb new file mode 100644 index 0000000..2cab36e --- /dev/null +++ b/test/models/game_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class GameTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/match_test.rb b/test/models/match_test.rb new file mode 100644 index 0000000..14436b1 --- /dev/null +++ b/test/models/match_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class MatchTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/pm_test.rb b/test/models/pm_test.rb new file mode 100644 index 0000000..e7f6b8f --- /dev/null +++ b/test/models/pm_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class PmTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/server_settings_test.rb b/test/models/server_settings_test.rb new file mode 100644 index 0000000..470b316 --- /dev/null +++ b/test/models/server_settings_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class ServerSettingsTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/server_test.rb b/test/models/server_test.rb new file mode 100644 index 0000000..125ffc9 --- /dev/null +++ b/test/models/server_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class ServerTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/team_match_pair_test.rb b/test/models/team_match_pair_test.rb new file mode 100644 index 0000000..c250b3c --- /dev/null +++ b/test/models/team_match_pair_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class TeamMatchPairTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/team_test.rb b/test/models/team_test.rb new file mode 100644 index 0000000..8b101cb --- /dev/null +++ b/test/models/team_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class TeamTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/tournament_option_test.rb b/test/models/tournament_option_test.rb new file mode 100644 index 0000000..8fa9628 --- /dev/null +++ b/test/models/tournament_option_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class TournamentOptionTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/tournament_test.rb b/test/models/tournament_test.rb new file mode 100644 index 0000000..24a7e5f --- /dev/null +++ b/test/models/tournament_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class TournamentTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/user_team_pair_test.rb b/test/models/user_team_pair_test.rb new file mode 100644 index 0000000..55f5c58 --- /dev/null +++ b/test/models/user_team_pair_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class UserTeamPairTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/models/user_test.rb b/test/models/user_test.rb new file mode 100644 index 0000000..82f61e0 --- /dev/null +++ b/test/models/user_test.rb @@ -0,0 +1,7 @@ +require 'test_helper' + +class UserTest < ActiveSupport::TestCase + # test "the truth" do + # assert true + # end +end diff --git a/test/test_helper.rb b/test/test_helper.rb new file mode 100644 index 0000000..bc7e05d --- /dev/null +++ b/test/test_helper.rb @@ -0,0 +1,15 @@ +ENV["RAILS_ENV"] ||= "test" +require File.expand_path('../../config/environment', __FILE__) +require 'rails/test_help' + +class ActiveSupport::TestCase + ActiveRecord::Migration.check_pending! + + # Setup all fixtures in test/fixtures/*.yml for all tests in alphabetical order. + # + # Note: You'll currently still have to declare fixtures explicitly in integration tests + # -- they do not yet inherit this setting + fixtures :all + + # Add more helper methods to be used by all tests here... +end -- cgit v1.2.3-2-g168b