From 07d20f7cf0f4333b8fa6445b2b333dd2dfcc95cc Mon Sep 17 00:00:00 2001 From: evazion Date: Fri, 17 Nov 2017 12:14:37 -0600 Subject: [PATCH] Add test for `category -> type` bulk update requests. --- test/unit/bulk_update_request_test.rb | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/test/unit/bulk_update_request_test.rb b/test/unit/bulk_update_request_test.rb index e30019c78..929cb2fc5 100644 --- a/test/unit/bulk_update_request_test.rb +++ b/test/unit/bulk_update_request_test.rb @@ -95,6 +95,16 @@ class BulkUpdateRequestTest < ActiveSupport::TestCase end end + context "for a `category -> type` change" do + should "work" do + tag = Tag.find_or_create_by_name("tagme") + bur = FactoryGirl.create(:bulk_update_request, :script => "category tagme -> meta") + bur.approve!(@admin) + + assert_equal(Tag.categories.meta, tag.reload.category) + end + end + context "with an associated forum topic" do setup do @topic = FactoryGirl.create(:forum_topic, :title => "[bulk] hoge")