ResultNotNull()
checks to see if the object passed in is not null. If the object and message are not null it will then simply return the object that was passed in, otherwise it will throw InvalidOperationException
.
return Assert.ResultNotNull(this.Database.GetItem(this.ItemRootId), string.Concat("Root item not found. ID: ", this.ItemRootId));