mirror of
https://github.com/Sonarr/Sonarr.git
synced 2026-04-22 22:16:13 -04:00
Fixed: Don't monitor new seasons if series is not monitored
Fixes #3547
This commit is contained in:
@@ -54,8 +54,9 @@ namespace NzbDrone.Core.Test.TvTests
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void should_monitor_new_seasons_automatically()
|
||||
public void should_monitor_new_seasons_automatically_if_series_is_monitored()
|
||||
{
|
||||
_series.Monitored = true;
|
||||
var newSeriesInfo = _series.JsonClone();
|
||||
newSeriesInfo.Seasons.Add(Builder<Season>.CreateNew()
|
||||
.With(s => s.SeasonNumber = 2)
|
||||
@@ -69,6 +70,23 @@ namespace NzbDrone.Core.Test.TvTests
|
||||
.Verify(v => v.UpdateSeries(It.Is<Series>(s => s.Seasons.Count == 2 && s.Seasons.Single(season => season.SeasonNumber == 2).Monitored == true), It.IsAny<bool>()));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void should_not_monitor_new_seasons_automatically_if_series_is_not_monitored()
|
||||
{
|
||||
_series.Monitored = false;
|
||||
var newSeriesInfo = _series.JsonClone();
|
||||
newSeriesInfo.Seasons.Add(Builder<Season>.CreateNew()
|
||||
.With(s => s.SeasonNumber = 2)
|
||||
.Build());
|
||||
|
||||
GivenNewSeriesInfo(newSeriesInfo);
|
||||
|
||||
Subject.Execute(new RefreshSeriesCommand(_series.Id));
|
||||
|
||||
Mocker.GetMock<ISeriesService>()
|
||||
.Verify(v => v.UpdateSeries(It.Is<Series>(s => s.Seasons.Count == 2 && s.Seasons.Single(season => season.SeasonNumber == 2).Monitored == false), It.IsAny<bool>()));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void should_not_monitor_new_special_season_automatically()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user