A lightweight, extensible, open-source, and cross-platform version of the Entity Framework data access technology.
Above is my code. How do I write test methods as per above code?
The official documentation covers unit testing asp.net Core controllers.
Unit test controller logic in ASP.NET Core
You might consider using HttpRepl to test Web API. This is an integration test because you're actually making HTTP requests. The advantage is you are also testing the actual service implementation rather than a mock.
Test web APIs with the HttpRepl
I have already researched regarding the same but not did not get relevant material.
You have to understand, the community has no idea what you have researched or tried. You must write a mock implementation for the injected services. Did you do this? Can you show us what you've tried?