Patch #32921

Rails 6: add header=present to csv tests

Added by Pavel Rosický 9 months ago. Updated 8 months ago.

Status:NewStart date:
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:Rails support
Target version:5.0.0

Description

fixes

Failure:
IssuesControllerTest#test_index_csv_with_all_columns [/redmine/test/functional/issues_controller_test.rb:878]:
Expected: "text/csv" 
  Actual: "text/csv; header=present" 

csvheaders.patch Magnifier (8.12 KB) Pavel Rosický, 2020-01-29 23:06

csvheaders2.patch Magnifier - reverts test_index_send_nothing_if_query_is_invalid (7.9 KB) Pavel Rosický, 2020-01-29 23:12

0001-Rails-6-add-header-present-to-csv-tests.patch Magnifier (9.39 KB) Marius BALTEANU, 2020-01-31 14:54


Related issues

Related to Redmine - Feature #29914: Migrate to Rails 6 New

History

#1 Updated by Pavel Rosický 9 months ago

#2 Updated by Marius BALTEANU 9 months ago

#3 Updated by Marius BALTEANU 9 months ago

Pavel, maybe you have a clue because I can't find or understand why media_type returns "text/csv; header=present" and not only text/csv as is explained here.

#4 Updated by Pavel Rosický 9 months ago

yeah, because the documentation is obsolete, it was changed here https://github.com/rails/rails/pull/37017

#5 Updated by Marius BALTEANU 9 months ago

Pavel Rosický wrote:

yeah, because the documentation is obsolete, it was changed here https://github.com/rails/rails/pull/37017

Thanks, it's clear now. Your patches look good to me and the failing tests because of this are passing now. I'm attaching a merged version of your patches.

#6 Updated by Go MAEDA 8 months ago

  • Category set to Rails support

Also available in: Atom PDF