Stefan Ceriu
78282bf1e1
chore(sdk-base): fix typos following typos crate bump to 1.30.0
2025-03-04 11:28:36 +02:00
Benjamin Bouvier
a5f0473e1b
test(timeline): use the MatrixMockServer and EventFactory in integration/timeline/mod.rs
2025-02-11 11:26:47 +01:00
Ivan Enderlin
7eae832b8c
test: set_timeline_prev_batch takes anything that implements Into<String>.
2025-02-04 19:43:38 +01:00
Damir Jelić
4c46e42201
chore: Release matrix-sdk version 0.10.0
2025-02-04 16:32:55 +01:00
Damir Jelić
0d4bc65e28
chore: Enable releases for the test crates
2025-02-04 16:32:55 +01:00
Benjamin Bouvier
041627ec4a
test: rename EventFactory::into_sync to into_event
2025-01-22 20:24:48 +01:00
Benjamin Bouvier
3428494468
refactor: rename SyncTimelineEvent to TimelineEvent
2025-01-22 20:24:48 +01:00
Benjamin Bouvier
eb31f035e6
refactor: turn TimelineEvent into SyncTimelineEvent
...
As the comment noted, they're essentially doing the same thing. A
`TimelineEvent` may not have computed push actions, and in that regard
it seemed more correct than `SyncTimelineEvent`, so another commit will
make the field optional.
2025-01-22 20:24:48 +01:00
Benjamin Bouvier
4341aaf65c
test: remove some uses of sync_timeline_event! in the base and sdk crates ( #4565 )
...
Part of #3716 .
2025-01-21 14:33:22 +00:00
Benjamin Bouvier
210c5749f1
test: minimize usage of EventFactory::state_key
...
It was used in places where we could make use of other helpers, in some
cases. Also introduces the `room_avatar` helper to create the room
avatar state event.
2025-01-21 10:50:29 +01:00
Benjamin Bouvier
0c74abbc50
test: get rid of EventBuilder ( #4560 )
...
This gets rid of `EventBuilder`, and makes more usage of the
`EventFactory`, which is more ergonomic to create test events.
A large part of
https://github.com/matrix-org/matrix-rust-sdk/issues/3716 .
2025-01-21 09:23:03 +00:00
Richard van der Hoff
f231c74314
test: simplify examples for KeyQueryResponseTemplate
...
Generating keys from slices rather than base64 is easier.
Also, s/builder/template/.
2025-01-16 15:13:11 +00:00
Richard van der Hoff
c24770a774
test: add support for dehydrated devices to KeyQueryResponseTemplate ( #4540 )
...
#4476 added some test helpers to generate `/keys/query` responses. We're
going to need to test dehydrated devices, so this PR adds support for
that.
2025-01-16 11:26:52 +00:00
Richard van der Hoff
3dd81fbe2c
test: rename snapshots not to contain :
...
Windows doens't allow you to have `:` in its filenames
2025-01-16 11:11:38 +00:00
Benjamin Bouvier
560e582e41
test: get rid of mock_redaction and replace it with the holy MatrixMockServer
2025-01-16 11:34:42 +01:00
Richard van der Hoff
fe3cc09ae0
test: add examples for the new builder
2025-01-15 10:42:21 +00:00
Richard van der Hoff
3a3cc54067
test: generate dan's data dynamically
2025-01-15 10:42:21 +00:00
Richard van der Hoff
47f8b32ea1
test: give Dan new keys
...
Regenerate Dan's data with new cross-signing and device keys, for which I know
the private keys.
The signatures are manually calculated for now; this will be improved in a
later commit.
2025-01-15 10:42:21 +00:00
Richard van der Hoff
49748dbd4b
test: factor out common parts of dan_keys_query_response{_loggedout}
2025-01-15 10:42:21 +00:00
Richard van der Hoff
25ea5fdd73
test: use builder for some more test data
2025-01-15 10:42:21 +00:00
Richard van der Hoff
5fadde5a6d
test: implement test user data builder type
...
... and use it for some simple data
2025-01-15 10:42:21 +00:00
Richard van der Hoff
b6be4d5170
test: remove redundant sig on master key
...
Our test helper won't do this, and it's redundant
2025-01-15 10:42:21 +00:00
Richard van der Hoff
c9bac4ff2b
test: snapshot the generated object rather than the JSON
...
We're going to be switching away from JSON-twiddling, so let's snapshot the
real object rather than the JSON.
2025-01-15 10:42:21 +00:00
Richard van der Hoff
fedf7d214f
test: add some snapshot tests before we change anything
2025-01-15 10:42:21 +00:00
Benjamin Bouvier
aca8c8b8ee
chore: remove some allow(dead_code) annotations and associated dead code ( #4472 )
...
We have quite a few `allow(dead_code)` annotations. While it's OK to use
in situations where the Cargo-feature combination explodes and makes it
hard to reason about when something is actually used or not, in other
situations it can be avoided, and show actual, dead code.
2025-01-08 10:37:18 +01:00
Damir Jelić
6501a44e6a
feat: Add support for MSC4171
...
Introduce support for MSC4171, enabling the designation of certain users
as service members. These flagged users are excluded from the room
display name calculation.
MSC: https://github.com/matrix-org/matrix-spec-proposals/pull/4171
2024-12-05 14:23:36 +01:00
Valere
6801811226
feat(crypto): Supports new UtdCause variants for withheld keys
...
Adds new UtdCause variants for withheld keys, enabling applications to display customised messages when an Unable-To-Decrypt message is expected.
refactor(crypto): Move WithheldCode from crypto to common crate
2024-12-04 15:33:23 +01:00
Damir Jelić
bcd0d20e2f
test: Add a method to build m.room.member events in the EventFactory
2024-11-30 09:20:49 +01:00
Kévin Commaille
ba5881355d
chore(test): Upgrade ctor
...
Fixes the `unexpected_cfgs` warning so it doesn't need to be disabled anymore.
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr >
2024-11-29 19:59:24 +01:00
Benjamin Bouvier
9a9730d59e
task: move the EventFactory to the matrix-sdk-test crate
...
This makes it available to the crypto crate, by lowering it into the
local dependency tree.
2024-11-20 16:33:39 +01:00
Timo
21bb85ac21
feat(Room): Check if the user is allowed to do a room mention before trying to send a call notify event. ( #4271 )
2024-11-18 16:15:28 +02:00
Damir Jelić
8f0f0fa4d4
chore(test): Don't require two room IDs in the mock_sync_room method
2024-11-12 14:51:31 +01:00
Andy Balaam
5f0ba1e7df
refactor(crypto) Avoid msk and ssk abbreviations in test data
2024-10-28 16:35:39 +00:00
Andy Balaam
a1a4ce0a95
refactor(crypto) Tidy IdentityChangeDataSet test data
2024-10-28 16:35:39 +00:00
Jorge Martin Espinosa
40f4fc138b
chore(room_preview): add RoomListItem::preview_room ( #4152 )
...
This method will return a `RoomPreview` for the provided room id.
Also added `fn RoomPreview::leave()` action to be able to decline
invites or cancel knocks, since there wasn't a
`Client::leave_room_by_id` counterpart as there is for join.
The PR also deprecates `RoomListItem::invited_room`, since we have a
better alternative now.
Co-authored-by: Benjamin Bouvier <benjamin@bouvier.cc >
2024-10-25 14:33:16 +02:00
Andy Balaam
e3180cdbc5
fix(crypto): Don't warn about verified users when subscribing to identity updates
2024-10-22 12:40:31 +01:00
Jorge Martín
664f6d5f5a
feat(knocking): add code to process knocked rooms separately during sync
2024-10-16 16:12:39 +02:00
Damir Jelić
ca7f2ad3d0
Add a cargo-release config
2024-10-10 14:32:46 +02:00
Andy Balaam
a695e291fa
crypto: Rename PreviouslyVerified to VerificationViolation
...
For consistency with other places, we have now settled on
`VerificationViolation` as the best way to express this situation.
2024-10-03 15:41:55 +01:00
Hubert Chathi
1dd8c908c5
crypto: Error when sending keys to previously-verified users with identity-based strategy ( #3896 )
2024-09-03 18:06:32 +01:00
Benjamin Bouvier
224292ab3e
testing: remove EventBuilder::make_sync_reaction which is unused
2024-08-29 16:21:56 +02:00
Ivan Enderlin
9e5b06902d
test(sdk): Add 2 more tests for auto-discovery of sliding sync.
2024-08-27 17:25:12 +02:00
Benjamin Bouvier
b95c189a18
test mocks: deduplicate mock_encryption_state
2024-08-22 10:45:50 +02:00
Benjamin Bouvier
92fe72f83a
test: add a mocks mod in matrix-sdk-test to reuse across different integration tests
2024-08-22 10:45:50 +02:00
Richard van der Hoff
dd810f4803
crypto: Track if our own identity was previously verified
...
... and expose new methods to access it.
2024-08-16 15:07:36 +01:00
Richard van der Hoff
5431c0fdd6
crypto: test: add tests for error_on_verified_user_problem
2024-08-14 14:57:42 +01:00
Richard van der Hoff
4ece38af4f
test: document methods in PreviouslyVerifiedTestData
2024-08-13 16:38:58 +01:00
Richard van der Hoff
4baa82d3a6
test: add new methods for device IDs
2024-08-13 16:38:58 +01:00
Richard van der Hoff
8b01e3e209
test: make internal functions private
2024-08-13 16:38:58 +01:00
Richard van der Hoff
4a69cc9110
test: inline device_keys_payload_bob_unsigned_device
...
This is only used in one place, so is a bit pointless.
2024-08-13 16:38:58 +01:00