@@ -108,17 +108,6 @@ describe('CeeblueVideoJSPlugin', () => {
108108 } )
109109 ] ) ;
110110
111- await Promise . race ( [
112- new Promise < void > ( ( resolve ) => {
113- player . on ( 'playing' , ( ) => {
114- resolve ( ) ;
115- } ) ;
116- } ) ,
117- new Promise ( ( _ , reject ) => {
118- setTimeout ( ( ) => reject ( new Error ( 'Playing event timeout' ) ) , 5000 ) ;
119- } )
120- ] ) ;
121-
122111 expect ( player . paused ( ) ) . toBe ( false ) ;
123112 } catch ( error ) {
124113 // If play fails due to autoplay restrictions, skip the test
@@ -135,23 +124,7 @@ describe('CeeblueVideoJSPlugin', () => {
135124 await Promise . race ( [
136125 player . play ( ) ,
137126 new Promise ( ( _ , reject ) => {
138- setTimeout ( ( ) => reject ( new Error ( 'Play timeout' ) ) , 5000 ) ;
139- } )
140- ] ) ;
141-
142- await Promise . race ( [
143- new Promise < void > ( ( resolve ) => {
144- player . on ( 'playing' , ( ) => {
145- resolve ( ) ;
146- } ) ;
147- } ) ,
148- new Promise < void > ( ( resolve ) => {
149- player . on ( 'loadeddata' , ( ) => {
150- resolve ( ) ;
151- } ) ;
152- } ) ,
153- new Promise ( ( _ , reject ) => {
154- setTimeout ( ( ) => reject ( new Error ( 'Video data timeout' ) ) , 5000 ) ;
127+ setTimeout ( ( ) => reject ( new Error ( 'Play timeout' ) ) , 60000 ) ;
155128 } )
156129 ] ) ;
157130
@@ -171,7 +144,7 @@ describe('CeeblueVideoJSPlugin', () => {
171144 await Promise . race ( [
172145 player . play ( ) ,
173146 new Promise ( ( _ , reject ) => {
174- setTimeout ( ( ) => reject ( new Error ( 'Play timeout' ) ) , 5000 ) ;
147+ setTimeout ( ( ) => reject ( new Error ( 'Play timeout' ) ) , 60000 ) ;
175148 } )
176149 ] ) ;
177150 expect ( player . paused ( ) ) . toBe ( false ) ;
@@ -182,7 +155,7 @@ describe('CeeblueVideoJSPlugin', () => {
182155 await Promise . race ( [
183156 player . play ( ) ,
184157 new Promise ( ( _ , reject ) => {
185- setTimeout ( ( ) => reject ( new Error ( 'Play timeout' ) ) , 5000 ) ;
158+ setTimeout ( ( ) => reject ( new Error ( 'Play timeout' ) ) , 60000 ) ;
186159 } )
187160 ] ) ;
188161 expect ( player . paused ( ) ) . toBe ( false ) ;
0 commit comments