Example #1
0
        public async Task ManageHealthChecksAsync()
        {
            await _registry.RegisterHealthCheckAsync(nameof(ManageHealthChecksAsync), nameof(ManageHealthChecksAsync), new Uri("http://localhost"));

            await _host.Received().RegisterHealthCheckAsync(nameof(ManageHealthChecksAsync), nameof(ManageHealthChecksAsync), new Uri("http://localhost"));

            await _registry.DeregisterHealthCheckAsync(nameof(ManageHealthChecksAsync));

            await _host.Received().DeregisterHealthCheckAsync(nameof(ManageHealthChecksAsync));

            await _registry.AddHealthCheckAsync(nameof(ManageHealthChecksAsync), nameof(ManageHealthChecksAsync), new Uri("http://localhost"));

            await _host.Received().RegisterHealthCheckAsync(nameof(ManageHealthChecksAsync), nameof(ManageHealthChecksAsync), new Uri("http://localhost"));
        }