aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/schema/schema.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activerecord/test/schema/schema.rb')
-rw-r--r--activerecord/test/schema/schema.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/activerecord/test/schema/schema.rb b/activerecord/test/schema/schema.rb
index ddfc1ac0d6..0fb2c6269f 100644
--- a/activerecord/test/schema/schema.rb
+++ b/activerecord/test/schema/schema.rb
@@ -17,6 +17,15 @@ ActiveRecord::Schema.define do
ActiveRecord::Base.connection.create_table(*args, &block)
ActiveRecord::Base.connection.execute "SET GENERATOR #{args.first}_seq TO 10000"
end
+ when "PostgreSQL"
+ enable_uuid_ossp!(ActiveRecord::Base.connection)
+ create_table :uuid_parents, id: :uuid, force: true do |t|
+ t.string :name
+ end
+ create_table :uuid_children, id: :uuid, force: true do |t|
+ t.string :name
+ t.uuid :uuid_parent_id
+ end
end