Sonar Scan & Test Coverage - Overall Summary
- Go 1.24, gocover-cobertura, SonarQube
go build
go test -v
go run main.go
./shopping-cart-go
curl -X POST -H "Content-Type: application/json" -d '{"id":1,"name":"Laptop","price":999.99}' http://localhost:8080/add
{"id":1,"name":"Laptop","price":999.99}
curl -X POST -H "Content-Type: application/json" -d '{"id":2,"name":"basketball","price":77.99}' http://localhost:8080/add
{"id":2,"name":"basketball","price":77.99}
curl http://localhost:8080/cart
[{"id":1,"name":"Laptop","price":999.99},{"id":2,"name":"basketball","price":77.99}]