Scope live chat to the current match and save match history
This commit is contained in:
@@ -38,7 +38,8 @@ describe('completed match details', () => {
|
||||
await report('game_end', 4, [player('101', { kills: 50, headshots: 20, downs: 2, revives: 3, score: 500 }), player('404')]);
|
||||
const { getMatchDetail, serverMatchHistory } = await import('../../src/lib/server/fleet/match-history.js');
|
||||
const match = getMatchDetail(1)!;
|
||||
const { game, startObserved, players, ...summary } = match;
|
||||
const { game, startObserved, players, chat, ...summary } = match;
|
||||
expect(chat).toEqual([]);
|
||||
expect({ ...summary, game }).toEqual(serverMatchHistory(server).matches[0]);
|
||||
expect({ ...summary, game, startObserved }).toMatchObject({
|
||||
id: 1, game: 't5', startObserved: true, server, status: 'completed',
|
||||
|
||||
Reference in New Issue
Block a user