Files
libsignal/swift/Tests/SignalClientTests/TestUtils.swift
Jordan Rose 9a569f2ffe Standardize license headers
...to have a period after "Signal Messenger, LLC."

...except for the Java sources, which still need a cleanup pass.
2021-10-28 17:27:30 -07:00

21 lines
618 B
Swift

//
// Copyright 2020-2021 Signal Messenger, LLC.
// SPDX-License-Identifier: AGPL-3.0-only
//
@testable import SignalClient
class BadStore: InMemorySignalProtocolStore {
enum Error: Swift.Error {
case badness
}
override func loadPreKey(id: UInt32, context: StoreContext) throws -> PreKeyRecord {
throw Error.badness
}
}
// Wrapped here so that the test files don't need to use @testable import.
func sealedSenderMultiRecipientMessageForSingleRecipient(_ message: [UInt8]) throws -> [UInt8] {
return try SignalClient.sealedSenderMultiRecipientMessageForSingleRecipient(message)
}