Resolve WES-133 "Multiple choice"
This commit is contained in:
committed by
Jelle De Geest
parent
04d9a4bf2b
commit
4e9d801e61
@@ -139,6 +139,20 @@ public class UserTest
|
||||
Assert.AreEqual(q.progress, 3.14159265f);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Test progress of a course is correctly reset (aka removed)
|
||||
/// </summary>
|
||||
[Test]
|
||||
public void Test_User_ResetCourseProgres()
|
||||
{
|
||||
var p = new PersistentDataController.SavedCourseProgress();
|
||||
p.courseIndex = CourseIndex.FINGERSPELLING;
|
||||
user.AddCourseProgress(p);
|
||||
Assert.IsNotNull(user.GetCourseProgress(CourseIndex.FINGERSPELLING));
|
||||
user.ResetCourseProgress(CourseIndex.FINGERSPELLING);
|
||||
Assert.IsNull(user.GetCourseProgress(CourseIndex.FINGERSPELLING));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Test GetMinigameProgress returns null when minigame cannot be found
|
||||
/// </summary>
|
||||
@@ -168,4 +182,18 @@ public class UserTest
|
||||
Assert.Zero(q.latestScores.Count);
|
||||
Assert.Zero(q.highestScores.Count);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Test progress of a minigame is correctly reset (aka removed)
|
||||
/// </summary>
|
||||
[Test]
|
||||
public void Test_User_ResetMinigameProgres()
|
||||
{
|
||||
var p = new PersistentDataController.SavedMinigameProgress();
|
||||
p.minigameIndex = MinigameIndex.SPELLING_BEE;
|
||||
user.AddMinigameProgress(p);
|
||||
Assert.IsNotNull(user.GetMinigameProgress(MinigameIndex.SPELLING_BEE));
|
||||
user.ResetMinigameProgress(MinigameIndex.SPELLING_BEE);
|
||||
Assert.IsNull(user.GetMinigameProgress(MinigameIndex.SPELLING_BEE));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user