From c46cd1bd0440d9d33c194320e459b01d2f274dc7 Mon Sep 17 00:00:00 2001 From: Jamie Wilson Date: Thu, 5 Jan 2023 18:05:17 -0500 Subject: [PATCH] DEV: Specify slug name during Category fabrication --- spec/fabricators/category_fabricator.rb | 1 - spec/serializers/reviewable_score_serializer_spec.rb | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/spec/fabricators/category_fabricator.rb b/spec/fabricators/category_fabricator.rb index 3793bb118ee..0e14967af41 100644 --- a/spec/fabricators/category_fabricator.rb +++ b/spec/fabricators/category_fabricator.rb @@ -2,7 +2,6 @@ Fabricator(:category) do name { sequence(:name) { |n| "Amazing Category #{n}" } } - slug { sequence(:slug) { |n| "amazing-category-#{n}" } } skip_category_definition true user end diff --git a/spec/serializers/reviewable_score_serializer_spec.rb b/spec/serializers/reviewable_score_serializer_spec.rb index 4b58979493f..2894db4e87b 100644 --- a/spec/serializers/reviewable_score_serializer_spec.rb +++ b/spec/serializers/reviewable_score_serializer_spec.rb @@ -15,7 +15,7 @@ RSpec.describe ReviewableScoreSerializer do end it 'adds a link for category settings' do - category = Fabricate.build(:category) + category = Fabricate(:category, name: 'Reviewable Category', slug: 'reviewable-category') reviewable.category = category serialized = serialized_score('category') link_url = "#{Discourse.base_url}/c/#{category.slug}/edit/settings"