< Summary

Class:DCL.SettingsCommon.SettingsControllers.SpecificControllers.AllowVoiceChatControlController
Assembly:SettingsControllers
File(s):/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/Controllers/Settings/SettingsControllers/SpecificControllers/AllowVoiceChatControlController.cs
Covered lines:5
Uncovered lines:0
Coverable lines:5
Total lines:18
Line coverage:100% (5 of 5)
Covered branches:0
Total branches:0

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity NPath complexity Sequence coverage
GetStoredValue()0%110100%
UpdateSetting(...)0%110100%

File(s)

/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/Controllers/Settings/SettingsControllers/SpecificControllers/AllowVoiceChatControlController.cs

#LineLine coverage
 1using DCL.SettingsCommon.SettingsControllers.BaseControllers;
 2using UnityEngine;
 3
 4namespace DCL.SettingsCommon.SettingsControllers.SpecificControllers
 5{
 6    [CreateAssetMenu(menuName = "Settings/Controllers/Controls/Allow Voice Chat", fileName = "AllowVoiceChatControlContr
 7    public class AllowVoiceChatControlController : SpinBoxSettingsControlController
 8    {
 29        public override object GetStoredValue() { return (int)currentGeneralSettings.voiceChatAllow; }
 10
 11        public override void UpdateSetting(object newValue)
 12        {
 213            int newIntValue = (int)newValue;
 214            currentGeneralSettings.voiceChatAllow = (GeneralSettings.VoiceChatAllow)newIntValue;
 215            Settings.i.ApplyVoiceChatSettings();
 216        }
 17    }
 18}