From 3523eb63945acbe16a78b320690ea8b3b333fa84 Mon Sep 17 00:00:00 2001 From: ta264 Date: Tue, 12 Jan 2021 21:27:03 +0000 Subject: [PATCH] Fix freeleech tests --- .../IndexerTests/GazelleTests/GazelleFixture.cs | 2 +- .../IndexerTests/RedactedTests/RedactedFixture.cs | 2 +- src/NzbDrone.Core/Indexers/Redacted/RedactedParser.cs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/NzbDrone.Core.Test/IndexerTests/GazelleTests/GazelleFixture.cs b/src/NzbDrone.Core.Test/IndexerTests/GazelleTests/GazelleFixture.cs index 43b50b102..c1d254b96 100644 --- a/src/NzbDrone.Core.Test/IndexerTests/GazelleTests/GazelleFixture.cs +++ b/src/NzbDrone.Core.Test/IndexerTests/GazelleTests/GazelleFixture.cs @@ -55,7 +55,7 @@ namespace NzbDrone.Core.Test.IndexerTests.GazelleTests releaseInfo.Title.Should().Be("Shania Twain - Shania Twain (1993) [FLAC 24bit Lossless] [WEB]"); releaseInfo.DownloadProtocol.Should().Be(DownloadProtocol.Torrent); releaseInfo.DownloadUrl.Should() - .Be("http://someurl.ch/torrents.php?action=download&id=1541452&authkey=redacted&torrent_pass=redacted"); + .Be("http://someurl.ch/torrents.php?action=download&id=1541452&authkey=redacted&torrent_pass=redacted&usetoken=0"); releaseInfo.InfoUrl.Should().Be("http://someurl.ch/torrents.php?id=106951&torrentid=1541452"); releaseInfo.CommentUrl.Should().Be(null); releaseInfo.Indexer.Should().Be(Subject.Definition.Name); diff --git a/src/NzbDrone.Core.Test/IndexerTests/RedactedTests/RedactedFixture.cs b/src/NzbDrone.Core.Test/IndexerTests/RedactedTests/RedactedFixture.cs index d17eb3e61..68da49f7c 100644 --- a/src/NzbDrone.Core.Test/IndexerTests/RedactedTests/RedactedFixture.cs +++ b/src/NzbDrone.Core.Test/IndexerTests/RedactedTests/RedactedFixture.cs @@ -54,7 +54,7 @@ namespace NzbDrone.Core.Test.IndexerTests.GazelleTests releaseInfo.Title.Should().Be("Shania Twain - Shania Twain (1993) [FLAC 24bit Lossless] [WEB]"); releaseInfo.DownloadProtocol.Should().Be(DownloadProtocol.Torrent); releaseInfo.DownloadUrl.Should() - .Be("https://redacted.ch/torrents.php?action=download&id=1541452&authkey=lidarr&torrent_pass=redacted"); + .Be("https://redacted.ch/torrents.php?action=download&id=1541452&authkey=lidarr&torrent_pass=redacted&usetoken=0"); releaseInfo.InfoUrl.Should().Be("https://redacted.ch/torrents.php?id=106951&torrentid=1541452"); releaseInfo.CommentUrl.Should().Be(null); releaseInfo.Indexer.Should().Be(Subject.Definition.Name); diff --git a/src/NzbDrone.Core/Indexers/Redacted/RedactedParser.cs b/src/NzbDrone.Core/Indexers/Redacted/RedactedParser.cs index 67b824a33..a3d1311af 100644 --- a/src/NzbDrone.Core/Indexers/Redacted/RedactedParser.cs +++ b/src/NzbDrone.Core/Indexers/Redacted/RedactedParser.cs @@ -95,7 +95,7 @@ namespace NzbDrone.Core.Indexers.Redacted .AddQueryParam("id", torrentId) .AddQueryParam("authkey", "lidarr") .AddQueryParam("torrent_pass", _settings.PassKey) - .AddQueryParam("usetoken", _settings.UseFreeleechToken); + .AddQueryParam("usetoken", _settings.UseFreeleechToken ? 1 : 0); return url.FullUri; }