chore: add #[non_exhaustive] and mutation methods to improve compatibility (#715)
* chore: add #[non_exhaustive] to reduce backwards-incompatible changes going forward * fix: remove ProtocolVersion import * fix: add a few more with_ mutator methods --------- Co-authored-by: Alex Hancock <alexhancock@block.xyz>
This commit is contained in:
parent
79834b6211
commit
f63718d202
1 changed files with 1568 additions and 1110 deletions
|
|
@ -308,10 +308,8 @@ async fn test_optional_i64_field_with_null_input() -> anyhow::Result<()> {
|
|||
|
||||
// Test null case
|
||||
let result = client
|
||||
.call_tool(CallToolRequestParams {
|
||||
meta: None,
|
||||
name: "test_optional_i64".into(),
|
||||
arguments: Some(
|
||||
.call_tool(
|
||||
CallToolRequestParams::new("test_optional_i64").with_arguments(
|
||||
serde_json::json!({
|
||||
"count": null,
|
||||
"mandatory_field": "test_null"
|
||||
|
|
@ -320,8 +318,7 @@ async fn test_optional_i64_field_with_null_input() -> anyhow::Result<()> {
|
|||
.unwrap()
|
||||
.clone(),
|
||||
),
|
||||
task: None,
|
||||
})
|
||||
)
|
||||
.await?;
|
||||
|
||||
let result_text = result
|
||||
|
|
@ -338,10 +335,8 @@ async fn test_optional_i64_field_with_null_input() -> anyhow::Result<()> {
|
|||
|
||||
// Test Some case
|
||||
let some_result = client
|
||||
.call_tool(CallToolRequestParams {
|
||||
meta: None,
|
||||
name: "test_optional_i64".into(),
|
||||
arguments: Some(
|
||||
.call_tool(
|
||||
CallToolRequestParams::new("test_optional_i64").with_arguments(
|
||||
serde_json::json!({
|
||||
"count": 42,
|
||||
"mandatory_field": "test_some"
|
||||
|
|
@ -350,8 +345,7 @@ async fn test_optional_i64_field_with_null_input() -> anyhow::Result<()> {
|
|||
.unwrap()
|
||||
.clone(),
|
||||
),
|
||||
task: None,
|
||||
})
|
||||
)
|
||||
.await?;
|
||||
|
||||
let some_result_text = some_result
|
||||
|
|
|
|||
Loading…
Reference in a new issue