1
use web::Config;
2

            
3
#[test]
4
1
fn test_config_structure() {
5
1
    let config = Config {
6
1
        site_url: "http://localhost:3000".to_string(),
7
1
        redis_url: "redis://localhost:6379".to_string(),
8
1
        client_origin: "http://localhost:3000".to_string(),
9
1
        access_token_expires_in: "15m".to_string(),
10
1
        access_token_max_age: 15,
11
1
        refresh_token_expires_in: "60m".to_string(),
12
1
        refresh_token_max_age: 60,
13
1
        ssh: web::config::SshConnectInfo {
14
1
            hostname: "ssh.example.invalid".to_string(),
15
1
            port: 2222,
16
1
            host_fingerprint: "(test)".to_string(),
17
1
        },
18
1
    };
19

            
20
1
    assert_eq!(config.site_url, "http://localhost:3000");
21
1
    assert_eq!(config.redis_url, "redis://localhost:6379");
22
1
    assert_eq!(config.access_token_max_age, 15);
23
1
    assert_eq!(config.refresh_token_max_age, 60);
24
1
}