Fix test error

This commit is contained in:
Nikolaj Geisle
2022-05-09 13:35:23 +02:00
parent f095797c2e
commit a5df4f169b
2 changed files with 11 additions and 3 deletions

View File

@@ -6,8 +6,16 @@ namespace Umbraco.Cms.Core.Models.Membership
{
public class ReadOnlyUserGroup : IReadOnlyUserGroup, IEquatable<ReadOnlyUserGroup>
{
public ReadOnlyUserGroup(int id, string? name, string? icon, int? startContentId, int? startMediaId, string? @alias,
IEnumerable<int> allowedLanguages, IEnumerable<string> allowedSections, IEnumerable<string>? permissions)
public ReadOnlyUserGroup(
int id,
string? name,
string? icon,
int? startContentId,
int? startMediaId,
string? @alias,
IEnumerable<int> allowedLanguages,
IEnumerable<string> allowedSections,
IEnumerable<string>? permissions)
{
Name = name ?? string.Empty;
Icon = icon;

View File

@@ -119,7 +119,7 @@ namespace Umbraco.Cms.Tests.UnitTests.Umbraco.Infrastructure.Editors
{
var currentUser = Mock.Of<IUser>(user => user.Groups == new[]
{
new ReadOnlyUserGroup(1, "CurrentUser", "icon-user", null, null, groupAlias, new string[0], new string[0])
new ReadOnlyUserGroup(1, "CurrentUser", "icon-user", null, null, groupAlias, new int[0], new string[0], new string[0])
});
IUser savingUser = null; // This means it is a new created user