mirror of
https://github.com/Radarr/Radarr.git
synced 2024-09-11 12:02:35 +02:00
Fixed some disk upgrade tests that were testing the wrong thing
This commit is contained in:
parent
3965518023
commit
d7b0183457
@ -128,6 +128,8 @@ public void should_not_be_upgradable_if_qualities_are_the_same()
|
|||||||
[Test]
|
[Test]
|
||||||
public void should_return_false_when_episodeFile_was_added_more_than_7_days_ago()
|
public void should_return_false_when_episodeFile_was_added_more_than_7_days_ago()
|
||||||
{
|
{
|
||||||
|
_firstFile.Quality.Quality = Quality.DVD;
|
||||||
|
|
||||||
_firstFile.DateAdded = DateTime.Today.AddDays(-30);
|
_firstFile.DateAdded = DateTime.Today.AddDays(-30);
|
||||||
_upgradeDisk.IsSatisfiedBy(_parseResultSingle, null).Should().BeFalse();
|
_upgradeDisk.IsSatisfiedBy(_parseResultSingle, null).Should().BeFalse();
|
||||||
}
|
}
|
||||||
@ -135,6 +137,9 @@ public void should_return_false_when_episodeFile_was_added_more_than_7_days_ago(
|
|||||||
[Test]
|
[Test]
|
||||||
public void should_return_false_when_first_episodeFile_was_added_more_than_7_days_ago()
|
public void should_return_false_when_first_episodeFile_was_added_more_than_7_days_ago()
|
||||||
{
|
{
|
||||||
|
_firstFile.Quality.Quality = Quality.DVD;
|
||||||
|
_secondFile.Quality.Quality = Quality.DVD;
|
||||||
|
|
||||||
_firstFile.DateAdded = DateTime.Today.AddDays(-30);
|
_firstFile.DateAdded = DateTime.Today.AddDays(-30);
|
||||||
_upgradeDisk.IsSatisfiedBy(_parseResultMulti, null).Should().BeFalse();
|
_upgradeDisk.IsSatisfiedBy(_parseResultMulti, null).Should().BeFalse();
|
||||||
}
|
}
|
||||||
@ -142,6 +147,9 @@ public void should_return_false_when_first_episodeFile_was_added_more_than_7_day
|
|||||||
[Test]
|
[Test]
|
||||||
public void should_return_false_when_second_episodeFile_was_added_more_than_7_days_ago()
|
public void should_return_false_when_second_episodeFile_was_added_more_than_7_days_ago()
|
||||||
{
|
{
|
||||||
|
_firstFile.Quality.Quality = Quality.DVD;
|
||||||
|
_secondFile.Quality.Quality = Quality.DVD;
|
||||||
|
|
||||||
_secondFile.DateAdded = DateTime.Today.AddDays(-30);
|
_secondFile.DateAdded = DateTime.Today.AddDays(-30);
|
||||||
_upgradeDisk.IsSatisfiedBy(_parseResultMulti, null).Should().BeFalse();
|
_upgradeDisk.IsSatisfiedBy(_parseResultMulti, null).Should().BeFalse();
|
||||||
}
|
}
|
||||||
@ -149,7 +157,8 @@ public void should_return_false_when_second_episodeFile_was_added_more_than_7_da
|
|||||||
[Test]
|
[Test]
|
||||||
public void should_return_true_when_episodeFile_was_added_more_than_7_days_ago_but_proper_is_for_better_quality()
|
public void should_return_true_when_episodeFile_was_added_more_than_7_days_ago_but_proper_is_for_better_quality()
|
||||||
{
|
{
|
||||||
_firstFile.Quality.Quality = Quality.SDTV;
|
WithFirstFileUpgradable();
|
||||||
|
|
||||||
_firstFile.DateAdded = DateTime.Today.AddDays(-30);
|
_firstFile.DateAdded = DateTime.Today.AddDays(-30);
|
||||||
_upgradeDisk.IsSatisfiedBy(_parseResultSingle, null).Should().BeTrue();
|
_upgradeDisk.IsSatisfiedBy(_parseResultSingle, null).Should().BeTrue();
|
||||||
}
|
}
|
||||||
@ -157,6 +166,8 @@ public void should_return_true_when_episodeFile_was_added_more_than_7_days_ago_b
|
|||||||
[Test]
|
[Test]
|
||||||
public void should_return_true_when_episodeFile_was_added_more_than_7_days_ago_but_is_for_search()
|
public void should_return_true_when_episodeFile_was_added_more_than_7_days_ago_but_is_for_search()
|
||||||
{
|
{
|
||||||
|
WithFirstFileUpgradable();
|
||||||
|
|
||||||
_firstFile.DateAdded = DateTime.Today.AddDays(-30);
|
_firstFile.DateAdded = DateTime.Today.AddDays(-30);
|
||||||
_upgradeDisk.IsSatisfiedBy(_parseResultSingle, new SingleEpisodeSearchCriteria()).Should().BeTrue();
|
_upgradeDisk.IsSatisfiedBy(_parseResultSingle, new SingleEpisodeSearchCriteria()).Should().BeTrue();
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user