about summary refs log tree commit diff
path: root/__tests__
diff options
context:
space:
mode:
authorHailey <me@haileyok.com>2024-08-13 17:35:05 -0700
committerGitHub <noreply@github.com>2024-08-13 17:35:05 -0700
commit26d3777ecc7192835f4b14a9fad775d8044e29f9 (patch)
treecb3a7e2721175d45952b678472acc1d5eac20b8a /__tests__
parent630ebf523d2e70db295ef1dc1705ea38c05104af (diff)
downloadvoidsky-26d3777ecc7192835f4b14a9fad775d8044e29f9.tar.zst
Add `/live/` to supported YouTube embed URLs (#4932)
Diffstat (limited to '__tests__')
-rw-r--r--__tests__/lib/string.test.ts8
1 files changed, 8 insertions, 0 deletions
diff --git a/__tests__/lib/string.test.ts b/__tests__/lib/string.test.ts
index 0da9551e3..f226de992 100644
--- a/__tests__/lib/string.test.ts
+++ b/__tests__/lib/string.test.ts
@@ -340,12 +340,14 @@ describe('parseEmbedPlayerFromUrl', () => {
     'https://youtube.com/watch?v=videoId',
     'https://youtube.com/watch?v=videoId&feature=share',
     'https://youtube.com/shorts/videoId',
+    'https://youtube.com/live/videoId',
     'https://m.youtube.com/watch?v=videoId',
     'https://music.youtube.com/watch?v=videoId',
 
     'https://youtube.com/shorts/',
     'https://youtube.com/',
     'https://youtube.com/random',
+    'https://youtube.com/live/',
 
     'https://twitch.tv/channelName',
     'https://www.twitch.tv/channelName',
@@ -475,10 +477,16 @@ describe('parseEmbedPlayerFromUrl', () => {
       source: 'youtube',
       playerUri: 'https://bsky.app/iframe/youtube.html?videoId=videoId&start=0',
     },
+    {
+      type: 'youtube_video',
+      source: 'youtube',
+      playerUri: 'https://bsky.app/iframe/youtube.html?videoId=videoId&start=0',
+    },
 
     undefined,
     undefined,
     undefined,
+    undefined,
 
     {
       type: 'twitch_video',