mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-24 22:35:39 -04:00
Added: Add Release Status to Metadata Profile, Default to Official Only (#250)
* Added: Add Release Status to Metadata Profile, Default to Official Only * Fixed: Unit Test and Comparison
This commit is contained in:
@@ -27,16 +27,22 @@ namespace NzbDrone.Core.Test.Profiles.Metadata
|
||||
Allowed = l == SecondaryAlbumType.Studio
|
||||
}).ToList(),
|
||||
|
||||
ReleaseStatuses = ReleaseStatus.All.OrderByDescending(l => l.Name).Select(l => new ProfileReleaseStatusItem
|
||||
{
|
||||
ReleaseStatus = l,
|
||||
Allowed = l == ReleaseStatus.Official
|
||||
}).ToList(),
|
||||
|
||||
Name = "TestProfile"
|
||||
};
|
||||
|
||||
Subject.Insert(profile);
|
||||
|
||||
|
||||
StoredModel.Name.Should().Be(profile.Name);
|
||||
|
||||
StoredModel.PrimaryAlbumTypes.Should().Equal(profile.PrimaryAlbumTypes, (a, b) => a.PrimaryAlbumType == b.PrimaryAlbumType && a.Allowed == b.Allowed);
|
||||
StoredModel.SecondaryAlbumTypes.Should().Equal(profile.SecondaryAlbumTypes, (a, b) => a.SecondaryAlbumType == b.SecondaryAlbumType && a.Allowed == b.Allowed);
|
||||
StoredModel.ReleaseStatuses.Should().Equal(profile.ReleaseStatuses, (a, b) => a.ReleaseStatus == b.ReleaseStatus && a.Allowed == b.Allowed);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user