summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorSean Harmer <sean.harmer@kdab.com>2017-04-07 15:32:04 +0100
committerSean Harmer <sean.harmer@kdab.com>2017-04-12 18:37:26 +0000
commit90667286d9ab851f6735fc53dd7aaa3881167b3d (patch)
tree089a3d453e2f76cb1284cb62e6d98c31da7e6ed1 /tests
parent6cf41cf05ca8d1b6caddcdf54767d1926ccae323 (diff)
Add a flag to AnimationClipLoader to track where its data comes from
Nicer than implicitly tracking it via m_source.isEmpty(). Change-Id: I120cb3728504b2bbc77d5959711a3f94731399ce Reviewed-by: Mike Krus <mike.krus@kdab.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/animation/animationcliploader/tst_animationcliploader.cpp1
-rw-r--r--tests/auto/animation/animationutils/tst_animationutils.cpp5
2 files changed, 6 insertions, 0 deletions
diff --git a/tests/auto/animation/animationcliploader/tst_animationcliploader.cpp b/tests/auto/animation/animationcliploader/tst_animationcliploader.cpp
index 35c0d5e54..09798e7d6 100644
--- a/tests/auto/animation/animationcliploader/tst_animationcliploader.cpp
+++ b/tests/auto/animation/animationcliploader/tst_animationcliploader.cpp
@@ -97,6 +97,7 @@ private Q_SLOTS:
Qt3DAnimation::Animation::AnimationClipLoader backendClip;
Qt3DAnimation::Animation::Handler handler;
backendClip.setHandler(&handler);
+ backendClip.setDataType(Qt3DAnimation::Animation::AnimationClipLoader::File);
Qt3DCore::QPropertyUpdatedChangePtr updateChange;
// WHEN
diff --git a/tests/auto/animation/animationutils/tst_animationutils.cpp b/tests/auto/animation/animationutils/tst_animationutils.cpp
index 17815f5db..282ceb829 100644
--- a/tests/auto/animation/animationutils/tst_animationutils.cpp
+++ b/tests/auto/animation/animationutils/tst_animationutils.cpp
@@ -163,6 +163,7 @@ public:
auto clipId = Qt3DCore::QNodeId::createId();
AnimationClipLoader *clip = handler->animationClipLoaderManager()->getOrCreateResource(clipId);
setPeerId(clip, clipId);
+ clip->setDataType(AnimationClipLoader::File);
clip->setSource(source);
clip->loadAnimation();
return clip;
@@ -2367,6 +2368,7 @@ private Q_SLOTS:
targetIndices.push_back({ 11 });
auto *clip = new AnimationClipLoader();
+ clip->setDataType(AnimationClipLoader::File);
clip->setSource(QUrl("qrc:/clip3.json"));
clip->loadAnimation();
@@ -2396,6 +2398,7 @@ private Q_SLOTS:
targetIndices.push_back({ 11 });
auto *clip = new AnimationClipLoader();
+ clip->setDataType(AnimationClipLoader::File);
clip->setSource(QUrl("qrc:/clip3.json"));
clip->loadAnimation();
@@ -2425,6 +2428,7 @@ private Q_SLOTS:
targetIndices.push_back({ 11 });
auto *clip = new AnimationClipLoader();
+ clip->setDataType(AnimationClipLoader::File);
clip->setSource(QUrl("qrc:/clip3.json"));
clip->loadAnimation();
@@ -2454,6 +2458,7 @@ private Q_SLOTS:
targetIndices.push_back({ 11 });
auto *clip = new AnimationClipLoader();
+ clip->setDataType(AnimationClipLoader::File);
clip->setSource(QUrl("qrc:/clip3.json"));
clip->loadAnimation();