因为Springboot采用rest风格,但在测试时候只能测试GetMapping,像Delet,post等不能直接测试,此时就可以用Swagger来测试。
另外Swagger可以采用注解方式告诉改接口干什么用。