0
0
Fork 0

Autofix Rubocop RSpec/LeadingSubject (#23670)

This commit is contained in:
Nick Schonning 2023-02-19 23:24:14 -05:00 committed by GitHub
parent 4ea1e0fceb
commit 4552685f6b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
78 changed files with 256 additions and 338 deletions

View file

@ -2,10 +2,10 @@ require 'rails_helper'
RSpec.describe CustomEmoji, type: :model do
describe '#search' do
let(:custom_emoji) { Fabricate(:custom_emoji, shortcode: shortcode) }
subject { described_class.search(search_term) }
let(:custom_emoji) { Fabricate(:custom_emoji, shortcode: shortcode) }
context 'shortcode is exact' do
let(:shortcode) { 'blobpats' }
let(:search_term) { 'blobpats' }
@ -26,10 +26,10 @@ RSpec.describe CustomEmoji, type: :model do
end
describe '#local?' do
let(:custom_emoji) { Fabricate(:custom_emoji, domain: domain) }
subject { custom_emoji.local? }
let(:custom_emoji) { Fabricate(:custom_emoji, domain: domain) }
context 'domain is nil' do
let(:domain) { nil }
@ -55,10 +55,10 @@ RSpec.describe CustomEmoji, type: :model do
end
describe '.from_text' do
let!(:emojo) { Fabricate(:custom_emoji) }
subject { described_class.from_text(text, nil) }
let!(:emojo) { Fabricate(:custom_emoji) }
context 'with plain text' do
let(:text) { 'Hello :coolcat:' }