Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/carloshenriquefs/tdd-event-city

:white_check_mark: - Desafio TDD Event City
https://github.com/carloshenriquefs/tdd-event-city

java tdd testes

Last synced: about 1 month ago
JSON representation

:white_check_mark: - Desafio TDD Event City

Awesome Lists containing this project

README

        

# :construction: - Desafio: TDD-Event-City

* Desenvolvimento TDD de API Rest com Java e Spring Boot;
* Implementação de cenários de busca, inserção, deleção e atualização;
* Tratamento de exceções em API com respostas HTTP customizadas;

##

## :clipboard: - Diagramas:

![tdd drawio](https://github.com/carloshenriquefs/tdd-event-city/assets/54969405/3105cb1b-5bc1-4965-84d9-39f292da0e6d)

![seed drawio](https://github.com/carloshenriquefs/tdd-event-city/assets/54969405/ab837811-3290-465d-80b3-f1261732ea13)

##

## :gear: - Endpoint's:

#### :house: - City:

``GET:``

* findById(id){}

* findAllName(){}

``POST:``

* insert(){}

``DELETE:``

* delete(id){}

##

#### :microphone: - Event:

``PUT:``

* update(id){}

##

## :hourglass: - Tests:

#### :house: - City:

- findAllShouldReturnAllResourcesSortedByName(){}
- insertShouldInsertResource(){}
- deleteShouldReturnNoContentWhenIndependentId(){}
- deleteShouldReturnNotFoundWhenNonExistingId(){}

##

#### :microphone: - Event:

- updateShouldUpdateResourceWhenIdExists(){}
- updateShouldReturnNotFoundWhenIdDoesNotExists(){}

##

### :white_check_mark: - Critérios:

##

- [x] - DELETE /cities/{id} deve retornar 404 Not Found quando id não existir;
- [x] - DELETE /cities/{id} deve retornar 204 No Content quando id for independente;
- [x] - DELETE /cities/{id} deve retornar 400 Bad Request quando id for dependente;
- [x] - POST /cities deve inserir recurso;
- [x] - GET /cities deve retornar recursos ordenados por nome;
- [x] - PUT /events deve atualizar recurso quando id existir;
- [x] - PUT /events deve retornar 404 Not Found quando id não existir;