mirror of
https://github.com/zkldi/Tachi.git
synced 2026-10-11 16:58:25 +03:00
Fix tests that no longer pass due to testdata change
This commit is contained in:
@@ -11,7 +11,7 @@ t.test("GET /api/v1/games/:game/:playtype/songs/:songID", (t) => {
|
||||
t.test("Should return the song at this ID and all of its charts.", async (t) => {
|
||||
const res = await mockApi.get("/api/v1/games/iidx/SP/songs/1");
|
||||
|
||||
t.equal(res.body.body.charts.length, 14);
|
||||
t.equal(res.body.body.charts.length, 4);
|
||||
|
||||
t.equal(res.body.body.song.id, 1);
|
||||
|
||||
|
||||
+13
-1
@@ -112,9 +112,15 @@ t.test("GET /api/v1/users/:userID/games/:game/:playtype/pbs", (t) => {
|
||||
|
||||
t.hasStrict(res.body, {
|
||||
success: true,
|
||||
description: "Retrieved 2 personal bests.",
|
||||
description: "Retrieved 4 personal bests.",
|
||||
body: {
|
||||
pbs: [
|
||||
{
|
||||
chartID: "71865a2b6d3581decf076ae83c6621302c4bb271",
|
||||
},
|
||||
{
|
||||
chartID: "952805894d7d78257e87019426fa1d87aec834a5",
|
||||
},
|
||||
{
|
||||
chartID: "c2311194e3897ddb5745b1760d2c0141f933e683",
|
||||
},
|
||||
@@ -131,9 +137,15 @@ t.test("GET /api/v1/users/:userID/games/:game/:playtype/pbs", (t) => {
|
||||
{
|
||||
chartID: "c2311194e3897ddb5745b1760d2c0141f933e683",
|
||||
},
|
||||
{
|
||||
chartID: "71865a2b6d3581decf076ae83c6621302c4bb271",
|
||||
},
|
||||
{
|
||||
chartID: "c641238220d73faf82659513ba03bde71b0b45f0",
|
||||
},
|
||||
{
|
||||
chartID: "952805894d7d78257e87019426fa1d87aec834a5",
|
||||
},
|
||||
],
|
||||
},
|
||||
});
|
||||
|
||||
+3
-3
@@ -111,13 +111,13 @@ t.test("GET /api/v1/users/:userID/games/:game/:playtype/scores", (t) => {
|
||||
"/api/v1/users/test_zkldi/games/iidx/SP/scores?search=5.1.1."
|
||||
);
|
||||
|
||||
t.equal(res.body.body.scores.length, 3);
|
||||
t.equal(res.body.body.scores.length, 5);
|
||||
t.equal(res.body.body.songs.length, 1);
|
||||
t.equal(res.body.body.charts.length, 2);
|
||||
t.equal(res.body.body.charts.length, 4);
|
||||
|
||||
t.hasStrict(res.body, {
|
||||
success: true,
|
||||
description: "Retrieved 3 scores.",
|
||||
description: "Retrieved 5 scores.",
|
||||
body: {
|
||||
scores: [
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user