Commit d8fc4dbc authored by Jakub Balga's avatar Jakub Balga
Browse files

REST testing manual

parent 77e4ec8f
Pipeline #139593 passed with stages
in 2 minutes and 43 seconds
......@@ -2,7 +2,7 @@
PA165 course at MUNI Spring 2022.
# Build, Run Tests, and Launch the Web Application
# Build and Run Tests
Assuming you are in the root directory of this project:
```bash
......@@ -19,7 +19,20 @@ Password: `admin`
E-mail: `user@winery.com`
Password: `user`
# About the Project
# How to test the REST API
- Download Insomnia or similar tool for sending HTTP requests
- Run the application (no need of login, REST API is there only for demonstration purposes)
- Get all grapes: GET http://localhost:8080/pa165/rest/grape
- Get grape with id 2: GET http://localhost:8080/pa165/rest/grape/2
- Create new variety Chardonnay: POST http://localhost:8080/pa165/rest/grape/create; body of request: {"name":"Chardonnay"}
- Change Pálava to Hibernal: POST http://localhost:8080/pa165/rest/grape/edit; body of request: {"id":1,"name":"Hibernal"}
- Delete Tramín červený: DELETE http://localhost:8080/pa165/rest/grape/delete; body of request: {"id":2,"name":"Tramín červený"}
- POST and DELETE requests does not return, inspect content of grape database by the first command
# About Project
- **Name**: Winery Management System
- **Technologies**: Java 11, Spring, Hibernate, Maven
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment