Browse Source

Remove unused UT

pull/150/head
gdlcf88 4 years ago
parent
commit
cca7d89a24
  1. 21
      plugins/Booking/test/EasyAbp.EShop.Plugins.Booking.Application.Tests/Authorization/BookingPaymentCreationAuthorizationHandlersTests.cs

21
plugins/Booking/test/EasyAbp.EShop.Plugins.Booking.Application.Tests/Authorization/BookingPaymentCreationAuthorizationHandlersTests.cs

@ -30,27 +30,6 @@ public class BookingPaymentCreationAuthorizationHandlersTests : BookingApplicati
context.HasFailed.ShouldBeFalse();
}
[Fact]
public async Task Should_Failed_If_ProductAsset_Mapping_Not_Exists()
{
var productAssetRepository = ServiceProvider.GetRequiredService<IProductAssetRepository>();
var productAsset = await productAssetRepository.GetAsync(x =>
x.AssetId == BookingTestConsts.Asset1Id && x.ProductId == BookingTestConsts.BookingProduct1Id);
await productAssetRepository.DeleteAsync(productAsset, true);
var handler = ServiceProvider.GetRequiredService<BookingPaymentCreationAuthorizationHandler>();
var context = await CreateAuthorizationHandlerContextAsync();
await handler.HandleAsync(context);
context.HasFailed.ShouldBeFalse();
await productAssetRepository.InsertAsync(productAsset, true);
}
private Task<AuthorizationHandlerContext> CreateAuthorizationHandlerContextAsync()
{
var orderLine1 = new OrderLineDto

Loading…
Cancel
Save