Fixed: Branch redirects will now occur during install of the a new update instead of during an update check.

This commit is contained in:
Taloth Saldono
2015-01-25 22:21:17 +01:00
parent 7ce9f416d1
commit 2f06cc6ffa
3 changed files with 33 additions and 15 deletions

View File

@@ -1,4 +1,5 @@
using System;
using System.Collections.Generic;
using System.IO;
using FluentAssertions;
using Moq;
@@ -294,6 +295,17 @@ namespace NzbDrone.Core.Test.UpdateTests
ExceptionVerification.ExpectedErrors(1);
}
[Test]
public void should_switch_to_branch_specified_in_updatepackage()
{
_updatePackage.Branch = "fake";
Subject.Execute(new InstallUpdateCommand() { UpdatePackage = _updatePackage });
Mocker.GetMock<IConfigFileProvider>()
.Verify(v => v.SaveConfigDictionary(It.Is<Dictionary<string, object>>(d => d.ContainsKey("Branch") && (string)d["Branch"] == "fake")), Times.Once());
}
[TearDown]
public void TearDown()
{