Commit 44b4dfbf authored by Chloe Liu's avatar Chloe Liu

Merge branch 'ml-update-delete-test-users' into 'master'

Update test user delete task and test user name

See merge request gitlab-org/gitlab!82162
parents ff84aced 6e67e185
......@@ -4,7 +4,7 @@ module QA
RSpec.describe 'Plan', :reliable do
let!(:user) do
Resource::User.fabricate_via_api! do |user|
user.name = "eve <img src=x onerror=alert(2)&lt;img src=x onerror=alert(1)&gt;"
user.name = "QA User <img src=x onerror=alert(2)&lt;img src=x onerror=alert(1)&gt;"
user.password = "test1234"
user.api_client = Runtime::API::Client.as_admin
end
......
......@@ -53,6 +53,11 @@ module QA
# When we reach the last page, the x-next-page header is a blank string
@page_no = response.headers[:x_next_page].to_s
if @page_no.to_i > 1000
puts "Finishing early to avoid timing out the CI job"
exit
end
JSON.parse(response.body).select do |user|
user['username'].start_with?('qa-user-', 'test-user-') \
&& (user['name'] == 'QA Tests' || user['name'].start_with?('QA User')) \
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment