diff --git a/Gemfile b/Gemfile
index b0940cdbebf123849e8280bac9f4742eb1e27882..50ced52d09bbf79bdc14f397ec4a8a808c734cd6 100644
--- a/Gemfile
+++ b/Gemfile
@@ -205,7 +205,7 @@ gem 'asciidoctor-plantuml', '~> 0.0.16'
 gem 'asciidoctor-kroki', '~> 0.8.0', require: false
 gem 'rouge', '~> 4.1.2'
 gem 'truncato', '~> 0.7.12'
-gem 'nokogiri', '~> 1.15', '>= 1.15.2'
+gem 'nokogiri', '~> 1.15', '>= 1.15.3'
 
 # Calendar rendering
 gem 'icalendar'
diff --git a/Gemfile.checksum b/Gemfile.checksum
index 4de6c3c7092fabc76af78f77fef88def9abe1c99..54a2b80b5a35b2f705639a7718286733a4406e31 100644
--- a/Gemfile.checksum
+++ b/Gemfile.checksum
@@ -392,17 +392,17 @@
 {"name":"nio4r","version":"2.5.8","platform":"java","checksum":"b2b1800f6bf7ce4b797ca8b639ad278a99c9c904fb087a91d944f38e4bd71401"},
 {"name":"nio4r","version":"2.5.8","platform":"ruby","checksum":"3becb4ad95ab8ac0a9bd2e1b16466869402be62848082bf6329ae9091f276676"},
 {"name":"no_proxy_fix","version":"0.1.2","platform":"ruby","checksum":"4e9b4c31bb146de7fcf347dc1087bb13ac2039b56d50aa019e61036256abcd00"},
-{"name":"nokogiri","version":"1.15.2","platform":"aarch64-linux","checksum":"497c698f0cc0f283934c9c93064249d113408e97e5f3677b0b5111af24a67c29"},
-{"name":"nokogiri","version":"1.15.2","platform":"arm-linux","checksum":"505ad4b80cedd12bc3c53065079cc825e7f3d4094ca7b54176ae6f3734dbe2cc"},
-{"name":"nokogiri","version":"1.15.2","platform":"arm64-darwin","checksum":"bbedeaf45ce1494f51806e5fab0d31816fc4584f8e2ec757dd516b9b30847ee4"},
-{"name":"nokogiri","version":"1.15.2","platform":"java","checksum":"b15ba3c1aa5b3726d7aceb44f635250653467c5b0d04248fa0f6a6afc6515fb0"},
-{"name":"nokogiri","version":"1.15.2","platform":"ruby","checksum":"20dc800b8fbe4c4f4b5b164e6aa3ab82a371bcb27eb685c166961c34dd8a22d7"},
-{"name":"nokogiri","version":"1.15.2","platform":"x64-mingw-ucrt","checksum":"bc3cc9631c9dd7a74a59554215474da657f956ccb126391d082a2a8c45d3ee14"},
-{"name":"nokogiri","version":"1.15.2","platform":"x64-mingw32","checksum":"1fd27732b161a497275798e502b31e97dfe1ab58aac02c0d6ace9cbe1fd6a38c"},
-{"name":"nokogiri","version":"1.15.2","platform":"x86-linux","checksum":"931383c6351d79903149b5c6a988e88daada59d7069f3a01b4dcf6730d411cc6"},
-{"name":"nokogiri","version":"1.15.2","platform":"x86-mingw32","checksum":"3f4a6350ca1d87d185f4bf509d953820c7191d1cf4213cc3bac9c492b9b4a720"},
-{"name":"nokogiri","version":"1.15.2","platform":"x86_64-darwin","checksum":"b57eeec09ee1c4010e317f50d2897fb9c1133d02598260db229e81127b337930"},
-{"name":"nokogiri","version":"1.15.2","platform":"x86_64-linux","checksum":"5bca696b9283ad7ce97b9c0dfdf029a62c26e92f39f440a65795e377d44f119a"},
+{"name":"nokogiri","version":"1.15.3","platform":"aarch64-linux","checksum":"70dadf636ae026f475f07c16b12c685544d4f8a764777df629abf1f7af0f2fb5"},
+{"name":"nokogiri","version":"1.15.3","platform":"arm-linux","checksum":"83871fa3f544dc601e27abbdef87315a77fe1270fe4904986bd3a7df9ca3d56f"},
+{"name":"nokogiri","version":"1.15.3","platform":"arm64-darwin","checksum":"fa4a027478df9004a2ce91389af7b7b5a4fc790c23492dca43b210a0f8770596"},
+{"name":"nokogiri","version":"1.15.3","platform":"java","checksum":"95d410f995364d9780c4147d8fca6974447a1ccd3a1e1b092f0408836a36cc9c"},
+{"name":"nokogiri","version":"1.15.3","platform":"ruby","checksum":"876631295a85315dac37e7a71386d62d9eb452a891083cfe7505cca4805088cb"},
+{"name":"nokogiri","version":"1.15.3","platform":"x64-mingw-ucrt","checksum":"599a46b6e4f5a34dd21da06bdbd69611728304af5ef42bb183e4b4ca073fd7a3"},
+{"name":"nokogiri","version":"1.15.3","platform":"x64-mingw32","checksum":"92ebfb637c9b7ba92a221b49ea3328c7e5ee79a28307d75ef55bfe4b5807face"},
+{"name":"nokogiri","version":"1.15.3","platform":"x86-linux","checksum":"ee314666eca832fa71b5bb4c090be46a80aded857aa26121b3b51f3ed658a646"},
+{"name":"nokogiri","version":"1.15.3","platform":"x86-mingw32","checksum":"44b7f18817894a5b697bab3d757b12bb7857a0218c1b2e0000929456a2178b34"},
+{"name":"nokogiri","version":"1.15.3","platform":"x86_64-darwin","checksum":"1f0bc0343f9dd1db8dd42e4c9110dd24fc11a7f923b9fa0f866e7f90739e4e7a"},
+{"name":"nokogiri","version":"1.15.3","platform":"x86_64-linux","checksum":"ca244ed58568d7265088f83c568d2947102fb00bac14b5bc0e63f678dcd6323d"},
 {"name":"notiffany","version":"0.1.3","platform":"ruby","checksum":"d37669605b7f8dcb04e004e6373e2a780b98c776f8eb503ac9578557d7808738"},
 {"name":"numerizer","version":"0.2.0","platform":"ruby","checksum":"e58076d5ee5370417b7e52d9cb25836d62acd1b8d9a194c308707986c1705d7b"},
 {"name":"oauth","version":"0.5.6","platform":"ruby","checksum":"4085fe28e0c5e2434135e00a6555294fd2a4ff96a98d1bdecdcd619fc6368dff"},
