< Summary - Jellyfin

Information
Class: Emby.Server.Implementations.Library.Validators.ArtistsPostScanTask
Assembly: Emby.Server.Implementations
File(s): /srv/git/jellyfin/Emby.Server.Implementations/Library/Validators/ArtistsPostScanTask.cs
Line coverage
100%
Covered lines: 5
Uncovered lines: 0
Coverable lines: 5
Total lines: 49
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Coverage history

Coverage history 0 25 50 75 100

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
.ctor(...)100%11100%
Run(...)100%11100%

File(s)

/srv/git/jellyfin/Emby.Server.Implementations/Library/Validators/ArtistsPostScanTask.cs

#LineLine coverage
 1using System;
 2using System.Threading;
 3using System.Threading.Tasks;
 4using MediaBrowser.Controller.Library;
 5using MediaBrowser.Controller.Persistence;
 6using Microsoft.Extensions.Logging;
 7
 8namespace Emby.Server.Implementations.Library.Validators
 9{
 10    /// <summary>
 11    /// Class ArtistsPostScanTask.
 12    /// </summary>
 13    public class ArtistsPostScanTask : ILibraryPostScanTask
 14    {
 15        /// <summary>
 16        /// The _library manager.
 17        /// </summary>
 18        private readonly ILibraryManager _libraryManager;
 19        private readonly ILogger<ArtistsValidator> _logger;
 20        private readonly IItemRepository _itemRepo;
 21
 22        /// <summary>
 23        /// Initializes a new instance of the <see cref="ArtistsPostScanTask" /> class.
 24        /// </summary>
 25        /// <param name="libraryManager">The library manager.</param>
 26        /// <param name="logger">The logger.</param>
 27        /// <param name="itemRepo">The item repository.</param>
 28        public ArtistsPostScanTask(
 29            ILibraryManager libraryManager,
 30            ILogger<ArtistsValidator> logger,
 31            IItemRepository itemRepo)
 32        {
 2233            _libraryManager = libraryManager;
 2234            _logger = logger;
 2235            _itemRepo = itemRepo;
 2236        }
 37
 38        /// <summary>
 39        /// Runs the specified progress.
 40        /// </summary>
 41        /// <param name="progress">The progress.</param>
 42        /// <param name="cancellationToken">The cancellation token.</param>
 43        /// <returns>Task.</returns>
 44        public Task Run(IProgress<double> progress, CancellationToken cancellationToken)
 45        {
 1946            return new ArtistsValidator(_libraryManager, _logger, _itemRepo).Run(progress, cancellationToken);
 47        }
 48    }
 49}