LOAD_TEST(btunittest, selector_loop_ut_8)
{
	AgentNodeTest* myTestAgent = initTestEnvNode("node_test/selector_loop_ut_8", format);
	myTestAgent->resetProperties();

	myTestAgent->testVar_0 = 10;
	myTestAgent->m_bCanSee = false;

	behaviac::EBTStatus s = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_RUNNING, s);
	CHECK_EQUAL(2, myTestAgent->testVar_0);
	CHECK_EQUAL(1, myTestAgent->testVar_1);

	myTestAgent->testVar_0 = 10;
	s = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_RUNNING, s);
	CHECK_EQUAL(2, myTestAgent->testVar_0);
	CHECK_EQUAL(2, myTestAgent->testVar_1);

	s = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_SUCCESS, s);
	CHECK_EQUAL(2, myTestAgent->testVar_0);
	CHECK_EQUAL(101, myTestAgent->testVar_1);

    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, wait_ut_2)
{
	AgentNodeTest* myTestAgent = initTestEnvNode("node_test/wait_ut_2", format);

	behaviac::Workspace::GetInstance()->SetTimeSinceStartup(0);
	myTestAgent->resetProperties();
	behaviac::EBTStatus status = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_RUNNING, status);
	CHECK_EQUAL(1, myTestAgent->testVar_0);

	for (int i = 0; i < 10; ++i) {
		double time = (i + 1) / 1000.0f;
		behaviac::Workspace::GetInstance()->SetTimeSinceStartup(time);
		status = myTestAgent->btexec();
		CHECK_EQUAL(behaviac::BT_RUNNING, status);
	}
	
	behaviac::Workspace::GetInstance()->SetTimeSinceStartup(1.001f);
	status = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_RUNNING, status);

	behaviac::Workspace::GetInstance()->SetTimeSinceStartup(1.100f);
	status = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_FAILURE, status);

	finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, selector_loop_ut_7)
{
	AgentNodeTest* myTestAgent = initTestEnvNode("node_test/selector_loop_ut_7", format);
	myTestAgent->resetProperties();

	myTestAgent->m_bCanSee = false;
	const int kCount = 5;
	for (int i = 0; i <kCount; ++i)
	{
		behaviac::EBTStatus s = myTestAgent->btexec();
		CHECK_EQUAL(behaviac::BT_RUNNING, s);
		CHECK_EQUAL(2, myTestAgent->testVar_0);
		CHECK_EQUAL(i + 1, myTestAgent->testVar_1);
	}

	myTestAgent->m_bCanSee = true;

	behaviac::EBTStatus s = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_RUNNING, s);
	CHECK_EQUAL(1, myTestAgent->testVar_0);
	CHECK_EQUAL(6, myTestAgent->testVar_1);

	myTestAgent->m_bTargetValid = false;

	s = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_SUCCESS, s);
	CHECK_EQUAL(1, myTestAgent->testVar_0);
	CHECK_EQUAL(3, myTestAgent->testVar_1);

    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, parallel_ut_4)
{
	AgentNodeTest* myTestAgent = initTestEnvNode("node_test/parallel_ut_4", format);
	myTestAgent->resetProperties();
	myTestAgent->btexec();
	CHECK_EQUAL(2, myTestAgent->testVar_0);
	myTestAgent->resetProperties();
	myTestAgent->btexec();
	CHECK_EQUAL(2, myTestAgent->testVar_0);
	finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, predicate_action_ut_3)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/predicate_action_ut_3", format);
    myTestAgent->resetProperties();
    behaviac::EBTStatus status = myTestAgent->btexec();
    CHECK_EQUAL(behaviac::BT_RUNNING, status);
    CHECK_EQUAL(0, myTestAgent->testVar_0);
    status = myTestAgent->btexec();
    CHECK_EQUAL(0, myTestAgent->testVar_0);
    CHECK_EQUAL(behaviac::BT_FAILURE, status);
    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, par_test_custom_property_reset)
{
	AgentNodeTest* myTestAgent = initTestEnvNode("par_test/custom_property_reset", format);
	myTestAgent->resetProperties();
	behaviac::EBTStatus status = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_SUCCESS, status);
	CHECK_EQUAL(10, myTestAgent->testVar_1);

	status = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_SUCCESS, status);
	CHECK_EQUAL(20, myTestAgent->testVar_1);
	finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, selector_loop_ut_4)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/selector_loop_ut_4", format);
    myTestAgent->resetProperties();
    behaviac::EBTStatus status = myTestAgent->btexec();
    BEHAVIAC_UNUSED_VAR(status);
    CHECK_EQUAL(1, myTestAgent->testVar_0);
    CHECK_EQUAL(0, myTestAgent->testVar_1);
    myTestAgent->resetProperties();
    myTestAgent->btexec();
    CHECK_EQUAL(1, myTestAgent->testVar_0);
    CHECK_EQUAL(0, myTestAgent->testVar_1);
    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, action_ut_waitforsignal_2)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/action_ut_waitforsignal_2", format);
    myTestAgent->resetProperties();
    behaviac::EBTStatus status = myTestAgent->btexec();
    BEHAVIAC_UNUSED_VAR(status);
    CHECK_FLOAT_EQUAL(-1.0f, myTestAgent->testVar_2);
    CHECK_EQUAL(behaviac::BT_RUNNING, status);
    myTestAgent->resetProperties();
    myTestAgent->testVar_2 = 0.0f;
    status = myTestAgent->btexec();
    CHECK_FLOAT_EQUAL(2.3f, myTestAgent->testVar_2);
    CHECK_EQUAL(behaviac::BT_SUCCESS, status);
    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, selector_probability_ut_4)
{
	const char* tree = "node_test/selector_probability_ut_4";

	behaviac::Profiler::CreateInstance();
	behaviac::Config::SetSocketing(false);
	behaviac::Config::SetLogging(false);

	//behaviac::Agent::Register<AgentNodeTest>();
	registerAllTypes();
	AgentNodeTest* myTestAgent = AgentNodeTest::DynamicCast(behaviac::Agent::Create<AgentNodeTest>());
	behaviac::Agent::SetIdMask(1);
	myTestAgent->SetIdFlag(1);
	myTestAgent->btload(tree);
	myTestAgent->btsetcurrent(tree);
	myTestAgent->resetProperties();

	behaviac::Workspace::GetInstance()->SetTimeSinceStartup(0.0);

	for (int i = 0; i < 10; ++i) {
		myTestAgent->btexec();
		if (myTestAgent->testVar_0 != -1) {
			CHECK_EQUAL(0, myTestAgent->testVar_0);
			CHECK_EQUAL(-1, myTestAgent->testVar_1);
			CHECK_FLOAT_EQUAL(0.0f, myTestAgent->testVar_2);
		}
		else {
			CHECK_EQUAL(-1, myTestAgent->testVar_0);
			CHECK_EQUAL(0, myTestAgent->testVar_1);
			CHECK_FLOAT_EQUAL(-1, myTestAgent->testVar_2);
		}

		behaviac::Workspace::GetInstance()->SetTimeSinceStartup(behaviac::Workspace::GetInstance()->GetTimeSinceStartup() + 0.1);
	}

	behaviac::Workspace::GetInstance()->SetTimeSinceStartup(behaviac::Workspace::GetInstance()->GetTimeSinceStartup() + 0.1);
	myTestAgent->btexec();

	CHECK_EQUAL(-1, myTestAgent->testVar_0);
	CHECK_EQUAL(-1, myTestAgent->testVar_1);


	unregisterAllTypes();
	BEHAVIAC_DELETE(myTestAgent);
	//behaviac::Agent::UnRegister<AgentNodeTest>();

	behaviac::Profiler::DestroyInstance();
}
LOAD_TEST(btunittest, action_ut_1)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/action_ut_1", format);
    myTestAgent->resetProperties();
    behaviac::EBTStatus status = myTestAgent->btexec();
    BEHAVIAC_UNUSED_VAR(status);
    CHECK_FLOAT_EQUAL(1.8f, myTestAgent->testVar_2);
    CHECK_FLOAT_EQUAL(4.5f, myTestAgent->testVar_3);

	CHECK_EQUAL("HC", myTestAgent->testVar_str_0);
	CHECK_EQUAL("NODE", myTestAgent->testVar_str_1);
	const TestNS::Float2& float2 = myTestAgent->GetVariable<TestNS::Float2>("testFloat2");
	CHECK_FLOAT_EQUAL(1.0f, float2.x);
	CHECK_FLOAT_EQUAL(1.0f, float2.y);

	const TestNS::Float2& c_ReturnFloat2 = myTestAgent->GetVariable<TestNS::Float2>("c_ReturnFloat2");
	CHECK_FLOAT_EQUAL(2.0f, c_ReturnFloat2.x);
	CHECK_FLOAT_EQUAL(2.0f, c_ReturnFloat2.y);

	const TestNS::Float2& c_ReturnFloat2Const = myTestAgent->GetVariable<TestNS::Float2>("c_ReturnFloat2Const");
	CHECK_FLOAT_EQUAL(2.0f, c_ReturnFloat2Const.x);
	CHECK_FLOAT_EQUAL(2.0f, c_ReturnFloat2Const.y);

	finlTestEnvNode(myTestAgent);
}
//< Action Nodes Tests
LOAD_TEST(btunittest, action_ut_0)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/action_ut_0", format);
    myTestAgent->resetProperties();

	ChildNodeTest* testChildAgent = behaviac::Agent::Create<ChildNodeTest>(1, "par_child", 0, 0);
	StaticAgent* pStaticAgent = behaviac::Agent::Create<StaticAgent>("StaticAgent");

	myTestAgent->testVar_3 = 1;
    testChildAgent->testVar_2 = 2;

    myTestAgent->SetVariable<ChildNodeTest*>("par_child", testChildAgent);

    myTestAgent->btexec();

    CHECK_EQUAL(1500, myTestAgent->testVar_0);
    CHECK_EQUAL(1800, myTestAgent->testVar_1);
    CHECK_EQUAL("null", myTestAgent->testVar_str_0);
	CHECK_EQUAL(2, StaticAgent::sInt);
    CHECK_EQUAL(true, testChildAgent->m_bTargetValid);

    behaviac::Agent::Destroy(testChildAgent);
    behaviac::Agent::Destroy(pStaticAgent);

    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, selector_probability_ut_2)
{
	const char* tree = "node_test/selector_probability_ut_2";

	behaviac::Profiler::CreateInstance();
	behaviac::Config::SetSocketing(false);
	behaviac::Config::SetLogging(false);

	//behaviac::Agent::Register<AgentNodeTest>();
	registerAllTypes();
	AgentNodeTest* myTestAgent = AgentNodeTest::DynamicCast(behaviac::Agent::Create<AgentNodeTest>());
	behaviac::Agent::SetIdMask(1);
	myTestAgent->SetIdFlag(1);
	myTestAgent->btload(tree);
	myTestAgent->btsetcurrent(tree);
	myTestAgent->resetProperties();

	int loopCount = 10000;

	while (loopCount > 0)
	{
		myTestAgent->btexec();
		CHECK_EQUAL(-1, myTestAgent->testVar_0);
		--loopCount;
	}

	unregisterAllTypes();
	BEHAVIAC_DELETE(myTestAgent);
	//behaviac::Agent::UnRegister<AgentNodeTest>();

	behaviac::Profiler::DestroyInstance();
}
LOAD_TEST(btunittest, wait_ut_0)
{
	AgentNodeTest* myTestAgent = initTestEnvNode("node_test/wait_ut_0", format);
	behaviac::Workspace::GetInstance()->SetTimeSinceStartup(0);
	myTestAgent->resetProperties();
	behaviac::EBTStatus status = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_RUNNING, status);
	CHECK_EQUAL(1, myTestAgent->testVar_0);

	behaviac::Workspace::GetInstance()->SetTimeSinceStartup(1.001f);
	status = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_SUCCESS, status);
	CHECK_EQUAL(2, myTestAgent->testVar_0);

	finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, decoration_successuntil_ut_1)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/decoration_successuntil_ut_1", format);
    myTestAgent->resetProperties();
    int loopCount = 0;

    while (loopCount < 5)
    {
        behaviac::EBTStatus status = myTestAgent->btexec();

        if (loopCount < 4)
        {
            CHECK_EQUAL(behaviac::BT_SUCCESS, status);

        }
        else
        {
            CHECK_EQUAL(behaviac::BT_FAILURE, status);
        }

        ++loopCount;
    }

    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, decoration_loop_ut_1)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/decoration_loop_ut_1", format);
    int loopCount = 0;

    while (loopCount < 500)
    {
        myTestAgent->resetProperties();
        myTestAgent->btexec();

        if (loopCount < 499)
        {
            CHECK_EQUAL(0, myTestAgent->testVar_0);

        }
        else
        {
            CHECK_EQUAL(1, myTestAgent->testVar_0);
        }

        ++loopCount;
    }

    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, action_ut_3_save_load)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/action_ut_3", format);
    myTestAgent->resetProperties();

