fix(tours): keep the bike paints, classes and costing to their modules, and pin the profile column to the contract

This commit is contained in:
Maurice
2026-10-19 22:15:22 +02:00
parent b374fdc989
commit f3a39d9452
5 changed files with 22 additions and 6 deletions
@@ -0,0 +1,16 @@
import { ToursBikeProfile } from '../../../src/db/entities/Tours.entity';
import { BIKE_PROFILES } from '@trek/shared';
import { describe, expect, it } from 'vitest';
/**
* BIK-01: the bike profile column holds a CHECK list (migration 045200) that
* the entity carries as its enum, and the contract holds its own list. A
* profile one side knows and the other refuses would be a tour the planner
* can save and the database cannot store.
*/
describe('bike profile column matches the contract', () => {
it('knows the same profiles as the bike contract', () => {
expect(Object.values(ToursBikeProfile).sort()).toEqual([...BIKE_PROFILES].sort());
});
});