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()
168
168
GazeProvider gazeProvider = CoreServices . InputSystem . GazeProvider . GameObjectReference . GetComponent < GazeProvider > ( ) ;
169
169
gazeProvider . GazePointer . BaseCursor . Destroy ( ) ;
170
170
DebugUtilities . LogVerbose ( "Application was playing, destroyed the gaze pointer's BaseCursor" ) ;
171
- UnityObjectExtensions . DestroyObject ( gazeProvider as Component ) ;
171
+ UnityObjectExtensions . DestroyObject ( gazeProvider ) ;
172
172
gazeProvider = null ;
173
173
174
174
// 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()
201
201
Assert . IsTrue ( focusProvider . TryGetFocusDetails ( pointer , out focusDetails ) ) ;
202
202
Assert . IsNull ( focusDetails . Object ) ;
203
203
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
+ } ;
208
210
Assert . IsTrue ( focusProvider . TryOverrideFocusDetails ( pointer , newFocusDetails ) ) ;
209
211
210
212
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
23
23
public class JoystickTests : BasePlayModeTests
24
24
{
25
25
#region Tests
26
+
26
27
[ UnityTest ]
27
28
public IEnumerator TestJoystickTranslation ( )
28
29
{
@@ -133,9 +134,11 @@ public IEnumerator TestJoystickScale()
133
134
134
135
Assert . IsTrue ( startScale != endScale ) ;
135
136
}
137
+
136
138
#endregion Tests
137
139
138
140
#region Utilities
141
+
139
142
public readonly string JoystickPrefabAssetPath = AssetDatabase . GUIDToAssetPath ( JoystickPrefabGuid ) ;
140
143
141
144
// Examples/Experimental/Joystick/JoystickPrefab.prefab
@@ -168,6 +171,7 @@ private GameObject InstantiatePrefabFromPath(string path)
168
171
Assert . IsNotNull ( joystick ) ;
169
172
return joystick ;
170
173
}
174
+
171
175
#endregion Utilities
172
176
}
173
177
}
You can’t perform that action at this time.
0 commit comments