Update README.md
This commit is contained in:
parent
f64aa9099b
commit
b4d7512ca5
1 changed files with 15 additions and 1 deletions
16
README.md
16
README.md
|
@ -28,7 +28,21 @@ require "spec-kemal"
|
||||||
require "../src/your-kemal-app"
|
require "../src/your-kemal-app"
|
||||||
```
|
```
|
||||||
|
|
||||||
Now you can access your `Kemal` application in your `spec`s.
|
Your Kemal application
|
||||||
|
|
||||||
|
```crystal
|
||||||
|
# src/your-kemal-app.cr
|
||||||
|
|
||||||
|
require "kemal"
|
||||||
|
|
||||||
|
get "/" do
|
||||||
|
"Hello World!"
|
||||||
|
end
|
||||||
|
|
||||||
|
Kemal.run
|
||||||
|
```
|
||||||
|
|
||||||
|
Now you can easily test your `Kemal` application in your `spec`s.
|
||||||
|
|
||||||
```crystal
|
```crystal
|
||||||
# spec/your-kemal-app-spec.cr
|
# spec/your-kemal-app-spec.cr
|
||||||
|
|
Loading…
Reference in a new issue