-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest.sh
More file actions
57 lines (49 loc) · 1.33 KB
/
Copy pathtest.sh
File metadata and controls
57 lines (49 loc) · 1.33 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
46
47
48
49
50
51
52
53
54
55
56
57
#!/bin/bash
# 设置中文编码
export LANG=zh_CN.UTF-8
export LC_ALL=zh_CN.UTF-8
# 颜色定义
RED='\033[0;31m'
GREEN='\033[0;32m'
BLUE='\033[0;34m'
NC='\033[0m' # No Color
echo -e "${BLUE}========================================"
echo "Express Delivery System - Test"
echo -e "========================================${NC}"
echo
echo "Current Directory: $(pwd)"
echo "Current Time: $(date)"
echo
echo "Testing basic functionality..."
echo
echo "[1/3] Checking Node.js..."
if command -v node &> /dev/null; then
echo -e "${GREEN}SUCCESS: Node.js is installed${NC}"
else
echo -e "${RED}ERROR: Node.js not found${NC}"
fi
echo
echo "[2/3] Checking project files..."
if [ -d "backend" ]; then
echo -e "${GREEN}SUCCESS: backend directory exists${NC}"
else
echo -e "${RED}ERROR: backend directory not found${NC}"
fi
if [ -f "backend/package.json" ]; then
echo -e "${GREEN}SUCCESS: package.json exists${NC}"
else
echo -e "${RED}ERROR: package.json not found${NC}"
fi
echo
echo "[3/3] Checking MySQL..."
if command -v mysql &> /dev/null; then
echo -e "${GREEN}SUCCESS: MySQL is installed${NC}"
else
echo -e "${RED}ERROR: MySQL not found${NC}"
fi
echo
echo -e "${BLUE}========================================"
echo "Test completed!"
echo -e "========================================${NC}"
echo
read -p "Press Enter to exit..."