forked from PlebeiusGaragicus/VibeReaderTwo
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest-logging.sh
More file actions
executable file
Β·45 lines (37 loc) Β· 1.25 KB
/
test-logging.sh
File metadata and controls
executable file
Β·45 lines (37 loc) Β· 1.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#!/bin/bash
# Test the logging system
echo "π§ͺ Testing VibeReader Logging System"
echo ""
# Check if backend is running
echo "1. Checking if backend is running..."
if curl -s http://localhost:8000/health > /dev/null 2>&1; then
echo " β Backend is running"
else
echo " β Backend is not running"
echo " Start it with: ./start-dev.sh (option 1)"
exit 1
fi
echo ""
echo "2. Testing API endpoints..."
# Test health endpoint
echo " Testing /health..."
curl -s http://localhost:8000/health | jq '.' || echo " (Install jq for pretty output)"
# Test books endpoint
echo ""
echo " Testing /api/books..."
curl -s http://localhost:8000/api/books | jq 'length' || echo " (Install jq for pretty output)"
echo ""
echo "3. Check backend logs in the terminal where you started the backend"
echo " You should see:"
echo " β GET /health"
echo " β GET /health β 200 (Xms)"
echo " β GET /api/books"
echo " β GET /api/books β 200 (Xms)"
echo ""
echo "4. Frontend logging test:"
echo " - Open the app in Electron or browser"
echo " - Open DevTools (Cmd+Option+I)"
echo " - In console, run: vibeDiagnostics.runDiagnostics()"
echo " - You should see detailed diagnostic output"
echo ""
echo "β Logging system test complete!"