Exemplo n.º 1
0
        private static async Task SetSnapshotMode(RepositoryDatabase database, RepositoryInfo repository)
        {
            repository.RepositoryMode = RepositoryMode.Snapshot;

            await database.UpsertReplace(repository).ConfigureAwait(false);

            var repo = await database.GetRepositoryById(repository.Id).ConfigureAwait(false);

            repo.Should().BeEquivalentTo(repository);
            repo.RepositoryMode.Should().Be(RepositoryMode.Snapshot);
        }