Пример #1
0
        public async Task Should_Not_Send_Webhook_If_There_Is_No_Subscription_Async()
        {
            await CreateTenantAndSubscribeToWebhookAsync(AppWebhookDefinitionNames.Users.Created,
                                                         AppFeatures.WebhookFeature, "true");

            AbpSession.TenantId = GetDefaultTenant().Id;

            await _webhookPublisher.PublishAsync(AppWebhookDefinitionNames.Test,
                                                 new
            {
                Name    = "Musa",
                Surname = "Demir"
            });

            await _backgroundJobManagerSubstitute.DidNotReceive().EnqueueAsync <WebhookSenderJob, WebhookSenderArgs>(Arg.Any <WebhookSenderArgs>());
        }