Esempio n. 1
0
    public void RemoveStrike()
    {
        var mock = new Mock <IStrikeData>(MockBehavior.Strict);

        mock.Setup(x => x.RemoveStrike(1, 2));
        var guildService = new StrikeService(mock.Object);

        guildService.RemoveStrike(1, 2);

        mock.Verify(x => x.RemoveStrike(1, 2), Times.Exactly(1));
    }
Esempio n. 2
0
 public ActionResult RemoveStrike(ulong guildId, [FromBody] StrikeId strikeId)
 {
     _strikeService.RemoveStrike(guildId, strikeId.Id);
     return(Ok($"Strike id: {strikeId.Id} was removed"));
 }