mirror of
https://github.com/discourse/discourse.git
synced 2025-05-23 23:31:18 +08:00
DEV: Correct syntax_tree violations
This commit is contained in:
@ -58,18 +58,12 @@ RSpec.describe ImportScripts::Base do
|
||||
describe "#create_post" do
|
||||
let(:importer) { described_class.new }
|
||||
fab!(:user) { Fabricate(:user) }
|
||||
let(:post_params) {
|
||||
{
|
||||
user_id: user.id,
|
||||
raw: "Test post [b]content[/b]",
|
||||
title: "Test topic for post"
|
||||
}
|
||||
}
|
||||
let(:post_params) do
|
||||
{ user_id: user.id, raw: "Test post [b]content[/b]", title: "Test topic for post" }
|
||||
end
|
||||
|
||||
it "creates a Post" do
|
||||
expect {
|
||||
importer.create_post(post_params, 123)
|
||||
}.to change { Post.count }.by(1)
|
||||
expect { importer.create_post(post_params, 123) }.to change { Post.count }.by(1)
|
||||
end
|
||||
|
||||
if ENV["IMPORT"] == "1"
|
||||
|
Reference in New Issue
Block a user