diff --git a/Gemfile.lock b/Gemfile.lock
index 7dfd585e9396aa83280b51e42335e52fa2e7559d..a5c6a44172c407fca58d7bd514ed64485a57961f 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1059,7 +1059,7 @@ GEM
     netrc (0.11.0)
     nio4r (2.5.8)
     no_proxy_fix (0.1.2)
-    nokogiri (1.15.2)
+    nokogiri (1.15.3)
       mini_portile2 (~> 2.8.2)
       racc (~> 1.4)
     notiffany (0.1.3)
@@ -1902,7 +1902,7 @@ DEPENDENCIES
   net-ldap (~> 0.17.1)
   net-ntp
   net-protocol (~> 0.1.3)
-  nokogiri (~> 1.15, >= 1.15.2)
+  nokogiri (~> 1.15, >= 1.15.3)
   oauth2 (~> 2.0)
   octokit (~> 4.15)
   ohai (~> 17.9)
diff --git a/spec/helpers/markup_helper_spec.rb b/spec/helpers/markup_helper_spec.rb
index 562d6683d97295497f14f9ead8f5fcd6819e19dd..22d1113ee8cae11c009d3d30e21b36430020aa9f 100644
--- a/spec/helpers/markup_helper_spec.rb
+++ b/spec/helpers/markup_helper_spec.rb
@@ -2,7 +2,7 @@
 
 require 'spec_helper'
 
-RSpec.describe MarkupHelper do
+RSpec.describe MarkupHelper, feature_category: :team_planning do
   let_it_be(:project) { create(:project, :repository) }
   let_it_be(:user) do
     user = create(:user, username: 'gfm')
@@ -461,7 +461,7 @@
 
       it 'displays the first line of a code block' do
         object = create_object("```\nCode block\nwith two lines\n```")
-        expected = %r{<pre.+><code><span class="line">Code block\.\.\.</span>\n</code></pre>}
+        expected = %r{<pre.+><code><span class="line">Code block\.\.\.</span></code></pre>}
 
         expect(helper.first_line_in_markdown(object, attribute, 100, is_todo: true, project: project)).to match(expected)
       end
@@ -477,7 +477,7 @@
       it 'preserves code color scheme' do
         object = create_object("```ruby\ndef test\n  'hello world'\nend\n```")
         expected = "\n<pre class=\"code highlight js-syntax-highlight language-ruby\">" \
-          "<code><span class=\"line\"><span class=\"k\">def</span> <span class=\"nf\">test</span>...</span>\n" \
+          "<code><span class=\"line\"><span class=\"k\">def</span> <span class=\"nf\">test</span>...</span>" \
           "</code></pre>\n"
 
         expect(helper.first_line_in_markdown(object, attribute, 150, is_todo: true, project: project)).to eq(expected)
diff --git a/spec/lib/banzai/filter/truncate_visible_filter_spec.rb b/spec/lib/banzai/filter/truncate_visible_filter_spec.rb
index 0d3528506827115afae70b4347c2b27dbae2b1b0..d55d54f766d8ecdf8147a6adb0eea8f4b5cbe258 100644
--- a/spec/lib/banzai/filter/truncate_visible_filter_spec.rb
+++ b/spec/lib/banzai/filter/truncate_visible_filter_spec.rb
@@ -44,7 +44,7 @@ def convert_markdown(text, context = {})
 
   describe 'truncates the first line of a code block' do
     let(:markdown) { "```\nCode block\nwith two lines\n```" }
-    let(:expected) { "Code block...</span>\n</code>" }
+    let(:expected) { "Code block...</span></code>" }
 
     it_behaves_like 'truncates text'
   end