public void CloudQueueClientGetServiceStats() { AssertSecondaryEndpoint(); CloudQueueClient client = GenerateCloudQueueClient(); client.DefaultRequestOptions.LocationMode = LocationMode.SecondaryOnly; TestHelper.VerifyServiceStats(client.GetServiceStats()); }
public void CloudQueueClientGetServiceStatsInvalidLoc() { CloudQueueClient client = GenerateCloudQueueClient(); client.DefaultRequestOptions.LocationMode = LocationMode.PrimaryOnly; try { client.GetServiceStats(); Assert.Fail("GetServiceStats should fail and throw an InvalidOperationException."); } catch (Exception e) { Assert.IsInstanceOfType(e, typeof(InvalidOperationException)); } }