Files
crawlapi/crates/db/tests/db_test.rs
Developer 62994d4f3d
Some checks failed
CI / Test (push) Has been cancelled
Deploy / Deploy to Staging (push) Has been cancelled
CI / Build & Push (push) Has been cancelled
Deploy / Deploy to Production (push) Has been cancelled
Initial commit: Full Crawl API implementation
2026-04-29 07:03:48 +00:00

19 lines
496 B
Rust

use shared::models::User;
#[test]
fn test_user_model_serialization() {
let user = User {
id: uuid::Uuid::new_v4(),
email: "test@example.com".to_string(),
password_hash: Some("hash".to_string()),
google_id: None,
credits: 30,
tier: "free".to_string(),
created_at: chrono::Utc::now(),
updated_at: chrono::Utc::now(),
};
let json = serde_json::to_string(&user).unwrap();
assert!(json.contains("test@example.com"));
}