public void ForceSnapshotTest() { var snapshotId = "testFixtureId"; Fixture fixture = GetSnapshotWithMarkets(snapshotId); _resource.Setup(x => x.Id).Returns(snapshotId); _resource.Setup(x => x.Content).Returns(new Summary()); _resource.Setup(x => x.MatchStatus).Returns(MatchStatus.InRunning); _resource.Setup(x => x.GetSnapshot()).Returns(FixtureJsonHelper.ToJson(fixture)); _supervisor.CreateStreamListener(_resource.Object, _plugin.Object); _supervisor.ForceSnapshot(fixture.Id); _supervisor.ForceSnapshot(fixture.Id); //inital snapshot + 2 forced snapshots = 3 _resource.Verify(x => x.GetSnapshot(), Times.Exactly(3)); _plugin.Verify(x => x.ProcessSnapshot(It.Is<Fixture>(f => f.Markets.Count == 1), It.IsAny<bool>()), Times.Exactly(3)); }