public async Task Then_Ukprn_Is_Required_To_Get_Provider_Permissions() { //Act try { await _providerPermissionsService.GetTrustedEmployers(default(uint)); } catch (Exception) { //Swallow exception as we test for this in a different test }; //Assert _providerRelationsApiClient.Verify(c => c.GetAccountProviderLegalEntitiesWithPermission( It.IsAny <GetAccountProviderLegalEntitiesWithPermissionRequest>(), It.IsAny <CancellationToken>()), Times.Never); Assert.ThrowsAsync <ArgumentException>(() => _providerPermissionsService.GetTrustedEmployers(default(uint))); }