fix: reject ambiguous Riot winner evidence

This commit is contained in:
dahyeon committed 2026-07-12 20:08:12 +00:00
1 parent 575cd911cb
commit 6aa2cb9009
2 files changed
+22 -1

No files matched your search

@@ -211,6 +211,22 @@ describe('Competition result Riot mapping', () => {
).toBeNull();
});
it('rejects inconsistent Riot evidence with more than one winning team', () => {
const { competition, detail, lookup } = fixture();
detail.info.teams.forEach((team) => {
team.win = true;
});
expect(
mapRiotGameToCompetitionSlot({
competition,
target: competition.projection.gameSlots[0],
detail,
lookup,
}),
).toBeNull();
});
it('orders collected Riot games by occurrence before first-to projection', () => {
const { detail } = fixture();
const later = {