1
0
Fork 0
mirror of https://github.com/middleman/middleman.git synced 2022-11-09 12:20:27 -05:00
middleman--middleman/middleman-core/features/encoding_option.feature
Paul McMahon 4fe0732713
Cleanup of how fixtures customize a fixture (#2342)
* Use "Given" instead of "And" as first scenario step

* Remove unnecessary step

The following step already invokes this step

* Remove setup in feature that doesn't do anything

As this referenced "i18n-test-app", but later we run
"i18n-mixed-sources", these steps weren't doing anything.

* Avoid referencing the same fixture twice

The step "the Server is running at" invokes the "a fixture app" step,
followed by "the Server is running" step.
2020-06-15 11:19:39 -07:00

27 lines
912 B
Gherkin

# encoding: iso-8859-1
Feature: encoding option
Scenario: No encoding set
Given the Server is running at "clean-app"
When I go to "/index.html"
Then the "Content-Type" header should contain "text/html"
Then the "Content-Type" header should contain "charset=utf-8"
@wip
Scenario: Custom encoding set
Given a fixture app "i-8859-1-app"
And a file named "config.rb" with:
"""
set :encoding, "ISO-8859-1"
::Rack::Mime::MIME_TYPES['.html'] = 'text/html; charset=iso-8859-1'
::Rack::Mime::MIME_TYPES['.htm'] = 'text/html; charset=iso-8859-1'
::Rack::Mime::MIME_TYPES['.map'] = 'application/json; charset=iso-8859-1'
"""
Given the Server is running
When I go to "/index.html"
Then the "Content-Type" header should contain "text/html"
Then the "Content-Type" header should contain "charset=iso-8859-1"
Then I should see "äöü"