refactor
This commit is contained in:
@@ -44,7 +44,7 @@ describe('FileProtestUseCase', () => {
|
||||
});
|
||||
|
||||
expect(result.isOk()).toBe(false);
|
||||
expect(result.error!.message).toBe('Race not found');
|
||||
expect(result.error!.details.message).toBe('Race not found');
|
||||
});
|
||||
|
||||
it('should return error when protesting against self', async () => {
|
||||
@@ -64,7 +64,7 @@ describe('FileProtestUseCase', () => {
|
||||
});
|
||||
|
||||
expect(result.isOk()).toBe(false);
|
||||
expect(result.error!.message).toBe('Cannot file a protest against yourself');
|
||||
expect(result.error!.details.message).toBe('Cannot file a protest against yourself');
|
||||
});
|
||||
|
||||
it('should return error when protesting driver is not an active member', async () => {
|
||||
@@ -87,7 +87,7 @@ describe('FileProtestUseCase', () => {
|
||||
});
|
||||
|
||||
expect(result.isOk()).toBe(false);
|
||||
expect(result.error!.message).toBe('Protesting driver is not an active member of this league');
|
||||
expect(result.error!.details.message).toBe('Protesting driver is not an active member of this league');
|
||||
});
|
||||
|
||||
it('should create protest and return protestId on success', async () => {
|
||||
|
||||
Reference in New Issue
Block a user