diff --git a/test/functional/my_profile_controller_test.rb b/test/functional/my_profile_controller_test.rb
new file mode 100644
index 0000000..36bc10f
--- /dev/null
+++ b/test/functional/my_profile_controller_test.rb
@@ -0,0 +1,38 @@
+require File.dirname(__FILE__) + '/../test_helper'
+require 'profile_admin_controller'
+
+# Re-raise errors caught by the controller.
+class ProfileAdminController; def rescue_action(e) raise e end; end
+
+class OnlyForPersonTestController < ProfileAdminController
+ requires_profile_class Person
+ def index
+ render :text => '
something
'
+ end
+end
+
+class ProfileAdminControllerTest < Test::Unit::TestCase
+
+ all_fixtures
+ def setup
+ @controller = ProfileAdminController.new
+ @request = ActionController::TestRequest.new
+ @response = ActionController::TestResponse.new
+ end
+
+ def test_should_allow_person
+ @controller = OnlyForPersonTestController.new
+ person = create_user('random_joe')
+
+ get :index, :profile => 'random_joe'
+ assert_response :success
+ end
+
+ def test_should_not_allow_bare_profile
+ @controller = OnlyForPersonTestController.new
+ org = Organization.create!(:identifier => 'hacking_institute', :name => 'Hacking Institute')
+
+ get :index, :profile => 'hacking_institute'
+ assert_response 403 # forbidden
+ end
+end
diff --git a/test/functional/profile_admin_controller_test.rb b/test/functional/profile_admin_controller_test.rb
deleted file mode 100644
index 36bc10f..0000000
--- a/test/functional/profile_admin_controller_test.rb
+++ /dev/null
@@ -1,38 +0,0 @@
-require File.dirname(__FILE__) + '/../test_helper'
-require 'profile_admin_controller'
-
-# Re-raise errors caught by the controller.
-class ProfileAdminController; def rescue_action(e) raise e end; end
-
-class OnlyForPersonTestController < ProfileAdminController
- requires_profile_class Person
- def index
- render :text => 'something
'
- end
-end
-
-class ProfileAdminControllerTest < Test::Unit::TestCase
-
- all_fixtures
- def setup
- @controller = ProfileAdminController.new
- @request = ActionController::TestRequest.new
- @response = ActionController::TestResponse.new
- end
-
- def test_should_allow_person
- @controller = OnlyForPersonTestController.new
- person = create_user('random_joe')
-
- get :index, :profile => 'random_joe'
- assert_response :success
- end
-
- def test_should_not_allow_bare_profile
- @controller = OnlyForPersonTestController.new
- org = Organization.create!(:identifier => 'hacking_institute', :name => 'Hacking Institute')
-
- get :index, :profile => 'hacking_institute'
- assert_response 403 # forbidden
- end
-end
--
libgit2 0.21.2