Permalink
Browse files

Fix build the correct way, ensure new apps work, closes #63

  • Loading branch information...
1 parent 7a093af commit 37d894f94e67fb43302bd1180abd786e39787462 @josevalim josevalim committed May 17, 2012
Showing with 3 additions and 3 deletions.
  1. +3 −3 test/generators_test.rb
@@ -16,12 +16,12 @@ class SerializerGeneratorTest < Rails::Generators::TestCase
def test_generates_a_serializer
run_generator
- assert_file "app/serializers/account_serializer.rb", /class AccountSerializer < ApplicationSerializer/
+ assert_file "app/serializers/account_serializer.rb", /class AccountSerializer < ActiveModel::Serializer/
end
def test_generates_a_namespaced_serializer
run_generator ["admin/account"]
- assert_file "app/serializers/admin/account_serializer.rb", /class Admin::AccountSerializer < ApplicationSerializer/
+ assert_file "app/serializers/admin/account_serializer.rb", /class Admin::AccountSerializer < ActiveModel::Serializer/
end
def test_uses_application_serializer_if_one_exists
@@ -62,6 +62,6 @@ def test_generates_attributes_and_associations
def test_with_no_attributes_does_not_add_extra_space
run_generator ["account"]
- assert_file "app/serializers/account_serializer.rb", /class AccountSerializer < ApplicationSerializer\nend/
+ assert_file "app/serializers/account_serializer.rb", /class AccountSerializer < ActiveModel::Serializer\nend/
end
end

0 comments on commit 37d894f

Please sign in to comment.