< Summary

Class:DCL.ECSComponents.AvatarUtils
Assembly:ECSComponents.Utils
File(s):/tmp/workspace/unity-renderer/unity-renderer/Assets/DCLPlugins/ECS7/ECSComponents/Utils/AvatarUtils.cs
Covered lines:3
Uncovered lines:1
Coverable lines:4
Total lines:21
Line coverage:75% (3 of 4)
Covered branches:0
Total branches:0

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity NPath complexity Sequence coverage
HaveSameWearablesAndColors(...)0%7.777075%

File(s)

/tmp/workspace/unity-renderer/unity-renderer/Assets/DCLPlugins/ECS7/ECSComponents/Utils/AvatarUtils.cs

#LineLine coverage
 1using System.Linq;
 2
 3namespace DCL.ECSComponents
 4{
 5    public static class AvatarUtils
 6    {
 7        public static bool HaveSameWearablesAndColors(PBAvatarShape avatar, PBAvatarShape otheravatar)
 8        {
 49            if (otheravatar == null || avatar == null)
 010                return false;
 11
 412            bool wearablesAreEqual = avatar.GetWereables().All(otheravatar.GetWereables().Contains) && avatar.GetWereabl
 13
 414            return avatar.GetBodyShape().Equals(otheravatar.GetBodyShape()) &&
 15                   avatar.GetSkinColor().Equals(otheravatar.GetSkinColor()) &&
 16                   avatar.GetHairColor().Equals(otheravatar.GetHairColor()) &&
 17                   avatar.GetEyeColor().Equals(otheravatar.GetEyeColor()) &&
 18                   wearablesAreEqual;
 19        }
 20    }
 21}