< Summary

Class:DCL.Social.Passports.PassportNavigationComponentView
Assembly:PassportHUD
File(s):/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/Controllers/HUD/Passport/Passport/PassportNavigation/PassportNavigationComponentView.cs
Covered lines:0
Uncovered lines:12
Coverable lines:12
Total lines:47
Line coverage:0% (0 of 12)
Covered branches:0
Total branches:0

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity NPath complexity Sequence coverage
SetGuestUser(...)0%2100%
SetName(...)0%2100%
EnableAboutPanel()0%2100%
EnableWearablesPanel()0%2100%
RefreshControl()0%2100%

File(s)

/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/Controllers/HUD/Passport/Passport/PassportNavigation/PassportNavigationComponentView.cs

#LineLine coverage
 1using System.Collections;
 2using System.Collections.Generic;
 3using UnityEngine;
 4using UnityEngine.UI;
 5using TMPro;
 6
 7namespace DCL.Social.Passports
 8{
 9    public class PassportNavigationComponentView : BaseComponentView, IPassportNavigationComponentView
 10    {
 11        private const string GUEST_TEXT = "is a guest";
 12
 13        [SerializeField] private GameObject aboutPanel;
 14        [SerializeField] private GameObject wearablesPanel;
 15        [SerializeField] private GameObject guestPanel;
 16        [SerializeField] private GameObject normalPanel;
 17        [SerializeField] private TextMeshProUGUI usernameText;
 18
 19        public void SetGuestUser(bool isGuest)
 20        {
 021            guestPanel.SetActive(isGuest);
 022            normalPanel.SetActive(!isGuest);
 023        }
 24
 25        public void SetName(string username)
 26        {
 027            usernameText.text = $"{username} {GUEST_TEXT}";
 028        }
 29
 30        private void EnableAboutPanel()
 31        {
 032            wearablesPanel.SetActive(false);
 033            aboutPanel.SetActive(true);
 034        }
 35
 36        private void EnableWearablesPanel()
 37        {
 038            aboutPanel.SetActive(false);
 039            wearablesPanel.SetActive(true);
 040        }
 41
 42        public override void RefreshControl()
 43        {
 044        }
 45
 46    }
 47}