GitLab security master is broken: create_test_failure_issues_spec.rb
There are some failures on create_test_failure_issues_spec
:
Failures:
1) CreateTestFailureIssues CreateTestFailureIssue#upsert when no issues are found calls CreateIssue#execute(payload)
Failure/Error: creator.upsert(failed_test)
#<Double "CreateIssue"> received :execute with unexpected arguments
expected: ({:description=>"### Test description\n\n`The test description`\n\n### Test file path\n\n[`spec/path/t..."wip-group::source_code"], :title=>"spec/path/to/file_spec.rb [test-hash:c5aa3a544982]", :weight=>1})
got: ({:description=>"### Test description\n\n`The test description`\n\n### Test file path\n\n[`spec/path/t..."wip-group::source_code"], :title=>"spec/path/to/file_spec.rb [test-hash:c5aa3a544982]", :weight=>1})
Diff:
@@ -1,5 +1,5 @@
[{:description=>
- "### Test description\n\n`The test description`\n\n### Test file path\n\n[`spec/path/to/file_spec.rb`](https://gitlab.com/gitlab-org/gitlab/-/blob/master/spec/path/to/file_spec.rb)\n\n<!-- Don't add anything after the report list since it's updated automatically -->\n### Reports (1)\n\n1. 2023-03-27: https://gitlab.com/gitlab-org/gitlab/-/jobs/1234 (https://gitlab.com/gitlab-org/gitlab/-/pipelines/5678)\n",
+ "### Test description\n\n`The test description`\n\n### Test file path\n\n[`spec/path/to/file_spec.rb`](https://gitlab.com/gitlab-org/security/gitlab/-/blob/master/spec/path/to/file_spec.rb)\n\n<!-- Don't add anything after the report list since it's updated automatically -->\n### Reports (1)\n\n1. 2023-03-27: https://gitlab.com/gitlab-org/gitlab/-/jobs/1234 (https://gitlab.com/gitlab-org/gitlab/-/pipelines/5678)\n",
:labels=>
["wip-type::maintenance",
"wip-test",
# ./scripts/pipeline/create_test_failure_issues.rb:128:in `create'
# ./scripts/pipeline/create_test_failure_issues.rb:73:in `upsert'
# ./spec/scripts/pipeline/create_test_failure_issues_spec.rb:138:in `block (5 levels) in <main>'
# ./spec/scripts/pipeline/create_test_failure_issues_spec.rb:67:in `block (4 levels) in <main>'
# ./spec/scripts/pipeline/create_test_failure_issues_spec.rb:67:in `block (3 levels) in <main>'
# ./spec/spec_helper.rb:464:in `block (3 levels) in <top (required)>'
# ./spec/support/sidekiq_middleware.rb:18:in `with_sidekiq_server_middleware'
# ./spec/spec_helper.rb:456:in `block (2 levels) in <top (required)>'
# ./spec/spec_helper.rb:452:in `block (3 levels) in <top (required)>'
# ./lib/gitlab/application_context.rb:61:in `with_raw_context'
# ./spec/spec_helper.rb:452:in `block (2 levels) in <top (required)>'
# ./spec/spec_helper.rb:240:in `block (2 levels) in <top (required)>'
# ./spec/support/system_exit_detected.rb:7:in `block (2 levels) in <main>'
# ./spec/support/database/prevent_cross_joins.rb:108:in `block (3 levels) in <main>'
# ./spec/support/database/prevent_cross_joins.rb:62:in `with_cross_joins_prevented'
# ./spec/support/database/prevent_cross_joins.rb:108:in `block (2 levels) in <main>'
2) CreateTestFailureIssues CreateTestFailureIssue#upsert when issues are found when issue already has the latest format behaves like existing issue update calls UpdateIssue#execute(payload)
Failure/Error: creator.upsert(failed_test)
#<Double "UpdateIssue"> received :execute with unexpected arguments
expected: (42, {:description=>"### Test description\n\n`The test description`\n\n### Test file path\n\n[`spec/path/t.../gitlab-org/gitlab/-/jobs/1234 (https://gitlab.com/gitlab-org/gitlab/-/pipelines/5678)", :weight=>2})
got: (42, {:description=>"### Test description\n\n`The test description`\n\n### Test file path\n\n[`spec/path/t.../gitlab-org/gitlab/-/jobs/1234 (https://gitlab.com/gitlab-org/gitlab/-/pipelines/5678)", :weight=>1})
Shared Example Group: "existing issue update" called from ./spec/scripts/pipeline/create_test_failure_issues_spec.rb:198
# ./scripts/pipeline/create_test_failure_issues.rb:112:in `update_reports'
# ./scripts/pipeline/create_test_failure_issues.rb:70:in `upsert'
# ./spec/scripts/pipeline/create_test_failure_issues_spec.rb:190:in `block (6 levels) in <main>'
# ./spec/scripts/pipeline/create_test_failure_issues_spec.rb:67:in `block (4 levels) in <main>'
# ./spec/scripts/pipeline/create_test_failure_issues_spec.rb:67:in `block (3 levels) in <main>'
# ./spec/spec_helper.rb:464:in `block (3 levels) in <top (required)>'
# ./spec/support/sidekiq_middleware.rb:18:in `with_sidekiq_server_middleware'
# ./spec/spec_helper.rb:456:in `block (2 levels) in <top (required)>'
# ./spec/spec_helper.rb:452:in `block (3 levels) in <top (required)>'
# ./lib/gitlab/application_context.rb:61:in `with_raw_context'
# ./spec/spec_helper.rb:452:in `block (2 levels) in <top (required)>'
# ./spec/spec_helper.rb:240:in `block (2 levels) in <top (required)>'
# ./spec/support/system_exit_detected.rb:7:in `block (2 levels) in <main>'
# ./spec/support/database/prevent_cross_joins.rb:108:in `block (3 levels) in <main>'
# ./spec/support/database/prevent_cross_joins.rb:62:in `with_cross_joins_prevented'
# ./spec/support/database/prevent_cross_joins.rb:108:in `block (2 levels) in <main>'
Finished in 3.88 seconds (files took 51.81 seconds to load)
2 examples, 2 failures
Failed examples:
rspec ./spec/scripts/pipeline/create_test_failure_issues_spec.rb:133 # CreateTestFailureIssues CreateTestFailureIssue#upsert when no issues are found calls CreateIssue#execute(payload)
rspec ./spec/scripts/pipeline/create_test_failure_issues_spec.rb:185 # CreateTestFailureIssues CreateTestFailureIssue#upsert when issues are found when issue already has the latest format behaves like existing issue update calls UpdateIssue#execute(payload)