aboutsummaryrefslogtreecommitdiffhomepage
path: root/test
diff options
context:
space:
mode:
authorlevlam <levlam@telegram.org>2026-01-13 17:11:55 +0300
committerlevlam <levlam@telegram.org>2026-01-13 17:11:55 +0300
commit4565767812d83b993e54a6a97be64e788aab0eba (patch)
treec54921b98ca0bb1e29c9124474a78fe001a91957 /test
parentebf736e46e98cbcb88cca4f8b836203b90e1ec89 (diff)
Add td_api::internalLinkTypeNewPrivateChat.
Diffstat (limited to 'test')
-rw-r--r--test/link.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/link.cpp b/test/link.cpp
index 02cdf98d5..1e5ccc154 100644
--- a/test/link.cpp
+++ b/test/link.cpp
@@ -401,6 +401,10 @@ static auto my_profile(const td::string &section) {
return td::td_api::make_object<td::td_api::internalLinkTypeMyProfile>(section);
}
+static auto new_private_chat() {
+ return td::td_api::make_object<td::td_api::internalLinkTypeNewPrivateChat>();
+}
+
static auto passport_data_request(td::int32 bot_user_id, const td::string &scope, const td::string &public_key,
const td::string &nonce, const td::string &callback_url) {
return td::td_api::make_object<td::td_api::internalLinkTypePassportDataRequest>(bot_user_id, scope, public_key, nonce,
@@ -972,6 +976,10 @@ TEST(Link, parse_internal_link_part2) {
parse_internal_link("tg://settings/my-profile/posts/add-album", my_profile("posts/add-album"));
parse_internal_link("tg://settings/my-profile/archived-posts", my_profile("archived-posts"));
+ parse_internal_link("tg://new", new_private_chat());
+ parse_internal_link("tg://new/", new_private_chat());
+ parse_internal_link("tg://new/asd", unknown_deep_link("tg://new/asd"));
+
parse_internal_link("t.me/joinchat?invite=abcdef", nullptr);
parse_internal_link("t.me/joinchat", nullptr);
parse_internal_link("t.me/joinchat/", nullptr);