-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.test
More file actions
127 lines (95 loc) · 3.88 KB
/
Copy path.env.test
File metadata and controls
127 lines (95 loc) · 3.88 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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
# Test Environment Variables for RottenStocks
# Used for running tests and CI/CD
# =============================================================================
# Test Environment Settings
# =============================================================================
ENVIRONMENT=test
DEBUG=false
LOG_LEVEL=WARNING
# =============================================================================
# Test Database Configuration
# =============================================================================
# Test database (automatically created/destroyed)
DATABASE_URL=postgresql://postgres:postgres@localhost:5432/rottenstocks_test
TEST_DATABASE_URL=postgresql://postgres:postgres@localhost:5432/rottenstocks_test
# Smaller connection pool for tests
DB_POOL_SIZE=5
DB_MAX_OVERFLOW=10
DB_POOL_TIMEOUT=10
# =============================================================================
# Test Redis Configuration
# =============================================================================
# Test Redis (use different DB to avoid conflicts)
REDIS_URL=redis://localhost:6379/15
TEST_REDIS_URL=redis://localhost:6379/15
REDIS_POOL_SIZE=5
REDIS_TIMEOUT=3
# =============================================================================
# Test API Keys (Mock Values)
# =============================================================================
# Mock Reddit API credentials
REDDIT_CLIENT_ID=test_reddit_client_id
REDDIT_CLIENT_SECRET=test_reddit_client_secret
REDDIT_USER_AGENT=TestBot/1.0 by TestUser
# Mock Alpha Vantage API
ALPHA_VANTAGE_API_KEY=test_alpha_vantage_key
# Mock Google Gemini API
GOOGLE_GEMINI_API_KEY=test_gemini_api_key
# =============================================================================
# Test Security Configuration
# =============================================================================
# Test JWT secret (different from production)
JWT_SECRET_KEY=test-jwt-secret-key-for-testing-only-not-secure
# Shorter token expiry for tests
JWT_ACCESS_TOKEN_EXPIRE_MINUTES=5
JWT_REFRESH_TOKEN_EXPIRE_DAYS=1
# =============================================================================
# Test Application Configuration
# =============================================================================
# Test API settings
API_V1_PREFIX=/api/v1
API_TITLE=RottenStocks Test API
API_VERSION=1.0.0-test
# Test server settings
HOST=127.0.0.1
PORT=8001
WORKERS=1
# Test URLs
FRONTEND_URL=http://localhost:3000
API_BASE_URL=http://localhost:8001
ALLOWED_ORIGINS=http://localhost:3000,http://127.0.0.1:3000
# =============================================================================
# Test Rate Limiting (More Permissive)
# =============================================================================
RATE_LIMIT_PER_MINUTE=1000
RATE_LIMIT_BURST=1000
REDDIT_RATE_LIMIT_PER_MINUTE=1000
ALPHA_VANTAGE_RATE_LIMIT_PER_MINUTE=1000
GEMINI_RATE_LIMIT_PER_MINUTE=1000
# =============================================================================
# Test Caching (Shorter TTLs)
# =============================================================================
STOCK_PRICE_CACHE_TTL=10
RATING_CACHE_TTL=30
SOCIAL_DATA_CACHE_TTL=60
CACHE_PREFIX=rottenstocks_test
# =============================================================================
# Test Background Jobs
# =============================================================================
CELERY_BROKER_URL=redis://localhost:6379/14
CELERY_RESULT_BACKEND=redis://localhost:6379/13
# Faster intervals for testing
STOCK_SYNC_INTERVAL_MINUTES=1
SENTIMENT_ANALYSIS_BATCH_SIZE=10
RATING_UPDATE_INTERVAL_MINUTES=1
# =============================================================================
# Test Development Tools
# =============================================================================
ENABLE_DOCS=false
ENABLE_REDOC=false
ENABLE_SWAGGER=false
# Enable database debugging in tests
DB_ECHO=false
DB_ECHO_POOL=false
# Disable profiling in tests
ENABLE_PROFILING=false