Beispiel #1
0
        public async Task UpdatePatch_WhenCurrentPatchIsLive_ReturnsWithoutUpdating()
        {
            _mockGameRepository.Setup(_ => _.LoadLivePatch()).ReturnsAsync(new Patch
            {
                Major   = 9,
                Minor   = 8,
                Version = 1
            });
            _mockRestClient.Setup(_ => _.GetAsync <Realm>("realms/na.json")).ReturnsAsync(new Realm
            {
                V = "9.8.1"
            });

            var result = await _target.UpdatePatch();

            Assert.IsFalse(result.Updated);
        }
Beispiel #2
0
        public async Task Run([TimerTrigger("0 0 6 * * *")] TimerInfo timer, ILogger log)
        {
            var patch = await _patchPipeline.UpdatePatch();

            log.LogInformation($"Patch Updated: {patch.Updated}, Current Live Patch: {patch.Version}");
        }