Sha256: 5959bef1053743bd75e47c802550d58f4a923a2852c66df630d11e3a913f53b6
Contents?: true
Size: 413 Bytes
Versions: 5
Compression:
Stored size: 413 Bytes
Contents
# frozen_string_literal: true RSpec.describe RuboCop::Cop::Sequel::PartialConstraint do include Spec::Helpers::Migration subject(:cop) { described_class.new } it 'registers an offense when using where for constraint' do offenses = inspect_source_within_migration(<<~RUBY) add_unique_constraint %i[col_1 col_2], where: "state != 'deleted'" RUBY expect(offenses.size).to eq(1) end end
Version data entries
5 entries across 5 versions & 1 rubygems