mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 12:07:55 +00:00
Remove support for handling SPA calls within the app. (#5515)
* Remove support for handling SPA call links. They were a stop-gap solution whilst we were building support for embedded room calling. * Simplify ElementCallConfiguration now that there is only 1 type of call to handle. * Remove the unused overlayModule from NavigationRoomCoordinator.
This commit is contained in:
@@ -20,43 +20,6 @@ struct AppRouteURLParserTests {
|
||||
appRouteURLParser = AppRouteURLParser(appSettings: appSettings)
|
||||
}
|
||||
|
||||
@Test
|
||||
func elementCallRoutes() throws {
|
||||
let url = try #require(URL(string: "https://call.element.io/test"))
|
||||
|
||||
#expect(appRouteURLParser.route(from: url) == AppRoute.genericCallLink(url: url))
|
||||
|
||||
let customSchemeURL = try #require(URL(string: "io.element.call:/?url=https%3A%2F%2Fcall.element.io%2Ftest"))
|
||||
|
||||
#expect(appRouteURLParser.route(from: customSchemeURL) == AppRoute.genericCallLink(url: url))
|
||||
}
|
||||
|
||||
@Test
|
||||
func customDomainUniversalLinkCallRoutes() throws {
|
||||
let url = try #require(URL(string: "https://somecustomdomain.element.io/test"))
|
||||
|
||||
#expect(appRouteURLParser.route(from: url) == nil)
|
||||
}
|
||||
|
||||
@Test
|
||||
func customSchemeLinkCallRoutes() throws {
|
||||
let urlString = "https://somecustomdomain.element.io/test?param=123"
|
||||
let url = try #require(URL(string: urlString))
|
||||
|
||||
let encodedURLString = try #require(urlString.addingPercentEncoding(withAllowedCharacters: .urlHostAllowed))
|
||||
|
||||
let customSchemeURL = try #require(URL(string: "io.element.call:/?url=\(encodedURLString)"))
|
||||
|
||||
#expect(appRouteURLParser.route(from: customSchemeURL) == AppRoute.genericCallLink(url: url))
|
||||
}
|
||||
|
||||
@Test
|
||||
func httpCustomSchemeLinkCallRoutes() throws {
|
||||
let customSchemeURL = try #require(URL(string: "io.element.call:/?url=http%3A%2F%2Fcall.element.io%2Ftest"))
|
||||
|
||||
#expect(appRouteURLParser.route(from: customSchemeURL) == nil)
|
||||
}
|
||||
|
||||
@Test
|
||||
func matrixUserURL() throws {
|
||||
let userID = "@test:matrix.org"
|
||||
|
||||
Reference in New Issue
Block a user