()
| 391 | |
| 392 | #[test] |
| 393 | fn parses_gateway_auth_config() { |
| 394 | let toml = r" |
| 395 | [openshell.gateway.auth] |
| 396 | allow_unauthenticated_users = true |
| 397 | "; |
| 398 | let tmp = write_tmp(toml); |
| 399 | let file = load(tmp.path()).expect("valid auth config parses"); |
| 400 | let auth = file.openshell.gateway.auth.expect("auth config"); |
| 401 | assert!(auth.allow_unauthenticated_users); |
| 402 | } |
| 403 | |
| 404 | #[test] |
| 405 | fn rejects_database_url_in_file() { |