private void EmailDomainChanged(EmailDomainChanged message) { this.BotState.Team.EmailDomain = message.EmailDomain; }
public void HandlesValidEmailDomainChanged() { var team = new TeamData { EmailDomain = "team.com" }; var mockState = new Mock<IBotState>(); mockState.Setup(s => s.Team).Returns(team).Verifiable(); var message = new EmailDomainChanged { Type = EventType.EmailDomainChanged, EmailDomain = "team2.com" }; RunHandler(message, mockState); Assert.Equal("team2.com", team.EmailDomain); }