集成测试ReactiveNeo4J

问题描述

亲爱的, 我对实施全栈集成测试(从Web层到存储库层)进行测试有点困惑,以测试我的创建/删除/更新操作是否按预期进行。 我对测试整个流程更感兴趣,而不仅仅是测试存储库层。 为了执行这些测试,我们决定与另一个数据库进行交互,创建一些节点(使用夹具whatsover)并删除它。

Neo4j似乎可以创建适合此目标的嵌入式数据库,并提供一个不错的批注@ ReactiveDataNeo4jTest,如果仅测试存储库层,则可以正常工作。

我正在尝试在遵循此“模板”的测试版本中使用它:

@RunWith(SpringJUnit4ClassRunner.class)
@AutoConfigureWebTestClient(timeout = "60000")
@ReactiveDataNeo4jTest
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
@BootstrapWith(SpringBootTestContextBootstrapper.class)
public class EntityControllerIntegrationTest

我得到的异常如下:

Unable to start ServletWebServerApplicationContext due to missing ServletWebServerFactory bean.

我尝试在不同时间删除/添加/更改不同的注释仍会得到不同的错误(重复的@Bootstrap注释,没有自动连接WebTestClient。)。

想法? 我喜欢这种方法,这似乎可行并且很适合我的情况,但是以某种方式我无法使用它。

想法?

谢谢 FB

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)

相关问答

错误1:Request method ‘DELETE‘ not supported 错误还原:...
错误1:启动docker镜像时报错:Error response from daemon:...
错误1:private field ‘xxx‘ is never assigned 按Alt...
报错如下,通过源不能下载,最后警告pip需升级版本 Requirem...