mirror of
https://github.com/bdunderscore/modular-avatar.git
synced 2025-01-17 20:00:06 +08:00
c454bc1ed8
* Add integration test for blendshape sync * fix: blendshape sync not being processed This change refactors AnimationDatabase to be part of the same extension context as the TrackObjectRenames functionality (which is renamed back to PathMappings). This then allows us to sequence deactivation of this context to come after blendshape processing completes. Fixes: #461
27 lines
987 B
C#
27 lines
987 B
C#
using nadena.dev.ndmf;
|
|
using nadena.dev.modular_avatar.animation;
|
|
using NUnit.Framework;
|
|
using UnityEditor;
|
|
|
|
namespace modular_avatar_tests
|
|
{
|
|
public class MiscAnimationTests : TestBase
|
|
{
|
|
[Test]
|
|
public void HighQualityCurvesSettingPreserved()
|
|
{
|
|
var prefab = CreatePrefab("HighQualityCurvesSettingPreserved.prefab");
|
|
var context = new BuildContext(prefab, null);
|
|
context.ActivateExtensionContext<AnimationServicesContext>();
|
|
context.DeactivateExtensionContext<AnimationServicesContext>();
|
|
|
|
var layer = findFxLayer(prefab, "Base Layer");
|
|
|
|
var hq_on = FindStateInLayer(layer, "HQ_ON");
|
|
var hq_off = FindStateInLayer(layer, "HQ_OFF");
|
|
|
|
Assert.True(new SerializedObject(hq_on.motion).FindProperty("m_UseHighQualityCurve").boolValue);
|
|
Assert.False(new SerializedObject(hq_off.motion).FindProperty("m_UseHighQualityCurve").boolValue);
|
|
}
|
|
}
|
|
} |