在 STS 中单独运行 jhipster 测试用例

时间:2021-05-11 11:37:39

标签: java spring-boot junit jhipster

我使用 jhipster 创建了一个 spring-boot 应用程序并在 Spring Studio Tool 中打开。

要在我单击任何测试文件并作为 JUnit 运行时运行 Junit 案例,它会在 JUnit 的控制台窗口中显示 DEBUG : [onnection adder] org.postgresql.ssl.MakeSSL : converting regular socket connection to ssl 显示 Runs 0/0 ,Errors 0, Failures 0

我如何在 Jhipster 中运行每个测试用例。我写的测试用例如下

      @Test
      public void saveApplication() throws Exception {
      restMockMvc.perform(post("/api/application")
                  .contentType(MediaType.APPLICATION_JSON)
                  .content(asJsonString(App)))
                  .andExpect(status().isOk());
      }

当 liquibase 锁错误出现时,junit 只显示 Run 1/21 , failed 1 。

0 个答案:

没有答案