| 254 | } |
| 255 | |
| 256 | func TestREST_SyncUser(t *testing.T) { |
| 257 | user := &common.User{ |
| 258 | Email: "test_user1@example.com", |
| 259 | Inbounds: []string{ |
| 260 | "VMESS TCP NOTLS", |
| 261 | "VLESS TCP REALITY", |
| 262 | }, |
| 263 | Proxies: &common.Proxy{ |
| 264 | Vmess: &common.Vmess{ |
| 265 | Id: uuid.New().String(), |
| 266 | }, |
| 267 | }, |
| 268 | } |
| 269 | |
| 270 | if err := sharedTestCtx.createAuthenticatedRequest("PUT", "/user/sync", user, &common.Empty{}); err != nil { |
| 271 | t.Fatalf("Sync user request failed: %v", err) |
| 272 | } |
| 273 | } |
| 274 | |
| 275 | func TestREST_SyncUsersChunked(t *testing.T) { |
| 276 | firstChunk := &common.UsersChunk{ |