Ich versuche, den iDialog Fluss mit einer gefälschten Nachricht zu testen, so:Microsoft.Rest.HttpOperationException in Microsoft.Bot.Builder.dll ("Zugriff verweigert"), während PromptDialog.Confirm Prüfung
var toBot = new Message()
{
ConversationId = Guid.NewGuid().ToString(),
Text = "Test",
};
Func<IDialog<T>> MakeRoot =() => testDialog;
toBot.From = new ChannelAccount(Guid.NewGuid().ToString());
toBot.To = new ChannelAccount(Guid.NewGuid().ToString());
Wenn Wenn es den PromptDialog.Confirm trifft, wird die Ausnahme "Microsoft.Rest.HttpOperationException in Microsoft.Bot.Builder.dll (" Zugriff verweigert ") ausgelöst.
Wenn ich nicht schaffen
toBot.From = new ChannelAccount(Guid.NewGuid().ToString());
es wirft System.NullReferenceException für KanalId.
PromptDialog.Confirm sieht aus wie:
PromptDialog.Confirm(context, AfterErrorConfirmationAsync, Strings.ConfirmError,
Strings.InvalidInput);
Wie kann ich dieses Problem umgehen?