Exemplo n.º 1
0
        public void raises_concurrency_issue()
        {
            var aggregate = new SimpleEventSourcedRoot();
            var result    = aggregate.Must().HaveVersion(1);

            result.Should().BeInvalid().WithMessage(ConcurrencyIssue.VersionMismatch(1, 0));
        }
Exemplo n.º 2
0
        public void guards_expected_version()
        {
            var aggregate = new SimpleEventSourcedRoot();
            var result    = aggregate.Must().HaveVersion(0);

            result.Should().BeValid().WithoutMessages();
        }