Fix tests in IndexerServiceFixture

(cherry picked from commit 90a9ecbaac1b406ffeb6b6876d619191a317a35f)
pull/3710/head
Bogdan 2 years ago committed by servarr
parent feebe6726a
commit 1c39f56521

@ -7,6 +7,7 @@ using NzbDrone.Core.Indexers.FileList;
using NzbDrone.Core.Indexers.Newznab; using NzbDrone.Core.Indexers.Newznab;
using NzbDrone.Core.Lifecycle; using NzbDrone.Core.Lifecycle;
using NzbDrone.Core.Test.Framework; using NzbDrone.Core.Test.Framework;
using NzbDrone.Test.Common;
namespace NzbDrone.Core.Test.IndexerTests namespace NzbDrone.Core.Test.IndexerTests
{ {
@ -33,13 +34,15 @@ namespace NzbDrone.Core.Test.IndexerTests
Mocker.SetConstant<IIndexerRepository>(repo); Mocker.SetConstant<IIndexerRepository>(repo);
var existingIndexers = Builder<IndexerDefinition>.CreateNew().BuildNew(); var existingIndexers = Builder<IndexerDefinition>.CreateNew().BuildNew();
existingIndexers.ConfigContract = typeof(NewznabSettings).Name; existingIndexers.ConfigContract = nameof(NewznabSettings);
repo.Insert(existingIndexers); repo.Insert(existingIndexers);
Subject.Handle(new ApplicationStartedEvent()); Subject.Handle(new ApplicationStartedEvent());
AllStoredModels.Should().NotContain(c => c.Id == existingIndexers.Id); AllStoredModels.Should().NotContain(c => c.Id == existingIndexers.Id);
ExceptionVerification.ExpectedWarns(1);
} }
} }
} }

Loading…
Cancel
Save