Fixed: nzb.su URL changed to api.nzb.su

This commit is contained in:
Mark McDowall 2014-03-16 22:32:39 -07:00
parent 0a5ed41270
commit 87f591dfbd
3 changed files with 34 additions and 0 deletions

View File

@ -253,5 +253,22 @@ namespace NzbDrone.Core.Test.Download
VerifyNoFailedDownloads();
}
[Test]
public void should_not_process_if_failed_due_to_lack_of_disk_space()
{
var history = Builder<History.History>.CreateListOfSize(1)
.Build()
.ToList();
GivenGrabbedHistory(history);
GivenFailedDownloadClientHistory();
_failed.First().Message = "Unpacking failed, write error or disk is full?";
Subject.Execute(new CheckForFailedDownloadCommand());
VerifyNoFailedDownloads();
}
}
}

View File

@ -0,0 +1,16 @@
using FluentMigrator;
using NzbDrone.Core.Datastore.Migration.Framework;
namespace NzbDrone.Core.Datastore.Migration
{
[Migration(46)]
public class fix_nzb_su_url : NzbDroneMigrationBase
{
protected override void MainDbUpgrade()
{
Execute.Sql("UPDATE Indexers SET Settings = replace(Settings, '//nzb.su', '//api.nzb.su')" +
"WHERE Implementation = 'Newznab'" +
"AND Settings LIKE '%//nzb.su%'");
}
}
}

View File

@ -191,6 +191,7 @@
<Compile Include="Datastore\Migration\044_fix_xbmc_episode_metadata.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="Datastore\Migration\046_fix_nzb_su_url.cs" />
<Compile Include="Datastore\Migration\Framework\MigrationContext.cs" />
<Compile Include="Datastore\Migration\Framework\MigrationController.cs" />
<Compile Include="Datastore\Migration\Framework\MigrationExtension.cs" />