Мы используем @SpringBootTest
с атрибутом @Autowired private MockMvc mockMvc
для макетирования HTTP-запросов к нашим классам контроллеров.
По какой-то причине, которую мы не можем определить, это создает огромное количество журналированиядля каждого теста и заполняет наши журналы тысяч строк текста, который выглядит следующим образом:
build 18-May-2019 03:09:40 Async:
build 18-May-2019 03:09:40 Async started = false
build 18-May-2019 03:09:40 Async result = null
build 18-May-2019 03:09:40
build 18-May-2019 03:09:40 Resolved Exception:
build 18-May-2019 03:09:40 Type = null
build 18-May-2019 03:09:40
build 18-May-2019 03:09:40 ModelAndView:
build 18-May-2019 03:09:40 View name = null
build 18-May-2019 03:09:40 View = null
build 18-May-2019 03:09:40 Model = null
build 18-May-2019 03:09:40
build 18-May-2019 03:09:40 FlashMap:
build 18-May-2019 03:09:40 Attributes = null
build 18-May-2019 03:09:40
build 18-May-2019 03:09:40 MockHttpServletResponse:
build 18-May-2019 03:09:40 Status = 200
build 18-May-2019 03:09:40 Error message = null
build 18-May-2019 03:09:40 Headers = {X-Content-Type-Options=[nosniff], X-XSS-Protection=[1; mode=block], Cache-Control=[no-cache, no-store, max-age=0, must-revalidate], Pragma=[no-cache], Expires=[0], X-Frame-Options=[DENY]}
build 18-May-2019 03:09:40 Content type = null
build 18-May-2019 03:09:40 Body =
build 18-May-2019 03:09:40 Forwarded URL = null
build 18-May-2019 03:09:40 Redirected URL = null
build 18-May-2019 03:09:40 Cookies = []
build 18-May-2019 03:09:40
build 18-May-2019 03:09:40 MockHttpServletRequest:
build 18-May-2019 03:09:40 HTTP Method = POST
build 18-May-2019 03:09:40 Request URI = /api/v1/certification/applications
build 18-May-2019 03:09:40 Parameters = {}
build 18-May-2019 03:09:40 Headers = {Content-Type=[application/json;charset=UTF-8]}
build 18-May-2019 03:09:40 Body = {"applicationVersion":"1.0"}
build 18-May-2019 03:09:40 Session Attrs = {}
build 18-May-2019 03:09:40
build 18-May-2019 03:09:40 Handler:
build 18-May-2019 03:09:40 Type = <redacted>
build 18-May-2019 03:09:40 Method = <redacted>
build 18-May-2019 03:09:40
build 18-May-2019 03:09:40 Async:
build 18-May-2019 03:09:40 Async started = false
build 18-May-2019 03:09:40 Async result = null
build 18-May-2019 03:09:40
build 18-May-2019 03:09:40 Resolved Exception:
build 18-May-2019 03:09:40 Type = null
build 18-May-2019 03:09:40
build 18-May-2019 03:09:40 ModelAndView:
build 18-May-2019 03:09:40 View name = null
build 18-May-2019 03:09:40 View = null
build 18-May-2019 03:09:40 Model = null
build 18-May-2019 03:09:40
build 18-May-2019 03:09:40 FlashMap:
build 18-May-2019 03:09:40 Attributes = null
build 18-May-2019 03:09:40
build 18-May-2019 03:09:40 MockHttpServletResponse:
build 18-May-2019 03:09:40 Status = 200
build 18-May-2019 03:09:40 Error message = null
build 18-May-2019 03:09:40 Headers = {X-Content-Type-Options=[nosniff], X-XSS-Protection=[1; mode=block], Cache-Control=[no-cache, no-store, max-age=0, must-revalidate], Pragma=[no-cache], Expires=[0], X-Frame-Options=[DENY]}
build 18-May-2019 03:09:40 Content type = null
build 18-May-2019 03:09:40 Body =
build 18-May-2019 03:09:40 Forwarded URL = null
build 18-May-2019 03:09:40 Redirected URL = null
build 18-May-2019 03:09:40 Cookies = []
Весь мой поиск в Интернете и чтение документации Spring Boot Test были бесплодными. Откуда взялась эта запись и как мы можем ее отключить?
Мы тщательно отсканировали наш код и уверены, что не печатаем / не несем за него ответственность.