Akka.Tests.Actor.LocalActorRefProviderSpec.An_ActorRefFactory_must_throw_suitable_exceptions_for_malformed_actor_names C# (CSharp) Method

An_ActorRefFactory_must_throw_suitable_exceptions_for_malformed_actor_names() private method

private An_ActorRefFactory_must_throw_suitable_exceptions_for_malformed_actor_names ( string name, string expectedExceptionMessageSubstring ) : void
name string
expectedExceptionMessageSubstring string
return void
        public void An_ActorRefFactory_must_throw_suitable_exceptions_for_malformed_actor_names(string name, string expectedExceptionMessageSubstring)
        {
            var exception = Assert.Throws<InvalidActorNameException>(() =>
                {
                    Sys.ActorOf(Props.Empty, name);
                });
            Assert.Contains(expectedExceptionMessageSubstring, exception.Message, StringComparison.InvariantCultureIgnoreCase);
        }