Files
Prowlarr/src/NzbDrone.Core.Test/MetadataSource/SkyHook/SkyHookProxySearchFixture.cs
T
Leonardo Galli 7cfa0531dc Fixed all tests and even added some new ones :) (#835)
* First fixing of tests.

* Updated more tests.

* Fix some tests

* Fix all prioritization tests.

And add new for preferred words.

* Updated CompletedDownloadservice tests

* Fixed a lot of tests

* Fixed all indexer requests. We should add more for the indexers we added.

To lazy for that though ¯\_(ツ)_/¯

* Fixed organizer tests.

Should probably be also updated to incorporate our newly added tags.

* Fix notification tests.

* Fixed update test for osx

* Fixed a few more tests.

* Fixed some more tests.

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update appveyor.yml

* Update activity.less

* Update appveyor.yml

* Update appveyor.yml

* Update CommonVersionInfo.cs

* Update build-appveyor.cake

Let's hope this works.

* Update CommonVersionInfo.cs

Just to kickstart appveyor

* Fixed a few tests

* Just ignore those tests.

* Fixed more tests.

* First steps in fixing Core.Test.Download.DownloadApprovedFixture

* Fix most DownloadApprovedFixture tests

* Fixed something.

* Fixed a few more tests.

* Fixed pending release tests.

* All Core tests are now fixed.

* Fixed the last tests :)

* Fixed Download Station Tests.

* Fixed Vuze and Transmission default settings which caused the tests to fail.

* Fix most tests.

* Fix RootFolder tests.

* Fixed last tests
2017-03-06 22:23:25 +01:00

57 lines
1.7 KiB
C#

using FluentAssertions;
using NUnit.Framework;
using NzbDrone.Core.MetadataSource.SkyHook;
using NzbDrone.Core.Test.Framework;
using NzbDrone.Test.Common;
using NzbDrone.Test.Common.Categories;
namespace NzbDrone.Core.Test.MetadataSource.SkyHook
{
[TestFixture]
[IntegrationTest]
public class SkyHookProxySearchFixture : CoreTest<SkyHookProxy>
{
[SetUp]
public void Setup()
{
UseRealHttp();
}
[TestCase("The Simpsons", "The Simpsons")]
[TestCase("South Park", "South Park")]
[TestCase("Franklin & Bash", "Franklin & Bash")]
[TestCase("House", "House")]
[TestCase("Mr. D", "Mr. D")]
//[TestCase("Rob & Big", "Rob & Big")]
[TestCase("M*A*S*H", "M*A*S*H")]
//[TestCase("imdb:tt0436992", "Doctor Who (2005)")]
[TestCase("tvdb:78804", "Doctor Who (2005)")]
[TestCase("tvdbid:78804", "Doctor Who (2005)")]
[TestCase("tvdbid: 78804 ", "Doctor Who (2005)")]
public void successful_search(string title, string expected)
{
var result = Subject.SearchForNewSeries(title);
result.Should().NotBeEmpty();
result[0].Title.Should().Be(expected);
ExceptionVerification.IgnoreWarns();
}
[TestCase("tvdbid:")]
[TestCase("tvdbid: 99999999999999999999")]
[TestCase("tvdbid: 0")]
[TestCase("tvdbid: -12")]
[TestCase("tvdbid:289578")]
[TestCase("adjalkwdjkalwdjklawjdlKAJD;EF")]
public void no_search_result(string term)
{
var result = Subject.SearchForNewSeries(term);
result.Should().BeEmpty();
ExceptionVerification.IgnoreWarns();
}
}
}