Open Closed

Can't perform a new Unit Test Code #9275

collexe created

Deat support team,

I am writing a new unit test code on the platform, however, hitting the below issue saying Service 'Microsoft.AspNetCore.Hosting.IWebHostEnvironment' which was not registered,

below is the screenshot,

Kindly advise further and appreciate for the prompt response, thank you.

Regards Alvin T

1 Answer(s)
  • 0
    maliming created
    Support Team


    You can do Mock IWebHostEnvironment in unit tests