Sha256: 4adb6d43bf79a391bb35b57776d3bff99d1bbb073ae1094625c0aea207ccba4a

Contents?: true

Size: 1.17 KB

Versions: 3

Compression:

Stored size: 1.17 KB

Contents

# typed: strict
# frozen_string_literal: true

TABLE_SCHEMA = T.let(lambda do |t|
  t.string :topic
  t.text :body
  t.references :received_messageable, polymorphic: true, index: false
  t.references :sent_messageable, polymorphic: true, index: false
  t.boolean :opened, default: false
  t.boolean :recipient_delete, default: false
  t.boolean :sender_delete, default: false
  t.boolean :recipient_permanent_delete, default: false
  t.boolean :sender_permanent_delete, default: false
  t.datetime :opened_at, :datetime
  t.string :ancestry
  t.timestamps
end, T.untyped)

TABLE_SCHEMA_UUID = T.let(lambda do |t|
  t.string :topic
  t.text :body
  t.references :received_messageable, polymorphic: true, index: false, type: :uuid
  t.references :sent_messageable, polymorphic: true, index: false, type: :uuid
  t.boolean :opened, default: false
  t.boolean :recipient_delete, default: false
  t.boolean :sender_delete, default: false
  t.boolean :recipient_permanent_delete, default: false
  t.boolean :sender_permanent_delete, default: false
  t.datetime :opened_at, :datetime
  t.string :ancestry
  t.timestamps
end, T.untyped)

USER_SCHEMA = T.let(lambda do |t|
  t.string :email
end, T.untyped)

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
acts-as-messageable-1.0.2 spec/support/table_schema.rb
acts-as-messageable-1.0.1 spec/support/table_schema.rb
acts-as-messageable-1.0.0 spec/support/table_schema.rb