Make test scene loading not depending on build settings
This commit is contained in:
parent
0a01cee64b
commit
7496bc6e2a
@ -1,5 +1,4 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using UnityEngine.SceneManagement;
|
||||
using UnityEngine.TestTools;
|
||||
@ -9,16 +8,15 @@ using NUnit.Framework;
|
||||
namespace Passer.Humanoid {
|
||||
|
||||
public class Sites_Test {
|
||||
public void Setup() {
|
||||
UnityEngine.SceneManagement.SceneManager.LoadScene("HumanoidControl/Runtime/Visitors/HumanoidVisitor Desktop");
|
||||
[UnitySetUp]
|
||||
public IEnumerator Setup() {
|
||||
Scene x = UnityEditor.SceneManagement.EditorSceneManager.LoadSceneInPlayMode("Packages/HumanoidControl4_Free/Tests/Runtime/Sites/[Test]HumanoidVisitor Desktop.unity", new LoadSceneParameters(LoadSceneMode.Single));
|
||||
yield return new WaitForSeconds(0.1F);
|
||||
}
|
||||
|
||||
[UnityTest]
|
||||
[Category("Sites")]
|
||||
public IEnumerator VisitShootingRange() {
|
||||
Setup();
|
||||
yield return new WaitForSeconds(1);
|
||||
|
||||
HumanoidControl humanoid = Object.FindObjectOfType<HumanoidControl>();
|
||||
Assert.IsFalse(humanoid == null);
|
||||
|
||||
@ -48,9 +46,6 @@ namespace Passer.Humanoid {
|
||||
[UnityTest]
|
||||
[Category("Sites")]
|
||||
public IEnumerator VisitSocialSpace() {
|
||||
Setup();
|
||||
yield return new WaitForSeconds(1);
|
||||
|
||||
HumanoidControl humanoid = Object.FindObjectOfType<HumanoidControl>();
|
||||
Assert.IsFalse(humanoid == null);
|
||||
|
||||
@ -80,9 +75,6 @@ namespace Passer.Humanoid {
|
||||
[UnityTest]
|
||||
[Category("Sites")]
|
||||
public IEnumerator VisitAvatarShop() {
|
||||
Setup();
|
||||
yield return new WaitForSeconds(1);
|
||||
|
||||
HumanoidControl humanoid = Object.FindObjectOfType<HumanoidControl>();
|
||||
Assert.IsFalse(humanoid == null);
|
||||
|
||||
@ -113,9 +105,6 @@ namespace Passer.Humanoid {
|
||||
[UnityTest]
|
||||
[Category("Sites")]
|
||||
public IEnumerator VisitGroceryStore() {
|
||||
Setup();
|
||||
yield return new WaitForSeconds(1);
|
||||
|
||||
HumanoidControl humanoid = Object.FindObjectOfType<HumanoidControl>();
|
||||
Assert.IsFalse(humanoid == null);
|
||||
|
||||
@ -145,9 +134,6 @@ namespace Passer.Humanoid {
|
||||
[UnityTest]
|
||||
[Category("Sites")]
|
||||
public IEnumerator VisitTour() {
|
||||
Setup();
|
||||
yield return new WaitForSeconds(1);
|
||||
|
||||
HumanoidControl humanoid = Object.FindObjectOfType<HumanoidControl>();
|
||||
Assert.IsFalse(humanoid == null);
|
||||
|
||||
|
10863
Tests/Runtime/Sites/[Test]HumanoidVisitor Desktop.unity
Normal file
10863
Tests/Runtime/Sites/[Test]HumanoidVisitor Desktop.unity
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a4835864fc49f2d4db65d3a6e0324450
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Loading…
x
Reference in New Issue
Block a user