Store MongoDB Credentials as Environment Variables fails

Hi, I don’t want to have user and pass of db hard coded in srv URI link in my Java springboot app. So I put user and pass in my env variables(IDE Intellij):


and have this URI in my file: = {DB_USERNAME} = {DB_PASSWORD}{DB_USERNAME}:{DB_PASSWORD}

but my test with this URI failsm while it works perfectly fine with the user and pass hard coded in URI.

Any help and idea how to resolve this issue?