common tests fix
This commit is contained in:
@@ -15,7 +15,7 @@ public class BackButtonTests
|
||||
[UnitySetUp]
|
||||
public IEnumerator SetupFunction()
|
||||
{
|
||||
string path = Path.Combine("Assets", "users.json");
|
||||
string path = $"{Application.persistentDataPath}/users.json";
|
||||
var oneUser = "{\"currentUserIndex\": 0,\"storedUsers\": [{\"username\": \"TEST\",\"avatar\": {\"instanceID\": 40848},\"playtime\": 0.0,\"courses\": [],\"minigames\": []}]}";
|
||||
|
||||
using (StreamWriter writer = new StreamWriter(path))
|
||||
|
||||
@@ -15,7 +15,7 @@ public class CourseActivityTests
|
||||
[UnitySetUp]
|
||||
public IEnumerator SetupFunction()
|
||||
{
|
||||
string path = Path.Combine("Assets", "users.json");
|
||||
string path = $"{Application.persistentDataPath}/users.json";
|
||||
var oneUser = "{\"currentUserIndex\": 0,\"storedUsers\": [{\"username\": \"TEST\",\"avatar\": {\"instanceID\": 40848},\"playtime\": 0.0,\"courses\": [],\"minigames\": []}]}";
|
||||
|
||||
using (StreamWriter writer = new StreamWriter(path))
|
||||
|
||||
@@ -15,7 +15,7 @@ public class CourseMenuScreenTest
|
||||
[UnitySetUp]
|
||||
public IEnumerator SetupFunction()
|
||||
{
|
||||
string path = Path.Combine("Assets", "users.json");
|
||||
string path = $"{Application.persistentDataPath}/users.json";
|
||||
var oneUser = "{\"currentUserIndex\": 0,\"storedUsers\": [{\"username\": \"TEST\",\"avatar\": {\"instanceID\": 40848},\"playtime\": 0.0,\"courses\": [],\"minigames\": []}]}";
|
||||
|
||||
using (StreamWriter writer = new StreamWriter(path))
|
||||
|
||||
@@ -15,7 +15,7 @@ public class ListCoursesScreenTest
|
||||
[UnitySetUp]
|
||||
public IEnumerator SetupFunction()
|
||||
{
|
||||
string path = Path.Combine("Assets", "users.json");
|
||||
string path = $"{Application.persistentDataPath}/users.json";
|
||||
var oneUser = "{\"currentUserIndex\": 0,\"storedUsers\": [{\"username\": \"TEST\",\"avatar\": {\"instanceID\": 40848},\"playtime\": 0.0,\"courses\": [],\"minigames\": []}]}";
|
||||
|
||||
using (StreamWriter writer = new StreamWriter(path))
|
||||
|
||||
@@ -15,7 +15,7 @@ public class MainMenuScreenTests
|
||||
[UnitySetUp]
|
||||
public IEnumerator SetupFunction()
|
||||
{
|
||||
string path = Path.Combine("Assets", "users.json");
|
||||
string path = $"{Application.persistentDataPath}/users.json";
|
||||
var oneUser = "{\"currentUserIndex\": 0,\"storedUsers\": [{\"username\": \"TEST\",\"avatar\": {\"instanceID\": 40848},\"playtime\": 0.0,\"courses\": [],\"minigames\": []}]}";
|
||||
|
||||
using (StreamWriter writer = new StreamWriter(path))
|
||||
|
||||
@@ -15,7 +15,7 @@ public class MiniGameActivityScreenTests
|
||||
[UnitySetUp]
|
||||
public IEnumerator SetupFunction()
|
||||
{
|
||||
string path = Path.Combine("Assets", "users.json");
|
||||
string path = $"{Application.persistentDataPath}/users.json";
|
||||
var oneUser = "{\"currentUserIndex\": 0,\"storedUsers\": [{\"username\": \"TEST\",\"avatar\": {\"instanceID\": 40848},\"playtime\": 0.0,\"courses\": [],\"minigames\": []}]}";
|
||||
|
||||
using (StreamWriter writer = new StreamWriter(path))
|
||||
|
||||
@@ -16,7 +16,7 @@ public class StartGamesTests
|
||||
[UnityTest]
|
||||
public IEnumerator BootWithUsersTest()
|
||||
{
|
||||
string path = Path.Combine("Assets", "users.json");
|
||||
string path = $"{Application.persistentDataPath}/users.json";
|
||||
var oneUser = "{\"currentUserIndex\": 0,\"storedUsers\": [{\"username\": \"TEST\",\"avatar\": {\"instanceID\": 40848},\"playtime\": 0.0,\"courses\": [],\"minigames\": []}]}";
|
||||
|
||||
using (StreamWriter writer = new StreamWriter(path))
|
||||
@@ -62,7 +62,7 @@ public class StartGamesTests
|
||||
public IEnumerator BootWithoutUsersTest()
|
||||
{
|
||||
// Arrange
|
||||
string path = Path.Combine("Assets", "users.json");
|
||||
string path = $"{Application.persistentDataPath}/users.json";
|
||||
var oneUser = "{}";
|
||||
|
||||
using (StreamWriter writer = new StreamWriter(path))
|
||||
|
||||
@@ -15,7 +15,7 @@ public class UserButtonTests
|
||||
[UnitySetUp]
|
||||
public IEnumerator SetupFunction()
|
||||
{
|
||||
string path = Path.Combine("Assets", "users.json");
|
||||
string path = $"{Application.persistentDataPath}/users.json";
|
||||
var oneUser = "{\"currentUserIndex\": 0,\"storedUsers\": [{\"username\": \"TEST\",\"avatar\": {\"instanceID\": 40848},\"playtime\": 0.0,\"courses\": [],\"minigames\": []}]}";
|
||||
|
||||
using (StreamWriter writer = new StreamWriter(path))
|
||||
|
||||
Reference in New Issue
Block a user