The TSGroupMember table is updated after every inserted interaction. It
asserts that the sender of the interaction is in the group membership.
Before, our tests would construct groups with mock membership and then
construct outgoing messages with the local address as the sender. This
would fail this new requirement.
The fix is to make sure that the local address is in the test group
membership if we'd like to "send" any messages.
We still need the AxolotlKit model classes to migrate old sessions,
but we don't need any of the actual protocol support. This also
means we can drop HKDFKit.
Additionally, we do still use some utilities from AxolotlKit:
- AxolotlExceptions.h: NSException names, should eventually be
replaced by NSErrors everywhere
- NSData+keyVersionByte.h: prepend/remove public key type byte,
should eventually be replaced by strong types (ECPublicKey)
- SPKProtocolContext.h: defines the SPKProtocol{Read,Write}Context
marker protocols, should be replaced by direct use of
SDSAny{Read,Write}Transaction
Previously this manually initialized two sessions through an
AxolotlKit-provided helper. Rather than expose a similar helper for
SignalClient, TestProtocolRunner now sends an empty message in both
directions to initialize the sessions.
OWSAccountIdFinder is no longer used for dependency injection in
SignalMetadataKit, so there's no need to allocate empty NSObjects just
to call the methods.
No functionality change.
There are a lot of events that get dispatched onto the main queue
(often /from/ the main queue), and processing them during the setup
for the subsequent test can cause problems. In particular, the
notification for setting up a local number in -[OWSMessageManagerTest
test_GroupUpdate] was occasionally being processed in the subsequent
-test_GroupUpdateWithAvatar, depending on how long GRDB took to set up
in the second test.
A synchronous barrier block will not run until all prior submitted
items run, and all of the work setting up this test is synchronously
submitted to the global background queue.
Updates the proto definition to add a preview description and date
field. Date and description metadata from fetched content will be sent
over the wire. We can't render it locally yet, but at least this will
allow supporting recipients to display the content.
Also, made some minor changes to HTMLMetadata to better handle article
publish/modified date tags.
This branch makes improvements to how HTML metadata is parsed. Now,
we'll parse other kinds of opengraph tags as well as title, favicon, and
meta description.
This branch also modifies how URL validation is performed. Before,
international URLs were not supported due to NSURL/NSDataDetectors
handling of punycode. Now, there are mechanisms to detect non-ASCII URLs
that have been parsed and validate that they are comprised of the
correct characters.