Exemplo n.º 1
0
    private bool Test_MultiSwapping()
    {
        // Test feature
        if (!Test_SwapComponents())
        {
            TestDebug.LogTestNotStarted("Test_MultiSwapping", "Failed!");
            return(false);
        }

        // Initial setup
        bool passed = true;

        _iconComponent.SetActive(true);
        _textComponent.SetActive(false);

        // Execution
        passed &= Test_SwapComponents();
        passed &= Test_SwapComponents();
        passed &= Test_SwapComponents();

        // Test results
        passed &= !_iconComponent.activeSelf && _textComponent.activeSelf;

        if (!passed)
        {
            TestDebug.LogTestFail("Test_MultiSwapping", "MultiSwapping failed!");
        }
        return(passed);
    }
Exemplo n.º 2
0
        public bool Test_Fields()
        {
            _testName = kTestFieldsName;
            if (_fieldsList == null)
            {
                TestDebug.LogTestNotStarted(_testName, "Fields list is null");
                return(true);
            }

            bool passed = true;

            foreach (var field in _fieldsList)
            {
                passed &= field.Test();
            }

            if (passed)
            {
                TestDebug.LogTestSucceed(_testName);
            }
            return(passed);
        }
Exemplo n.º 3
0
        public bool Test_Methods()
        {
            _testName = kTestMethodName;
            if (_methodsList == null)
            {
                TestDebug.LogTestNotStarted(_testName, "Methods list is null");
                return(true);
            }

            bool passed = true;

            foreach (var method in _methodsList)
            {
                passed &= method.Test();
            }

            if (passed)
            {
                TestDebug.LogTestSucceed(_testName);
            }
            return(passed);
        }