From 6c5f73b241d3b31123fbbc61cc4acf76adae8d5e Mon Sep 17 00:00:00 2001 From: Miquel Sabaté Solà Date: Mon, 18 Mar 2024 22:20:23 +0100 Subject: thing: removed unique index on title MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Miquel Sabaté Solà --- test/models/thing_test.rb | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'test/models/thing_test.rb') diff --git a/test/models/thing_test.rb b/test/models/thing_test.rb index 766a5e2..ef2a1e2 100644 --- a/test/models/thing_test.rb +++ b/test/models/thing_test.rb @@ -60,18 +60,12 @@ class ThingTest < ActiveSupport::TestCase thing.save! end - test 'title and target must be unique' do + test 'target must be unique' do thing = things(:thing1).dup - thing.title = 'another' assert_raise(ActiveRecord::RecordInvalid) { thing.save! } thing.target = 'also another' - thing.title = things(:thing1).title - assert_raise(ActiveRecord::RecordInvalid) { thing.save! } - - thing.target = 'also another' - thing.title = 'now for real' assert_difference('Thing.count') { thing.save! } end -- cgit v1.2.3