aboutsummaryrefslogtreecommitdiffstats
path: root/guides/source/testing.md
diff options
context:
space:
mode:
authoryuuji.yaginuma <yuuji.yaginuma@gmail.com>2016-07-16 10:56:28 +0900
committeryuuji.yaginuma <yuuji.yaginuma@gmail.com>2016-07-16 10:56:28 +0900
commit777ae60ddf9e9e2863bdc0a496922ef0d3f5d756 (patch)
tree59cd93b8a08cc28056d7ea9f49ea0bee9ed69f01 /guides/source/testing.md
parent4f567d8d45b025ddef73263321f7f404128ca231 (diff)
downloadrails-777ae60ddf9e9e2863bdc0a496922ef0d3f5d756.tar.gz
rails-777ae60ddf9e9e2863bdc0a496922ef0d3f5d756.tar.bz2
rails-777ae60ddf9e9e2863bdc0a496922ef0d3f5d756.zip
add missing braces [ci skip]
Also modify to use Ruby 1.9+ syntax.
Diffstat (limited to 'guides/source/testing.md')
-rw-r--r--guides/source/testing.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/guides/source/testing.md b/guides/source/testing.md
index 440d87bf73..26d50bec0c 100644
--- a/guides/source/testing.md
+++ b/guides/source/testing.md
@@ -879,10 +879,10 @@ can be passed as headers:
```ruby
# setting an HTTP Header
-get articles_url, headers: "Content-Type" => "text/plain" # simulate the request with custom header
+get articles_url, headers: { "Content-Type": "text/plain" } # simulate the request with custom header
# setting a CGI variable
-get articles_url, headers: "HTTP_REFERER" => "http://example.com/home" # simulate the request with custom env variable
+get articles_url, headers: { "HTTP_REFERER": "http://example.com/home" } # simulate the request with custom env variable
```
### Testing `flash` notices