dave1
❔ How to bugfix this issue of Ambigious call when it's pointing to the same package
infrastructure/Program.cs(50,18): error CS0121: The call is ambiguous between the following methods or properties: 'Microsoft.Extensions.DependencyInjection.MediatorDependencyInjectionExtensions.AddMediator(Microsoft.Extensions.DependencyInjection.IServiceCollection, System.Action<Mediator.MediatorOptions>)' and 'Microsoft.Extensions.DependencyInjection.MediatorDependencyInjectionExtensions.AddMediator(Microsoft.Extensions.DependencyInjection.IServiceCollection, System.Action<Mediator.MediatorOptions>)'
4 replies
Registering IDbCommand and autowiring and testing
i've registered the following
i now want to change that in my CustomWebApplicationFactory like..
but doing this the 'regions' table cannot be found, i'd presume it's not registering it correctly.
When not swapping the implementation, it finds my local db with my local appsettings connection string
the table does exist because i'm also registering AppDbContext with entity framework(and those tests are passing, i'm currently converting everything to repositories)
3 replies
❔ how to run a test to test an endpoint and to check in the database that the data been stored
I dont know what the correct way is to do this in aspnet, or if this is how it is done in .net
I want to basically post to an endpointz
, say /blog
Check for a 201 response then check it has been stored in the database.
40 replies