public void When_a_type_cannot_be_resolved_via_GetRequiredService_it_throws() { var container = new PocketContainer() as ISupportRequiredService; Action resolve = () => container.GetRequiredService(typeof(string)); resolve.ShouldThrow <ArgumentException>(); }