DEV: Apply syntax_tree formatting to plugins/*

This commit is contained in:
David Taylor
2023-01-06 20:42:16 +00:00
parent 93e2dad656
commit 055310cea4
110 changed files with 3712 additions and 3158 deletions

View File

@ -2,24 +2,21 @@
RSpec.describe DiscourseNarrativeBot::CertificateGenerator do
let(:user) { Fabricate(:user) }
let(:avatar_url) { 'http://test.localhost/cdn/avatar.png' }
let(:avatar_url) { "http://test.localhost/cdn/avatar.png" }
let(:date) { "2017-00-10" }
describe 'when an invalid date is given' do
it 'should default to the current date' do
describe "when an invalid date is given" do
it "should default to the current date" do
expect { described_class.new(user, date, avatar_url) }.to_not raise_error
end
end
describe '#logo_group' do
describe 'when SiteSetting.site_logo_small_url is blank' do
before do
SiteSetting.logo_small = ''
end
describe "#logo_group" do
describe "when SiteSetting.site_logo_small_url is blank" do
before { SiteSetting.logo_small = "" }
it 'should not try to fetch a image' do
expect(described_class.new(user, date, avatar_url).send(:logo_group, 1, 1, 1))
.to eq(nil)
it "should not try to fetch a image" do
expect(described_class.new(user, date, avatar_url).send(:logo_group, 1, 1, 1)).to eq(nil)
end
end
end