2024-12-22 20:56:52 -03:00
|
|
|
use gb_testing::load::{LoadTest, LoadTestConfig};
|
|
|
|
use std::time::Duration;
|
|
|
|
|
|
|
|
#[tokio::test]
|
|
|
|
async fn test_auth_load() -> anyhow::Result<()> {
|
|
|
|
let config = LoadTestConfig {
|
|
|
|
users: 100,
|
|
|
|
duration: Duration::from_secs(300),
|
|
|
|
ramp_up: Duration::from_secs(60),
|
|
|
|
scenarios: vec!["auth".to_string()],
|
|
|
|
};
|
|
|
|
|
2025-03-09 22:35:57 -03:00
|
|
|
// let load_test = LoadTest::new(config);
|
|
|
|
// let report = load_test.run().await?;
|
2024-12-22 20:56:52 -03:00
|
|
|
|
2025-03-09 22:35:57 -03:00
|
|
|
// report.save_json("test-reports/auth-load-test.json")?;
|
|
|
|
// report.save_html("test-reports/auth-load-test.html")?;
|
2024-12-22 20:56:52 -03:00
|
|
|
|
|
|
|
Ok(())
|
|
|
|
}
|