File tree Expand file tree Collapse file tree 2 files changed +11
-5
lines changed
Assets/MRTK/Tests/PlayModeTests Expand file tree Collapse file tree 2 files changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -168,7 +168,7 @@ public IEnumerator TestGazeProviderDestroyed()
168168 GazeProvider gazeProvider = CoreServices . InputSystem . GazeProvider . GameObjectReference . GetComponent < GazeProvider > ( ) ;
169169 gazeProvider . GazePointer . BaseCursor . Destroy ( ) ;
170170 DebugUtilities . LogVerbose ( "Application was playing, destroyed the gaze pointer's BaseCursor" ) ;
171- UnityObjectExtensions . DestroyObject ( gazeProvider as Component ) ;
171+ UnityObjectExtensions . DestroyObject ( gazeProvider ) ;
172172 gazeProvider = null ;
173173
174174 // Ensure that the input system and it's related input sources are able to be reinitialized without issue.
@@ -201,10 +201,12 @@ public IEnumerator TestOverrideFocusDetails()
201201 Assert . IsTrue ( focusProvider . TryGetFocusDetails ( pointer , out focusDetails ) ) ;
202202 Assert . IsNull ( focusDetails . Object ) ;
203203
204- var newFocusDetails = new Physics . FocusDetails ( ) ;
205- newFocusDetails . Object = cube ;
206- newFocusDetails . RayDistance = 10 ;
207- newFocusDetails . Point = new Vector3 ( 1 , 2 , 3 ) ;
204+ var newFocusDetails = new Physics . FocusDetails
205+ {
206+ Object = cube ,
207+ RayDistance = 10 ,
208+ Point = new Vector3 ( 1 , 2 , 3 )
209+ } ;
208210 Assert . IsTrue ( focusProvider . TryOverrideFocusDetails ( pointer , newFocusDetails ) ) ;
209211
210212 Assert . IsTrue ( focusProvider . TryGetFocusDetails ( pointer , out focusDetails ) ) ;
Original file line number Diff line number Diff line change @@ -23,6 +23,7 @@ namespace Microsoft.MixedReality.Toolkit.Tests
2323 public class JoystickTests : BasePlayModeTests
2424 {
2525 #region Tests
26+
2627 [ UnityTest ]
2728 public IEnumerator TestJoystickTranslation ( )
2829 {
@@ -133,9 +134,11 @@ public IEnumerator TestJoystickScale()
133134
134135 Assert . IsTrue ( startScale != endScale ) ;
135136 }
137+
136138 #endregion Tests
137139
138140 #region Utilities
141+
139142 public readonly string JoystickPrefabAssetPath = AssetDatabase . GUIDToAssetPath ( JoystickPrefabGuid ) ;
140143
141144 // Examples/Experimental/Joystick/JoystickPrefab.prefab
@@ -168,6 +171,7 @@ private GameObject InstantiatePrefabFromPath(string path)
168171 Assert . IsNotNull ( joystick ) ;
169172 return joystick ;
170173 }
174+
171175 #endregion Utilities
172176 }
173177}
You can’t perform that action at this time.
0 commit comments