integration tests
This commit is contained in:
@@ -92,4 +92,9 @@ export class InMemoryLeagueMembershipRepository implements LeagueMembershipRepos
|
||||
}
|
||||
return Promise.resolve();
|
||||
}
|
||||
|
||||
clear(): void {
|
||||
this.memberships.clear();
|
||||
this.joinRequests.clear();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,6 +14,10 @@ export class InMemoryLeagueRepository implements LeagueRepository {
|
||||
this.logger.info('InMemoryLeagueRepository initialized');
|
||||
}
|
||||
|
||||
clear(): void {
|
||||
this.leagues.clear();
|
||||
}
|
||||
|
||||
async findById(id: string): Promise<League | null> {
|
||||
this.logger.debug(`Attempting to find league with ID: ${id}.`);
|
||||
try {
|
||||
|
||||
@@ -105,4 +105,8 @@ export class InMemoryRaceRepository implements RaceRepository {
|
||||
this.logger.debug(`[InMemoryRaceRepository] Checking existence of race with ID: ${id}.`);
|
||||
return Promise.resolve(this.races.has(id));
|
||||
}
|
||||
|
||||
clear(): void {
|
||||
this.races.clear();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -83,4 +83,8 @@ export class InMemorySeasonRepository implements SeasonRepository {
|
||||
);
|
||||
return Promise.resolve(activeSeasons);
|
||||
}
|
||||
|
||||
clear(): void {
|
||||
this.seasons.clear();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -95,4 +95,9 @@ export class InMemorySponsorRepository implements SponsorRepository {
|
||||
this.logger.debug(`[InMemorySponsorRepository] Checking existence of sponsor with ID: ${id}`);
|
||||
return Promise.resolve(this.sponsors.has(id));
|
||||
}
|
||||
|
||||
clear(): void {
|
||||
this.sponsors.clear();
|
||||
this.emailIndex.clear();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -109,4 +109,8 @@ export class InMemorySponsorshipRequestRepository implements SponsorshipRequestR
|
||||
this.logger.debug(`[InMemorySponsorshipRequestRepository] Checking existence of request with ID: ${id}.`);
|
||||
return Promise.resolve(this.requests.has(id));
|
||||
}
|
||||
|
||||
clear(): void {
|
||||
this.requests.clear();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user