removed cron job that made rentals active. Now whether or not the rental is active is determined on the fly

This commit is contained in:
jackiettran
2026-01-02 17:08:49 -05:00
parent bc01c818aa
commit 4209dcc8fc
17 changed files with 142 additions and 162 deletions

View File

@@ -10,6 +10,7 @@ describe('ConditionCheckService', () => {
describe('submitConditionCheck', () => {
// Set rental dates relative to current time for valid time window
// Active status is computed: confirmed + startDateTime in the past
const now = new Date();
const mockRental = {
id: 'rental-123',
@@ -17,7 +18,7 @@ describe('ConditionCheckService', () => {
renterId: 'renter-789',
startDateTime: new Date(now.getTime() - 1000 * 60 * 60), // 1 hour ago
endDateTime: new Date(now.getTime() + 1000 * 60 * 60 * 24), // 24 hours from now
status: 'active'
status: 'confirmed' // Will be computed as "active" since startDateTime is in the past
};
const mockPhotos = ['/uploads/photo1.jpg', '/uploads/photo2.jpg'];