While running the connection test case, I am getting this error

java.lang.AssertionError: Check your connection string 

at org.junit.Assert.failNotEquals(Assert.java:834)
	at org.junit.Assert.assertEquals(Assert.java:645)
	at mflix.api.daos.ConnectionTest.testMoviesCount(ConnectionTest.java:44)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
	at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
	at org.springframework.test.context.junit4.statements.RunBeforeTestExecutionCallbacks.evaluate(RunBeforeTestExecutionCallbacks.java:73)

Hi :wave: @Ira_Sheikh,

Welcome to the MongoDB University forums :sparkles:

Have you put the srv string in the src/main/resources/application.properties file of the mflix app?

If yes, then there might be some issue with the formatting of the connection string. Could you please share the screenshot of the application.properties file and your srv string with us?

It will help us to identify the issue.

Thanks,
Kushagra

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.