Skip to content

Commit

Permalink
test: improve determinism in test
Browse files Browse the repository at this point in the history
  • Loading branch information
rellfy committed Dec 22, 2024
1 parent 4247a14 commit b1a5530
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/chat.rs
Original file line number Diff line number Diff line change
Expand Up @@ -805,7 +805,11 @@ mod tests {
ChatCompletionMessage {
role: ChatCompletionMessageRole::User,
content: Some(
"What's 0.9102847*28456? reply in plain text and round to 2 decimals"
"What's 0.9102847*28456? \
reply in plain text, \
round the number to to 2 decimals \
and reply with the result number only, \
with no full stop at the end"
.to_string(),
),
name: None,
Expand Down Expand Up @@ -855,7 +859,7 @@ mod tests {
.content
.as_ref()
.unwrap(),
"The result of 0.9102847 * 28456 is approximately 25903.06 when rounded to two decimal places."
"25903.06"
);
}
}

0 comments on commit b1a5530

Please sign in to comment.