【问题标题】:How to disable security feature for Unit testing in Spring Webflux如何在 Spring Webflux 中禁用单元测试的安全功能
【发布时间】:2019-06-03 20:28:57
【问题描述】:

我的Unit tests are passed 已经。在我使用JWT token 添加安全性后,通过的单元测试是failed 安全功能的cos。我想disable security features 进行单元测试。我不想rewrite所有的测试用例。

我可以disable the security features 进行单元测试吗?

我用Spring Boot 2.1.1WebfluxRouterFunction代替了控制器。

【问题讨论】:

    标签: unit-testing spring-boot spring-webflux


    【解决方案1】:

    我不知道这是否是最佳解决方案。我生成了unexpired token 并在我的单元测试用例中使用了它。

    【讨论】:

      猜你喜欢
      • 2020-08-12
      • 2015-09-19
      • 1970-01-01
      • 2019-03-30
      • 2015-11-14
      • 1970-01-01
      • 2021-05-06
      • 2019-01-20
      • 2019-01-20
      相关资源
      最近更新 更多