File obs-server-2.10-0128-Fix-garbage-component-at-end-of-elements.patch of Package obs-server

From b27eaff622da9b3ad8e26d64673c7eb5ea977130 Mon Sep 17 00:00:00 2001
From: Henne Vogelsang <hvogel@opensuse.org>
Date: Tue, 13 Apr 2021 15:58:14 +0200
Subject: [PATCH] Fix garbage component at end of elements

---
 src/api/test/functional/source_controller_test.rb | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/api/test/functional/source_controller_test.rb b/src/api/test/functional/source_controller_test.rb
index a646dd6109..4f8bff9f1d 100644
--- a/src/api/test/functional/source_controller_test.rb
+++ b/src/api/test/functional/source_controller_test.rb
@@ -2621,10 +2621,10 @@ class SourceControllerTest < ActionDispatch::IntegrationTest
     assert_response :success
     orig_project_meta = @response.body
     doc = REXML::Document.new(@response.body)
-    person = doc.elements["/project'"].add_element 'person'
+    person = doc.elements['/project'].add_element 'person'
     person.add_attribute(REXML::Attribute.new('userid', 'adrian'))
     person.add_attribute(REXML::Attribute.new('role', 'maintainer'))
-    rt = doc.elements["/project/repository'"].add_element 'releasetarget'
+    rt = doc.elements['/project/repository'].add_element 'releasetarget'
     rt.add_attribute(REXML::Attribute.new('project', 'home:adrian:RT'))
     rt.add_attribute(REXML::Attribute.new('repository', 'rt'))
     put '/source/home:Iggy/_meta', params: doc.to_s
@@ -2731,7 +2731,7 @@ class SourceControllerTest < ActionDispatch::IntegrationTest
     assert_response :success
     orig_project_meta = @response.body
     doc = REXML::Document.new(@response.body)
-    rt = doc.elements["/project/repository'"].add_element 'releasetarget'
+    rt = doc.elements['/project/repository'].add_element 'releasetarget'
     rt.add_attribute(REXML::Attribute.new('project', 'home:adrian:RT'))
     rt.add_attribute(REXML::Attribute.new('repository', 'rt'))
     put '/source/home:Iggy/_meta', params: doc.to_s
@@ -2852,7 +2852,7 @@ class SourceControllerTest < ActionDispatch::IntegrationTest
     assert_response :success
     orig_project_meta = @response.body
     doc = REXML::Document.new(@response.body)
-    rt = doc.elements["/project/repository'"].add_element 'releasetarget'
+    rt = doc.elements['/project/repository'].add_element 'releasetarget'
     rt.add_attribute(REXML::Attribute.new('project', 'home:adrian:RT'))
     rt.add_attribute(REXML::Attribute.new('repository', 'rt'))
     put '/source/home:Iggy/_meta', params: doc.to_s
-- 
2.31.1