Skip to content

Commit

Permalink
FBX-450 update obsolete function (#689)
Browse files Browse the repository at this point in the history
* test update in test

* update other function as well
  • Loading branch information
vkovec authored Jan 13, 2023
1 parent 5615116 commit 6904be2
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions com.unity.formats.fbx/Tests/FbxTests/ModelExporterTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,17 @@ public void TestBasics()
var character = new GameObject();
var smr = character.AddComponent<SkinnedMeshRenderer>();
smr.sharedMesh = cube.GetComponent<MeshFilter>().sharedMesh;
#if UNITY_2023_1_OR_NEWER
var meshCount = Object.FindObjectsByType<Mesh>(FindObjectsSortMode.None).Length;
#else // UNITY_2023_1_OR_NEWER
var meshCount = Object.FindObjectsOfType<Mesh>().Length;
#endif // UNITY_2023_1_OR_NEWER
ModelExporter.ExportObject(GetRandomFbxFilePath(), character);
#if UNITY_2023_1_OR_NEWER
Assert.AreEqual(meshCount, Object.FindObjectsByType<Mesh>(FindObjectsSortMode.None).Length);
#else // UNITY_2023_1_OR_NEWER
Assert.AreEqual(meshCount, Object.FindObjectsOfType<Mesh>().Length);
#endif // UNITY_2023_1_OR_NEWER
}

// Test euler to quaternion conversion
Expand Down

0 comments on commit 6904be2

Please sign in to comment.