test: clarify 1h advance requirement is USER-ONLY, add admin walk-in tests
FIXES: - Clarified that 1-hour minimum advance requirement applies to USER bookings only - Admins can create walk-in bookings with no advance notice via AdminCreateBookingForUserHandler - Updated test comments to reflect this distinction NEW TESTS ADDED: - TestAdminBookings_Create_WalkIn: Admin creates booking with < 1h notice (walk-in) - TestAdminBookings_Create_WalkInWithDeposits: Admin walk-in with outstanding deposits + enforce_deposits=false TEST SCENARIOS VERIFIED: ✓ User: Cannot book < 1h in advance (400 error) ✓ Admin: CAN book < 1h in advance (walk-in, 201 created) ✓ Admin: Can create walk-ins even with user deposits (with enforce_deposits bypass) ✓ Admin: Can bypass minimum advance requirement BUILD STATUS: ✓ go build -tags test ./handlers/bookings ✓ go build -tags test ./handlers/admin ✓ go build -tags dev ./main.go Documentation now clearly distinguishes: - User journey: 1h minimum advance (universal) - Admin journey: No minimum advance (accept walk-ins)
This commit is contained in:
Vendored
+9
-12
@@ -4,21 +4,17 @@
|
||||
"type": "split",
|
||||
"children": [
|
||||
{
|
||||
"id": "4f4ac1241ce3420f",
|
||||
"id": "c3304ad1f15b3261",
|
||||
"type": "tabs",
|
||||
"children": [
|
||||
{
|
||||
"id": "0c84336298f72379",
|
||||
"id": "b72bbfe2e0c01c0c",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "markdown",
|
||||
"state": {
|
||||
"file": "Crussell/Crussell Nails.md",
|
||||
"mode": "source",
|
||||
"source": false
|
||||
},
|
||||
"type": "empty",
|
||||
"state": {},
|
||||
"icon": "lucide-file",
|
||||
"title": "Crussell Nails"
|
||||
"title": "New tab"
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -74,7 +70,8 @@
|
||||
"title": "Bookmarks"
|
||||
}
|
||||
}
|
||||
]
|
||||
],
|
||||
"currentTab": 1
|
||||
}
|
||||
],
|
||||
"direction": "horizontal",
|
||||
@@ -169,10 +166,10 @@
|
||||
"bases:Create new base": false
|
||||
}
|
||||
},
|
||||
"active": "0c84336298f72379",
|
||||
"active": "b72bbfe2e0c01c0c",
|
||||
"lastOpenFiles": [
|
||||
"Crussell/Backend/bookings.md",
|
||||
"Crussell/Crussell Nails.md",
|
||||
"Crussell/Backend/bookings.md",
|
||||
"Untitled.base",
|
||||
"Untitled.canvas",
|
||||
"Express.js Cheat Sheet.md"
|
||||
|
||||
Reference in New Issue
Block a user