Sha256: 18e79af40cb660ee968bf79b4e9e97ae5768cebca304b7b9d9e57a9f3570a636
Contents?: true
Size: 583 Bytes
Versions: 2
Compression:
Stored size: 583 Bytes
Contents
RSpec.describe 'ROM.container' do include_context 'database setup' with_adapters do let(:rom) do ROM.container(:sql, uri) do |conf| conf.default.create_table(:dragons) do primary_key :id column :name, String end conf.relation(:dragons) do schema(infer: true) end end end after do rom.gateways[:default].connection.drop_table(:dragons) end it 'creates tables within the setup block' do expect(rom.relations[:dragons]).to be_kind_of(ROM::SQL::Relation) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
rom-sql-2.0.0.beta2 | spec/integration/setup_spec.rb |
rom-sql-2.0.0.beta1 | spec/integration/setup_spec.rb |