-
-
Notifications
You must be signed in to change notification settings - Fork 100
Fix(jsonrpc): Do not error on missign webxdc info #6866
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -53,3 +53,4 @@ result | |
# direnv | ||
.envrc | ||
.direnv | ||
.aider* |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -124,6 +124,23 @@ async fn test_send_invalid_webxdc() -> Result<()> { | |
Ok(()) | ||
} | ||
|
||
#[tokio::test(flavor = "multi_thread", worker_threads = 2)] | ||
async fn test_set_draft_invalid_webxdc() -> Result<()> { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The test is not actually failing when I revert the fix, seems not to reproduce the bug There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The bug is deltachat-json-rpc specific. I tried to replicate the issue in core first and left the test as an artifact. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is it realistic to reproduce the bug with a python test? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Rather a jsonrpc test, but I think it's unnecessary for such a small thing There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Doesn't matter whether it's a Typescript JsonRPC or a Python JsonRPC test (in BTW, to prevent confusion about which Python bindings are meant, at some point we should rename the deprecated CFFI Python bindings, which are currently in |
||
let t = TestContext::new_alice().await; | ||
let chat_id = create_group_chat(&t, ProtectionStatus::Unprotected, "foo").await?; | ||
|
||
let mut instance = create_webxdc_instance( | ||
&t, | ||
"invalid-no-zip-but-7z.xdc", | ||
include_bytes!("../../test-data/webxdc/invalid-no-zip-but-7z.xdc"), | ||
)?; | ||
|
||
// draft should not fail | ||
chat_id.set_draft(&t, Some(&mut instance)).await?; | ||
chat_id.get_draft(&t).await.unwrap(); | ||
Ok(()) | ||
} | ||
|
||
#[tokio::test(flavor = "multi_thread", worker_threads = 2)] | ||
async fn test_send_special_webxdc_format() -> Result<()> { | ||
let t = TestContext::new_alice().await; | ||
|
Uh oh!
There was an error while loading. Please reload this page.