#if BEHAVIAC_COMPILER_MSVC || BEHAVIAC_COMPILER_GCC_CYGWIN || BEHAVIAC_COMPILER_GCC_LINUX
    behaviac::State_t state;
    myTestAgent->btsave(state);
    state.SaveToFile("btsave.xml");
#endif

    behaviac::EBTStatus status = myTestAgent->btexec();
    BEHAVIAC_UNUSED_VAR(status);
    CHECK_FLOAT_EQUAL(2.4f, myTestAgent->testVar_2);
    CHECK_FLOAT_EQUAL(4.0f, myTestAgent->testVar_3);

#if BEHAVIAC_COMPILER_MSVC || BEHAVIAC_COMPILER_GCC_CYGWIN || BEHAVIAC_COMPILER_GCC_LINUX
    myTestAgent->resetProperties();

    behaviac::State_t stateTemp;
    stateTemp.LoadFromFile("btsave.xml");

    myTestAgent->btload(state);

    //myTestAgent->btexec();
    //CHECK_EQUAL(2.4f, myTestAgent->testVar_2);
    //CHECK_EQUAL(4.0f, myTestAgent->testVar_3);
#endif

    finlTestEnvNode(myTestAgent);
}
//< Decoration Frames Tests
LOAD_TEST(btunittest, decoration_frames_ut_0)
{
	behaviac::Workspace::GetInstance()->SetFrameSinceStartup(0);

    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/decoration_frames_ut_0", format);
    int loopCount = 0;

    while (loopCount < 100)
    {
        myTestAgent->resetProperties();
        myTestAgent->btexec();

        if (loopCount < 99)
        {
            CHECK_EQUAL(0, myTestAgent->testVar_0);
        }
        else
        {
            CHECK_EQUAL(1, myTestAgent->testVar_0);
        }

        ++loopCount;
		behaviac::Workspace::GetInstance()->SetFrameSinceStartup(behaviac::Workspace::GetInstance()->GetFrameSinceStartup() + 1);
    }

    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, decoration_countlimit_ut_2)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/decoration_countlimit_ut_2", format);
    myTestAgent->resetProperties();
    int loopCount = 0;
    while (loopCount < 11)
    {
        if (loopCount == 5)
        {
            myTestAgent->testVar_1 = 0;
            myTestAgent->testVar_2 = 0.0f;
        }

        myTestAgent->btexec();
        myTestAgent->testVar_1 = -1;
        if (loopCount < 10)
        {
            CHECK_EQUAL(0, myTestAgent->testVar_0);
        }
        else
        {
            CHECK_EQUAL(1, myTestAgent->testVar_0);
        }
        ++loopCount;
    }
    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, action_ut_waitforsignal_0_saveload_agent)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/action_ut_waitforsignal_0", format);
    myTestAgent->resetProperties();
    behaviac::EBTStatus status = myTestAgent->btexec();
    BEHAVIAC_UNUSED_VAR(status);
    CHECK_EQUAL(-1, myTestAgent->testVar_1);
    CHECK_FLOAT_EQUAL(-1.0f, myTestAgent->testVar_2);

    behaviac::State_t state;
    myTestAgent->btsave(state);
    state.SaveToFile("btsave3.xml", myTestAgent);

    //modify the members
    myTestAgent->testVar_1 = 1;
    myTestAgent->testVar_2 = 1;

    behaviac::State_t stateTemp;
    stateTemp.LoadFromFile("btsave3.xml", myTestAgent);
    CHECK_EQUAL(-1, myTestAgent->testVar_1);
    CHECK_FLOAT_EQUAL(-1.0f, myTestAgent->testVar_2);

    myTestAgent->btload(stateTemp);

    finlTestEnvNode(myTestAgent);
}
//< Wait For Frames Tests
LOAD_TEST(btunittest, action_waitframes_ut_0)
{
    behaviac::Profiler::CreateInstance();
    behaviac::Config::SetSocketing(false);
    behaviac::Config::SetLogging(false);

    //behaviac::Agent::Register<AgentNodeTest>();
    registerAllTypes();
    AgentNodeTest* myTestAgent = AgentNodeTest::DynamicCast(behaviac::Agent::Create<AgentNodeTest>());
    behaviac::Agent::SetIdMask(1);
    myTestAgent->SetIdFlag(1);
    myTestAgent->btload("node_test/action_waitframes_ut_0");
    myTestAgent->btsetcurrent("node_test/action_waitframes_ut_0");
    myTestAgent->resetProperties();

    int loopCount = 0;

	behaviac::Workspace::GetInstance()->SetFrameSinceStartup(0);

    while (loopCount < 5)
    {
        myTestAgent->btexec();

        if (loopCount < 4)
        {
            CHECK_EQUAL(1, myTestAgent->testVar_0);
        }
        else
        {
            CHECK_EQUAL(2, myTestAgent->testVar_0);
        }

        ++loopCount;
		behaviac::Workspace::GetInstance()->SetFrameSinceStartup(behaviac::Workspace::GetInstance()->GetFrameSinceStartup() + 1);
    }

    myTestAgent->resetProperties();
    myTestAgent->btexec();
    CHECK_EQUAL(1, myTestAgent->testVar_0);

    BEHAVIAC_DELETE(myTestAgent);
    behaviac::Agent::UnRegister<AgentNodeTest>();

    behaviac::Profiler::DestroyInstance();

    unregisterAllTypes();
}
Exemple #21
0
LOAD_TEST(btunittest, event_ut_1)
{
	AgentNodeTest* myTestAgent = initTestEnvNode("node_test/event_ut_1", format);

	myTestAgent->resetProperties();

	behaviac::EBTStatus status = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_RUNNING, status);

	myTestAgent->FireEvent("event_test_int", 13);
	CHECK_EQUAL(13, myTestAgent->event_test_var_int);
			
	status = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_RUNNING, status);
	
	finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, decoration_not_ut_1)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/decoration_not_ut_1", format);
    myTestAgent->resetProperties();
    behaviac::EBTStatus status = myTestAgent->btexec();
    CHECK_EQUAL(0, myTestAgent->testVar_0);
    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, condition_ut_3)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/condition_ut_3", format);
    myTestAgent->resetProperties();
    behaviac::EBTStatus status = myTestAgent->btexec();
    BEHAVIAC_UNUSED_VAR(status);
    CHECK_EQUAL(2, myTestAgent->testVar_0);
    finlTestEnvNode(myTestAgent);
}
//< Noop Node Test
LOAD_TEST(btunittest, action_noop_ut_0)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/action_noop_ut_0", format);
    myTestAgent->resetProperties();
    behaviac::EBTStatus status = myTestAgent->btexec();
    CHECK_EQUAL(2, myTestAgent->testVar_0);
    CHECK_EQUAL(behaviac::BT_SUCCESS, status);
    finlTestEnvNode(myTestAgent);
}
//< Decoration Always Failure Tests
LOAD_TEST(btunittest, decoration_alwaysfailure_ut_0)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/decoration_alwaysfailure_ut_0", format);
    myTestAgent->resetProperties();
    behaviac::EBTStatus status = myTestAgent->btexec();
    CHECK_EQUAL(1, myTestAgent->testVar_0);
    CHECK_EQUAL(1, myTestAgent->testVar_1);
    CHECK_EQUAL(1.0f, myTestAgent->testVar_2);
    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, node_test_selector_ut_5)
{
	AgentNodeTest* myTestAgent = initTestEnvNode("node_test/selector_ut_5", format);

	myTestAgent->resetProperties();

	myTestAgent->testColor = EnumTest_One;

	behaviac::EBTStatus status = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_SUCCESS, status);
	CHECK_EQUAL(0, myTestAgent->testVar_0);

	myTestAgent->testColor = EnumTest_OneAfterOne;
	status = myTestAgent->btexec();
	CHECK_EQUAL(behaviac::BT_SUCCESS, status);
	CHECK_EQUAL(1, myTestAgent->testVar_0);

	finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, reference_ut_2)
{
	AgentNodeTest* myTestAgent = initTestEnvNode("node_test/reference_ut_2", format);
	myTestAgent->resetProperties();

	myTestAgent->btexec();
	CHECK_EQUAL(0, myTestAgent->testVar_0);
	CHECK_FLOAT_EQUAL(0.0f, myTestAgent->testVar_2);
	finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, decoration_repeat_0)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/repeat/repeat_ut_0", format);
    myTestAgent->resetProperties();

    myTestAgent->btexec();

    CHECK_EQUAL(5, myTestAgent->testVar_0);
    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, predicate_selector_ut_5)
{
    AgentNodeTest* myTestAgent = initTestEnvNode("node_test/predicate_selector_ut_5", format);
    myTestAgent->resetProperties();
    behaviac::EBTStatus status = myTestAgent->btexec();
    CHECK_EQUAL(behaviac::BT_FAILURE, status);
    CHECK_EQUAL(0, myTestAgent->testVar_0);
    CHECK_EQUAL(0, myTestAgent->testVar_1);
    CHECK_FLOAT_EQUAL(0.0f, myTestAgent->testVar_2);
    finlTestEnvNode(myTestAgent);
}
LOAD_TEST(btunittest, selector_loop_ut_5)
{
	AgentNodeTest* myTestAgent = initTestEnvNode("node_test/selector_loop_ut_5", format);
	myTestAgent->resetProperties();
	behaviac::EBTStatus s = myTestAgent->btexec();

	CHECK_EQUAL(behaviac::BT_SUCCESS, s);
	CHECK_EQUAL(1, myTestAgent->testVar_0);

    finlTestEnvNode(myTestAgent);
}