[Rails5] Flash has wrong value
Note: add
rails5
to a branch name to trigger rails5 specific CI jobs.
https://gitlab.com/gitlab-org/gitlab-ce/-/jobs/75037718
Failures:
1) Projects::ImportsController GET #show when repository exists when import is in progress renders template
Failure/Error: expect(response).to render_template :show
expecting <"show"> but rendering with <["errors/access_denied", "layouts/errors"]>
# ./spec/controllers/projects/imports_controller_spec.rb:38:in `block (5 levels) in <top (required)>'
2) Projects::ImportsController GET #show when repository exists when import is in progress sets flash.now if params is present
Failure/Error: expect(flash.now[:notice]).to eq 'In progress'
expected: "In progress"
got: nil
(compared using ==)
# ./spec/controllers/projects/imports_controller_spec.rb:44:in `block (5 levels) in <top (required)>'
3) Projects::ImportsController GET #show when repository exists when import failed redirects to new_namespace_project_import_path
Failure/Error: expect(response).to redirect_to new_project_import_path(project)
Expected response to be a <3XX: redirect>, but was a <404: Not Found>
# ./spec/controllers/projects/imports_controller_spec.rb:56:in `block (5 levels) in <top (required)>'
4) Projects::ImportsController GET #show when repository exists when import finished when project is a fork redirects to namespace_project_path
Failure/Error: expect(flash[:notice]).to eq 'The project was successfully forked.'
expected: "The project was successfully forked."
got: nil
(compared using ==)
# ./spec/controllers/projects/imports_controller_spec.rb:71:in `block (6 levels) in <top (required)>'
5) Projects::ImportsController GET #show when repository exists when import finished when project is external redirects to namespace_project_path
Failure/Error: expect(flash[:notice]).to eq 'The project was successfully imported.'
expected: "The project was successfully imported."
got: nil
(compared using ==)
# ./spec/controllers/projects/imports_controller_spec.rb:80:in `block (6 levels) in <top (required)>'
6) Projects::ImportsController GET #show when repository exists when import finished when continue params is present redirects to internal params[:to]
Failure/Error: expect(flash[:notice]).to eq params[:notice]
expected: "Finished"
got: nil
(compared using ==)
# ./spec/controllers/projects/imports_controller_spec.rb:96:in `block (6 levels) in <top (required)>'
Finished in 7 minutes 40 seconds (files took 15.56 seconds to load)
1412 examples, 6 failures