Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-10-24 00:12:16 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-10-24 00:12:16 +0300
commita0686b4653208e66c768b63e249bd73406f9e267 (patch)
tree4df20a2bac7ff9057e60e022b34aad42cfd73dc0 /spec/lib/api
parentc5da163db1c10676b1a01a898b7b3a4506e65b89 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/lib/api')
-rw-r--r--spec/lib/api/entities/wiki_page_spec.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/spec/lib/api/entities/wiki_page_spec.rb b/spec/lib/api/entities/wiki_page_spec.rb
index a3566293c5c..da75ade997b 100644
--- a/spec/lib/api/entities/wiki_page_spec.rb
+++ b/spec/lib/api/entities/wiki_page_spec.rb
@@ -24,7 +24,7 @@ RSpec.describe API::Entities::WikiPage do
context "with front matter content" do
let(:wiki_page) { create(:wiki_page) }
- let(:content_with_front_matter) { "---\nxxx: abc\n---\nHome Page" }
+ let(:content_with_front_matter) { "---\ntitle: abc\n---\nHome Page" }
before do
wiki_page.update(content: content_with_front_matter) # rubocop:disable Rails/SaveBang
@@ -33,6 +33,10 @@ RSpec.describe API::Entities::WikiPage do
it 'returns the raw wiki page content' do
expect(subject[:content]).to eq content_with_front_matter
end
+
+ it 'return the front matter title' do
+ expect(subject[:front_matter]).to eq({ title: "abc" })
+ end
end
context 'when render_html param is passed' do