diff --git a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioActionTimelineTest/ActionTimelineTestScene.cpp b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioActionTimelineTest/ActionTimelineTestScene.cpp index 501a7373dc..1acda7e00d 100644 --- a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioActionTimelineTest/ActionTimelineTestScene.cpp +++ b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioActionTimelineTest/ActionTimelineTestScene.cpp @@ -23,6 +23,7 @@ CocoStudioActionTimelineTests::CocoStudioActionTimelineTests() ADD_TEST_CASE(TestActionTimelineEase); ADD_TEST_CASE(TestActionTimelineSkeleton); ADD_TEST_CASE(TestTimelineExtensionData); + ADD_TEST_CASE(TestActionTimelineBlendFuncFrame); } CocoStudioActionTimelineTests::~CocoStudioActionTimelineTests() @@ -577,4 +578,22 @@ void TestTimelineExtensionData::onEnter() std::string TestTimelineExtensionData::title() const { return "Test Timeline extension data"; -} \ No newline at end of file +} + +// TestActionTimelineBlendFuncFrame +void TestActionTimelineBlendFuncFrame::onEnter() +{ + ActionTimelineBaseTest::onEnter(); + Node* node = CSLoader::createNode("ActionTimeline/skeletonBlendFuncFrame.csb"); + ActionTimeline* action = CSLoader::createTimeline("ActionTimeline/skeletonBlendFuncFrame.csb"); + node->runAction(action); + node->setScale(0.2f); + node->setPosition(VisibleRect::center()); + this->addChild(node); + action->gotoFrameAndPlay(0); +} + +std::string TestActionTimelineBlendFuncFrame::title() const +{ + return "Test ActionTimeline BlendFunc Frame"; +} diff --git a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioActionTimelineTest/ActionTimelineTestScene.h b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioActionTimelineTest/ActionTimelineTestScene.h index 7b48a9d1e9..b14e50d6b8 100644 --- a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioActionTimelineTest/ActionTimelineTestScene.h +++ b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioActionTimelineTest/ActionTimelineTestScene.h @@ -139,4 +139,11 @@ public: virtual std::string title() const override; }; +class TestActionTimelineBlendFuncFrame : public ActionTimelineBaseTest +{ +public: + CREATE_FUNC(TestActionTimelineBlendFuncFrame); + virtual void onEnter() override; + virtual std::string title() const override; +}; #endif // __ANIMATION_SCENE_H__ diff --git a/tests/cpp-tests/Resources/ActionTimeline/skeletonBlendFuncFrame.csb b/tests/cpp-tests/Resources/ActionTimeline/skeletonBlendFuncFrame.csb new file mode 100644 index 0000000000..c0dabdc8bb Binary files /dev/null and b/tests/cpp-tests/Resources/ActionTimeline/skeletonBlendFuncFrame.csb differ