From 2c59d78cde32cfd6f6fcda1f9aa78f94b38e5930 Mon Sep 17 00:00:00 2001 From: hukl Date: Tue, 6 Oct 2009 20:54:47 +0200 Subject: updated globalize2 --- vendor/plugins/globalize2/test/data/models.rb | 29 ++++++++++++++++++++++ .../globalize2/test/data/no_globalize_schema.rb | 4 +-- vendor/plugins/globalize2/test/data/post.rb | 24 ------------------ 3 files changed, 31 insertions(+), 26 deletions(-) create mode 100644 vendor/plugins/globalize2/test/data/models.rb delete mode 100644 vendor/plugins/globalize2/test/data/post.rb (limited to 'vendor/plugins/globalize2/test/data') diff --git a/vendor/plugins/globalize2/test/data/models.rb b/vendor/plugins/globalize2/test/data/models.rb new file mode 100644 index 0000000..f6dab90 --- /dev/null +++ b/vendor/plugins/globalize2/test/data/models.rb @@ -0,0 +1,29 @@ +class Post < ActiveRecord::Base + translates :subject, :content + validates_presence_of :subject +end + +class Blog < ActiveRecord::Base + has_many :posts, :order => 'id ASC' +end + +class Parent < ActiveRecord::Base + translates :content +end + +class Child < Parent +end + +class Comment < ActiveRecord::Base + validates_presence_of :content + belongs_to :post +end + +class TranslatedComment < Comment + translates :content +end + +class UltraLongModelNameWithoutProper < ActiveRecord::Base + translates :subject, :content + validates_presence_of :subject +end \ No newline at end of file diff --git a/vendor/plugins/globalize2/test/data/no_globalize_schema.rb b/vendor/plugins/globalize2/test/data/no_globalize_schema.rb index 7cfaf69..379455d 100644 --- a/vendor/plugins/globalize2/test/data/no_globalize_schema.rb +++ b/vendor/plugins/globalize2/test/data/no_globalize_schema.rb @@ -1,5 +1,5 @@ # This schema creates tables without columns for the translated fields -ActiveRecord::Schema.define do +ActiveRecord::Schema.define do create_table :blogs, :force => true do |t| t.string :name end @@ -8,4 +8,4 @@ ActiveRecord::Schema.define do t.references :blog end end - + diff --git a/vendor/plugins/globalize2/test/data/post.rb b/vendor/plugins/globalize2/test/data/post.rb deleted file mode 100644 index 6673dc4..0000000 --- a/vendor/plugins/globalize2/test/data/post.rb +++ /dev/null @@ -1,24 +0,0 @@ -class Post < ActiveRecord::Base - translates :subject, :content - validates_presence_of :subject -end - -class Blog < ActiveRecord::Base - has_many :posts, :order => 'id ASC' -end - -class Parent < ActiveRecord::Base - translates :content -end - -class Child < Parent -end - -class Comment < ActiveRecord::Base - validates_presence_of :content - belongs_to :post -end - -class TranslatedComment < Comment - translates :content -end \ No newline at end of file -- cgit v1.3