Update README.md

This commit is contained in:
Serdar Dogruyol 2016-11-05 01:05:09 +02:00 committed by GitHub
parent 11157d2484
commit 6df7caca0a

View file

@ -44,12 +44,14 @@ Kemal.run
Now you can easily test your `Kemal` application in your `spec`s. Now you can easily test your `Kemal` application in your `spec`s.
```
KEMAL_ENV=test crystal spec
```
```crystal ```crystal
# spec/your-kemal-app-spec.cr # spec/your-kemal-app-spec.cr
describe "Your::Kemal::App" do describe "Your::Kemal::App" do
# Be sure to start your app in test mode
start
# You can use get,post,put,patch,delete to call the corresponding route. # You can use get,post,put,patch,delete to call the corresponding route.
it "renders /" do it "renders /" do
@ -57,8 +59,6 @@ describe "Your::Kemal::App" do
response.body.should eq "Hello World!" response.body.should eq "Hello World!"
end end
# Be sure to stop your app after the specs
stop
end end
``` ```