mirror of
https://github.com/Sonarr/Sonarr.git
synced 2024-12-16 11:37:58 +02:00
Fix broken tests
This commit is contained in:
parent
f4c71fc56f
commit
89b1d58b86
@ -61,7 +61,7 @@ public void should_be_true_when_restrictions_are_empty()
|
||||
[Test]
|
||||
public void should_be_true_when_title_contains_one_required_term()
|
||||
{
|
||||
GivenRestictions(new List<string> { "WEBRip" }, null);
|
||||
GivenRestictions(new List<string> { "WEBRip" }, new List<string>());
|
||||
|
||||
Subject.IsSatisfiedBy(_remoteEpisode, null).Accepted.Should().BeTrue();
|
||||
}
|
||||
@ -69,7 +69,7 @@ public void should_be_true_when_title_contains_one_required_term()
|
||||
[Test]
|
||||
public void should_be_false_when_title_does_not_contain_any_required_terms()
|
||||
{
|
||||
GivenRestictions(new List<string> { "doesnt", "exist" }, null);
|
||||
GivenRestictions(new List<string> { "doesnt", "exist" }, new List<string>());
|
||||
|
||||
Subject.IsSatisfiedBy(_remoteEpisode, null).Accepted.Should().BeFalse();
|
||||
}
|
||||
@ -77,7 +77,7 @@ public void should_be_false_when_title_does_not_contain_any_required_terms()
|
||||
[Test]
|
||||
public void should_be_true_when_title_does_not_contain_any_ignored_terms()
|
||||
{
|
||||
GivenRestictions(null, new List<string> { "ignored" });
|
||||
GivenRestictions(new List<string>(), new List<string> { "ignored" });
|
||||
|
||||
Subject.IsSatisfiedBy(_remoteEpisode, null).Accepted.Should().BeTrue();
|
||||
}
|
||||
@ -85,7 +85,7 @@ public void should_be_true_when_title_does_not_contain_any_ignored_terms()
|
||||
[Test]
|
||||
public void should_be_false_when_title_contains_one_anded_ignored_terms()
|
||||
{
|
||||
GivenRestictions(null, new List<string> { "edited" });
|
||||
GivenRestictions(new List<string>(), new List<string> { "edited" });
|
||||
|
||||
Subject.IsSatisfiedBy(_remoteEpisode, null).Accepted.Should().BeFalse();
|
||||
}
|
||||
@ -96,7 +96,7 @@ public void should_be_false_when_title_contains_one_anded_ignored_terms()
|
||||
[TestCase("X264,NOTTHERE")]
|
||||
public void should_ignore_case_when_matching_required(string required)
|
||||
{
|
||||
GivenRestictions(required.Split(',').ToList(), null);
|
||||
GivenRestictions(required.Split(',').ToList(), new List<string>());
|
||||
|
||||
Subject.IsSatisfiedBy(_remoteEpisode, null).Accepted.Should().BeTrue();
|
||||
}
|
||||
@ -107,7 +107,7 @@ public void should_ignore_case_when_matching_required(string required)
|
||||
[TestCase("X264,NOTTHERE")]
|
||||
public void should_ignore_case_when_matching_ignored(string ignored)
|
||||
{
|
||||
GivenRestictions(null, ignored.Split(',').ToList());
|
||||
GivenRestictions(new List<string>(), ignored.Split(',').ToList());
|
||||
|
||||
Subject.IsSatisfiedBy(_remoteEpisode, null).Accepted.Should().BeFalse();
|
||||
}
|
||||
@ -137,7 +137,7 @@ public void should_be_false_when_release_contains_one_restricted_word_and_one_re
|
||||
[TestCase(@"/\.WEB/", true)]
|
||||
public void should_match_perl_regex(string pattern, bool expected)
|
||||
{
|
||||
GivenRestictions(pattern.Split(',').ToList(), null);
|
||||
GivenRestictions(pattern.Split(',').ToList(), new List<string>());
|
||||
|
||||
Subject.IsSatisfiedBy(_remoteEpisode, null).Accepted.Should().Be(expected);
|
||||
}
|
||||
|
@ -170,7 +170,7 @@ public void error_item_should_have_required_properties()
|
||||
GivenTorrents(new List<QBittorrentTorrent> { torrent });
|
||||
|
||||
var item = Subject.GetItems().Single();
|
||||
VerifyFailed(item);
|
||||
VerifyWarning(item);
|
||||
}
|
||||
|
||||
[Test]
|
||||
|
Loading…
Reference in New Issue
Block a user