feat: prepare log chat
This commit is contained in:
@@ -183,6 +183,7 @@ async fn test_chat_completions_ok() {
|
||||
role: api::Role::User,
|
||||
content: "What is 2+2?".to_string(),
|
||||
}],
|
||||
conversation_id: None,
|
||||
};
|
||||
|
||||
let res = provider.chat_completions(&req).await.unwrap();
|
||||
@@ -217,6 +218,7 @@ async fn test_chat_completions_missing_messages() {
|
||||
..Default::default()
|
||||
},
|
||||
messages: vec![],
|
||||
conversation_id: None,
|
||||
};
|
||||
|
||||
let err = provider.chat_completions(&req).await.unwrap_err();
|
||||
@@ -243,6 +245,7 @@ async fn test_chat_completions_no_user_message() {
|
||||
role: api::Role::System,
|
||||
content: "be helpful".to_string(),
|
||||
}],
|
||||
conversation_id: None,
|
||||
};
|
||||
|
||||
let err = provider.chat_completions(&req).await.unwrap_err();
|
||||
@@ -269,6 +272,7 @@ async fn test_chat_completions_model_not_found() {
|
||||
role: api::Role::User,
|
||||
content: "hi".to_string(),
|
||||
}],
|
||||
conversation_id: None,
|
||||
};
|
||||
|
||||
let err = provider.chat_completions(&req).await.unwrap_err();
|
||||
|
||||
Reference in New Issue
Block a user