mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-24 22:35:39 -04:00
Relative episode file paths
This commit is contained in:
+3
-2
@@ -30,7 +30,8 @@ namespace NzbDrone.Core.Test.MediaFiles.EpisodeFileMovingServiceTests
|
||||
.Build();
|
||||
|
||||
_episodeFile = Builder<EpisodeFile>.CreateNew()
|
||||
.With(f => f.Path = @"C:\Test\File.avi")
|
||||
.With(f => f.Path = null)
|
||||
.With(f => f.RelativePath = @"Season 1\File.avi")
|
||||
.Build();
|
||||
|
||||
_localEpisode = Builder<LocalEpisode>.CreateNew()
|
||||
@@ -44,7 +45,7 @@ namespace NzbDrone.Core.Test.MediaFiles.EpisodeFileMovingServiceTests
|
||||
|
||||
Mocker.GetMock<IBuildFileNames>()
|
||||
.Setup(s => s.BuildFilePath(It.IsAny<Series>(), It.IsAny<Int32>(), It.IsAny<String>(), It.IsAny<String>()))
|
||||
.Returns(@"C:\Test\File Name.avi");
|
||||
.Returns(@"C:\Test\TV\Series\File Name.avi");
|
||||
|
||||
Mocker.GetMock<IDiskProvider>()
|
||||
.Setup(s => s.FileExists(It.IsAny<String>()))
|
||||
|
||||
@@ -83,7 +83,7 @@ namespace NzbDrone.Core.Test.MediaFiles.EpisodeImport
|
||||
|
||||
|
||||
Mocker.GetMock<IMediaFileService>()
|
||||
.Setup(c => c.FilterExistingFiles(_videoFiles, It.IsAny<int>()))
|
||||
.Setup(c => c.FilterExistingFiles(_videoFiles, It.IsAny<Series>()))
|
||||
.Returns(_videoFiles);
|
||||
}
|
||||
|
||||
@@ -163,7 +163,7 @@ namespace NzbDrone.Core.Test.MediaFiles.EpisodeImport
|
||||
|
||||
|
||||
Mocker.GetMock<IMediaFileService>()
|
||||
.Setup(c => c.FilterExistingFiles(_videoFiles, It.IsAny<int>()))
|
||||
.Setup(c => c.FilterExistingFiles(_videoFiles, It.IsAny<Series>()))
|
||||
.Returns(_videoFiles);
|
||||
|
||||
Subject.GetImportDecisions(_videoFiles, _series, false);
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using FizzWare.NBuilder;
|
||||
using FluentAssertions;
|
||||
@@ -31,6 +32,7 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
|
||||
var series = Builder<Series>.CreateNew()
|
||||
.With(e => e.Profile = new Profile { Items = Qualities.QualityFixture.GetDefaultQualities() })
|
||||
.With(s => s.Path = @"C:\Test\TV\30 Rock".AsOsAgnostic())
|
||||
.Build();
|
||||
|
||||
var episodes = Builder<Episode>.CreateListOfSize(5)
|
||||
@@ -48,7 +50,7 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
{
|
||||
Series = series,
|
||||
Episodes = new List<Episode> {episode},
|
||||
Path = @"C:\Test\TV\30 Rock\30 Rock - S01E01 - Pilot.avi".AsOsAgnostic(),
|
||||
Path = Path.Combine(series.Path, "30 Rock - S01E01 - Pilot.avi"),
|
||||
Quality = new QualityModel(Quality.Bluray720p),
|
||||
ParsedEpisodeInfo = new ParsedEpisodeInfo
|
||||
{
|
||||
|
||||
@@ -4,7 +4,6 @@ using NUnit.Framework;
|
||||
using NzbDrone.Core.MediaFiles;
|
||||
using NzbDrone.Core.Qualities;
|
||||
using NzbDrone.Core.Test.Framework;
|
||||
using NzbDrone.Core.Tv;
|
||||
|
||||
namespace NzbDrone.Core.Test.MediaFiles
|
||||
{
|
||||
|
||||
+42
-38
@@ -1,4 +1,5 @@
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using FluentAssertions;
|
||||
using Moq;
|
||||
@@ -6,20 +7,24 @@ using NUnit.Framework;
|
||||
using NzbDrone.Core.MediaFiles;
|
||||
using NzbDrone.Core.Organizer;
|
||||
using NzbDrone.Core.Test.Framework;
|
||||
using NzbDrone.Core.Tv;
|
||||
using NzbDrone.Test.Common;
|
||||
|
||||
namespace NzbDrone.Core.Test.MediaFiles
|
||||
namespace NzbDrone.Core.Test.MediaFiles.MediaFileServiceTests
|
||||
{
|
||||
[TestFixture]
|
||||
public class MediaFileServiceTest : CoreTest<MediaFileService>
|
||||
public class FilterFixture : CoreTest<MediaFileService>
|
||||
{
|
||||
private Series _series;
|
||||
|
||||
[Test]
|
||||
[TestCase("Law & Order: Criminal Intent - S10E07 - Icarus [HDTV-720p]",
|
||||
"Law & Order- Criminal Intent - S10E07 - Icarus [HDTV-720p]")]
|
||||
public void CleanFileName(string name, string expectedName)
|
||||
[SetUp]
|
||||
public void Setup()
|
||||
{
|
||||
FileNameBuilder.CleanFileName(name).Should().Be(expectedName);
|
||||
_series = new Series
|
||||
{
|
||||
Id = 10,
|
||||
Path = @"C:\".AsOsAgnostic()
|
||||
};
|
||||
}
|
||||
|
||||
[Test]
|
||||
@@ -27,9 +32,9 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
{
|
||||
var files = new List<string>()
|
||||
{
|
||||
"c:\\file1.avi".AsOsAgnostic(),
|
||||
"c:\\file2.avi".AsOsAgnostic(),
|
||||
"c:\\file3.avi".AsOsAgnostic()
|
||||
"C:\\file1.avi".AsOsAgnostic(),
|
||||
"C:\\file2.avi".AsOsAgnostic(),
|
||||
"C:\\file3.avi".AsOsAgnostic()
|
||||
};
|
||||
|
||||
Mocker.GetMock<IMediaFileRepository>()
|
||||
@@ -37,26 +42,25 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
.Returns(new List<EpisodeFile>());
|
||||
|
||||
|
||||
Subject.FilterExistingFiles(files, 10).Should().BeEquivalentTo(files);
|
||||
Subject.FilterExistingFiles(files, _series).Should().BeEquivalentTo(files);
|
||||
}
|
||||
|
||||
|
||||
[Test]
|
||||
public void filter_should_return_none_if_all_files_exist()
|
||||
{
|
||||
var files = new List<string>()
|
||||
{
|
||||
"c:\\file1.avi".AsOsAgnostic(),
|
||||
"c:\\file2.avi".AsOsAgnostic(),
|
||||
"c:\\file3.avi".AsOsAgnostic()
|
||||
"C:\\file1.avi".AsOsAgnostic(),
|
||||
"C:\\file2.avi".AsOsAgnostic(),
|
||||
"C:\\file3.avi".AsOsAgnostic()
|
||||
};
|
||||
|
||||
Mocker.GetMock<IMediaFileRepository>()
|
||||
.Setup(c => c.GetFilesBySeries(It.IsAny<int>()))
|
||||
.Returns(files.Select(f => new EpisodeFile { Path = f }).ToList());
|
||||
.Returns(files.Select(f => new EpisodeFile { RelativePath = Path.GetFileName(f) }).ToList());
|
||||
|
||||
|
||||
Subject.FilterExistingFiles(files, 10).Should().BeEmpty();
|
||||
Subject.FilterExistingFiles(files, _series).Should().BeEmpty();
|
||||
}
|
||||
|
||||
[Test]
|
||||
@@ -64,21 +68,21 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
{
|
||||
var files = new List<string>()
|
||||
{
|
||||
"c:\\file1.avi".AsOsAgnostic(),
|
||||
"c:\\file2.avi".AsOsAgnostic(),
|
||||
"c:\\file3.avi".AsOsAgnostic()
|
||||
"C:\\file1.avi".AsOsAgnostic(),
|
||||
"C:\\file2.avi".AsOsAgnostic(),
|
||||
"C:\\file3.avi".AsOsAgnostic()
|
||||
};
|
||||
|
||||
Mocker.GetMock<IMediaFileRepository>()
|
||||
.Setup(c => c.GetFilesBySeries(It.IsAny<int>()))
|
||||
.Returns(new List<EpisodeFile>
|
||||
{
|
||||
new EpisodeFile{Path = "c:\\file2.avi".AsOsAgnostic()}
|
||||
new EpisodeFile{ RelativePath = "file2.avi".AsOsAgnostic()}
|
||||
});
|
||||
|
||||
|
||||
Subject.FilterExistingFiles(files, 10).Should().HaveCount(2);
|
||||
Subject.FilterExistingFiles(files, 10).Should().NotContain("c:\\file2.avi".AsOsAgnostic());
|
||||
Subject.FilterExistingFiles(files, _series).Should().HaveCount(2);
|
||||
Subject.FilterExistingFiles(files, _series).Should().NotContain("C:\\file2.avi".AsOsAgnostic());
|
||||
}
|
||||
|
||||
[Test]
|
||||
@@ -88,21 +92,21 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
|
||||
var files = new List<string>()
|
||||
{
|
||||
"c:\\file1.avi".AsOsAgnostic(),
|
||||
"c:\\FILE2.avi".AsOsAgnostic(),
|
||||
"c:\\file3.avi".AsOsAgnostic()
|
||||
"C:\\file1.avi".AsOsAgnostic(),
|
||||
"C:\\FILE2.avi".AsOsAgnostic(),
|
||||
"C:\\file3.avi".AsOsAgnostic()
|
||||
};
|
||||
|
||||
Mocker.GetMock<IMediaFileRepository>()
|
||||
.Setup(c => c.GetFilesBySeries(It.IsAny<int>()))
|
||||
.Returns(new List<EpisodeFile>
|
||||
{
|
||||
new EpisodeFile{Path = "c:\\file2.avi".AsOsAgnostic()}
|
||||
new EpisodeFile{ RelativePath = "file2.avi".AsOsAgnostic()}
|
||||
});
|
||||
|
||||
|
||||
Subject.FilterExistingFiles(files, 10).Should().HaveCount(2);
|
||||
Subject.FilterExistingFiles(files, 10).Should().NotContain("c:\\file2.avi".AsOsAgnostic());
|
||||
Subject.FilterExistingFiles(files, _series).Should().HaveCount(2);
|
||||
Subject.FilterExistingFiles(files, _series).Should().NotContain("C:\\file2.avi".AsOsAgnostic());
|
||||
}
|
||||
|
||||
[Test]
|
||||
@@ -112,19 +116,19 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
|
||||
var files = new List<string>()
|
||||
{
|
||||
"c:\\file1.avi".AsOsAgnostic(),
|
||||
"c:\\FILE2.avi".AsOsAgnostic(),
|
||||
"c:\\file3.avi".AsOsAgnostic()
|
||||
"C:\\file1.avi".AsOsAgnostic(),
|
||||
"C:\\FILE2.avi".AsOsAgnostic(),
|
||||
"C:\\file3.avi".AsOsAgnostic()
|
||||
};
|
||||
|
||||
Mocker.GetMock<IMediaFileRepository>()
|
||||
.Setup(c => c.GetFilesBySeries(It.IsAny<int>()))
|
||||
.Returns(new List<EpisodeFile>
|
||||
{
|
||||
new EpisodeFile{Path = "c:\\file2.avi".AsOsAgnostic()}
|
||||
new EpisodeFile{ RelativePath = "file2.avi".AsOsAgnostic()}
|
||||
});
|
||||
|
||||
Subject.FilterExistingFiles(files, 10).Should().HaveCount(3);
|
||||
Subject.FilterExistingFiles(files, _series).Should().HaveCount(3);
|
||||
}
|
||||
|
||||
[Test]
|
||||
@@ -132,16 +136,16 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
{
|
||||
var files = new List<string>()
|
||||
{
|
||||
"c:\\FILE1.avi".AsOsAgnostic()
|
||||
"C:\\FILE1.avi".AsOsAgnostic()
|
||||
};
|
||||
|
||||
Mocker.GetMock<IMediaFileRepository>()
|
||||
.Setup(c => c.GetFilesBySeries(It.IsAny<int>()))
|
||||
.Returns(new List<EpisodeFile>());
|
||||
|
||||
Subject.FilterExistingFiles(files, 10).Should().HaveCount(1);
|
||||
Subject.FilterExistingFiles(files, 10).Should().NotContain(files.First().ToLower());
|
||||
Subject.FilterExistingFiles(files, 10).Should().Contain(files.First());
|
||||
Subject.FilterExistingFiles(files, _series).Should().HaveCount(1);
|
||||
Subject.FilterExistingFiles(files, _series).Should().NotContain(files.First().ToLower());
|
||||
Subject.FilterExistingFiles(files, _series).Should().Contain(files.First());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -30,7 +30,7 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
.Returns(Builder<Series>.CreateNew().Build());
|
||||
|
||||
Mocker.GetMock<IDiskProvider>()
|
||||
.Setup(e => e.FileExists(It.Is<String>(c => c != DELETED_PATH)))
|
||||
.Setup(e => e.FileExists(It.Is<String>(c => !c.Contains(DELETED_PATH))))
|
||||
.Returns(true);
|
||||
|
||||
Mocker.GetMock<IEpisodeService>()
|
||||
@@ -68,18 +68,18 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void should_delete_none_existing_files()
|
||||
public void should_delete_non_existent_files()
|
||||
{
|
||||
var episodeFiles = Builder<EpisodeFile>.CreateListOfSize(10)
|
||||
.Random(2)
|
||||
.With(c => c.Path = DELETED_PATH)
|
||||
.With(c => c.RelativePath = DELETED_PATH)
|
||||
.Build();
|
||||
|
||||
GivenEpisodeFiles(episodeFiles);
|
||||
|
||||
Subject.Execute(new CleanMediaFileDb(0));
|
||||
|
||||
Mocker.GetMock<IMediaFileService>().Verify(c => c.Delete(It.Is<EpisodeFile>(e => e.Path == DELETED_PATH), false), Times.Exactly(2));
|
||||
Mocker.GetMock<IMediaFileService>().Verify(c => c.Delete(It.Is<EpisodeFile>(e => e.RelativePath == DELETED_PATH), false), Times.Exactly(2));
|
||||
}
|
||||
|
||||
[Test]
|
||||
@@ -87,7 +87,7 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
{
|
||||
var episodeFiles = Builder<EpisodeFile>.CreateListOfSize(10)
|
||||
.Random(10)
|
||||
.With(c => c.Path = "ExistingPath")
|
||||
.With(c => c.RelativePath = "ExistingPath")
|
||||
.Build();
|
||||
|
||||
GivenEpisodeFiles(episodeFiles);
|
||||
@@ -98,21 +98,6 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
Mocker.GetMock<IMediaFileService>().Verify(c => c.Delete(It.IsAny<EpisodeFile>(), false), Times.Exactly(10));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void should_delete_files_that_do_not_belong_to_the_series_path()
|
||||
{
|
||||
var episodeFiles = Builder<EpisodeFile>.CreateListOfSize(10)
|
||||
.Random(10)
|
||||
.With(c => c.Path = "ExistingPath")
|
||||
.Build();
|
||||
|
||||
GivenEpisodeFiles(episodeFiles);
|
||||
|
||||
Subject.Execute(new CleanMediaFileDb(0));
|
||||
|
||||
Mocker.GetMock<IMediaFileService>().Verify(c => c.Delete(It.IsAny<EpisodeFile>(), false), Times.Exactly(10));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void should_unlink_episode_when_episodeFile_does_not_exist()
|
||||
{
|
||||
@@ -128,7 +113,7 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
{
|
||||
var episodeFiles = Builder<EpisodeFile>.CreateListOfSize(10)
|
||||
.Random(10)
|
||||
.With(c => c.Path = "ExistingPath")
|
||||
.With(c => c.RelativePath = "ExistingPath")
|
||||
.Build();
|
||||
|
||||
GivenEpisodeFiles(episodeFiles);
|
||||
|
||||
@@ -1,23 +1,33 @@
|
||||
using FizzWare.NBuilder;
|
||||
using System.IO;
|
||||
using FizzWare.NBuilder;
|
||||
using Moq;
|
||||
using NUnit.Framework;
|
||||
using NzbDrone.Common.Disk;
|
||||
using NzbDrone.Core.Lifecycle;
|
||||
using NzbDrone.Core.MediaFiles;
|
||||
using NzbDrone.Core.MediaFiles.Events;
|
||||
using NzbDrone.Core.MediaFiles.MediaInfo;
|
||||
using NzbDrone.Core.Test.Framework;
|
||||
using NzbDrone.Core.Tv;
|
||||
using NzbDrone.Test.Common;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace NzbDrone.Core.Test.MediaFiles.MediaInfo
|
||||
{
|
||||
[TestFixture]
|
||||
public class UpdateMediaInfoServiceFixture : CoreTest<UpdateMediaInfoService>
|
||||
{
|
||||
private Series _series;
|
||||
|
||||
[SetUp]
|
||||
public void Setup()
|
||||
{
|
||||
_series = new Series
|
||||
{
|
||||
Id = 1,
|
||||
Path = @"C:\series".AsOsAgnostic()
|
||||
};
|
||||
}
|
||||
|
||||
private void GivenFileExists()
|
||||
{
|
||||
Mocker.GetMock<IDiskProvider>()
|
||||
@@ -44,7 +54,7 @@ namespace NzbDrone.Core.Test.MediaFiles.MediaInfo
|
||||
{
|
||||
var episodeFiles = Builder<EpisodeFile>.CreateListOfSize(3)
|
||||
.All()
|
||||
.With(v => v.Path = @"C:\series\media.mkv".AsOsAgnostic())
|
||||
.With(v => v.RelativePath = "media.mkv")
|
||||
.TheFirst(1)
|
||||
.With(v => v.MediaInfo = new MediaInfoModel())
|
||||
.BuildList();
|
||||
@@ -56,10 +66,10 @@ namespace NzbDrone.Core.Test.MediaFiles.MediaInfo
|
||||
GivenFileExists();
|
||||
GivenSuccessfulScan();
|
||||
|
||||
Subject.Handle(new SeriesScannedEvent(new Tv.Series { Id = 1 }));
|
||||
Subject.Handle(new SeriesScannedEvent(_series));
|
||||
|
||||
Mocker.GetMock<IVideoFileInfoReader>()
|
||||
.Verify(v => v.GetMediaInfo(@"C:\series\media.mkv".AsOsAgnostic()), Times.Exactly(2));
|
||||
.Verify(v => v.GetMediaInfo(Path.Combine(_series.Path, "media.mkv")), Times.Exactly(2));
|
||||
|
||||
Mocker.GetMock<IMediaFileService>()
|
||||
.Verify(v => v.Update(It.IsAny<EpisodeFile>()), Times.Exactly(2));
|
||||
@@ -70,7 +80,7 @@ namespace NzbDrone.Core.Test.MediaFiles.MediaInfo
|
||||
{
|
||||
var episodeFiles = Builder<EpisodeFile>.CreateListOfSize(2)
|
||||
.All()
|
||||
.With(v => v.Path = @"C:\series\media.mkv".AsOsAgnostic())
|
||||
.With(v => v.RelativePath = "media.mkv")
|
||||
.BuildList();
|
||||
|
||||
Mocker.GetMock<IMediaFileService>()
|
||||
@@ -79,10 +89,10 @@ namespace NzbDrone.Core.Test.MediaFiles.MediaInfo
|
||||
|
||||
GivenSuccessfulScan();
|
||||
|
||||
Subject.Handle(new SeriesScannedEvent(new Tv.Series { Id = 1 }));
|
||||
Subject.Handle(new SeriesScannedEvent(_series));
|
||||
|
||||
Mocker.GetMock<IVideoFileInfoReader>()
|
||||
.Verify(v => v.GetMediaInfo(@"C:\series\media.mkv".AsOsAgnostic()), Times.Never());
|
||||
.Verify(v => v.GetMediaInfo("media.mkv"), Times.Never());
|
||||
|
||||
Mocker.GetMock<IMediaFileService>()
|
||||
.Verify(v => v.Update(It.IsAny<EpisodeFile>()), Times.Never());
|
||||
@@ -93,9 +103,9 @@ namespace NzbDrone.Core.Test.MediaFiles.MediaInfo
|
||||
{
|
||||
var episodeFiles = Builder<EpisodeFile>.CreateListOfSize(2)
|
||||
.All()
|
||||
.With(v => v.Path = @"C:\series\media.mkv".AsOsAgnostic())
|
||||
.With(v => v.RelativePath = "media.mkv")
|
||||
.TheFirst(1)
|
||||
.With(v => v.Path = @"C:\series\media2.mkv".AsOsAgnostic())
|
||||
.With(v => v.RelativePath = "media2.mkv")
|
||||
.BuildList();
|
||||
|
||||
Mocker.GetMock<IMediaFileService>()
|
||||
@@ -104,12 +114,12 @@ namespace NzbDrone.Core.Test.MediaFiles.MediaInfo
|
||||
|
||||
GivenFileExists();
|
||||
GivenSuccessfulScan();
|
||||
GivenFailedScan(@"C:\series\media2.mkv".AsOsAgnostic());
|
||||
GivenFailedScan(Path.Combine(_series.Path, "media2.mkv"));
|
||||
|
||||
Subject.Handle(new SeriesScannedEvent(new Tv.Series { Id = 1 }));
|
||||
Subject.Handle(new SeriesScannedEvent(_series));
|
||||
|
||||
Mocker.GetMock<IVideoFileInfoReader>()
|
||||
.Verify(v => v.GetMediaInfo(@"C:\series\media.mkv".AsOsAgnostic()), Times.Exactly(1));
|
||||
.Verify(v => v.GetMediaInfo(Path.Combine(_series.Path, "media.mkv")), Times.Exactly(1));
|
||||
|
||||
Mocker.GetMock<IMediaFileService>()
|
||||
.Verify(v => v.Update(It.IsAny<EpisodeFile>()), Times.Exactly(1));
|
||||
|
||||
@@ -10,6 +10,7 @@ using NzbDrone.Core.MediaFiles;
|
||||
using NzbDrone.Core.Parser.Model;
|
||||
using NzbDrone.Core.Test.Framework;
|
||||
using NzbDrone.Core.Tv;
|
||||
using NzbDrone.Test.Common;
|
||||
|
||||
namespace NzbDrone.Core.Test.MediaFiles
|
||||
{
|
||||
@@ -22,6 +23,10 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
public void Setup()
|
||||
{
|
||||
_localEpisode = new LocalEpisode();
|
||||
_localEpisode.Series = new Series
|
||||
{
|
||||
Path = @"C:\Test\TV\Series".AsOsAgnostic()
|
||||
};
|
||||
|
||||
_episodeFile = Builder<EpisodeFile>
|
||||
.CreateNew()
|
||||
@@ -42,7 +47,7 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
new EpisodeFile
|
||||
{
|
||||
Id = 1,
|
||||
Path = @"C:\Test\30 Rock\Season 01\30.rock.s01e01.avi",
|
||||
RelativePath = @"Season 01\30.rock.s01e01.avi",
|
||||
}))
|
||||
.Build()
|
||||
.ToList();
|
||||
@@ -57,7 +62,7 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
new EpisodeFile
|
||||
{
|
||||
Id = 1,
|
||||
Path = @"C:\Test\30 Rock\Season 01\30.rock.s01e01.avi",
|
||||
RelativePath = @"Season 01\30.rock.s01e01.avi",
|
||||
}))
|
||||
.Build()
|
||||
.ToList();
|
||||
@@ -71,14 +76,14 @@ namespace NzbDrone.Core.Test.MediaFiles
|
||||
new EpisodeFile
|
||||
{
|
||||
Id = 1,
|
||||
Path = @"C:\Test\30 Rock\Season 01\30.rock.s01e01.avi",
|
||||
RelativePath = @"Season 01\30.rock.s01e01.avi",
|
||||
}))
|
||||
.TheNext(1)
|
||||
.With(e => e.EpisodeFile = new LazyLoaded<EpisodeFile>(
|
||||
new EpisodeFile
|
||||
{
|
||||
Id = 2,
|
||||
Path = @"C:\Test\30 Rock\Season 01\30.rock.s01e02.avi",
|
||||
RelativePath = @"Season 01\30.rock.s01e02.avi",
|
||||
}))
|
||||
.Build()
|
||||
.ToList();
|
||||
|
||||
Reference in New Issue
Block a user