File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -44,6 +44,24 @@ describe('Video', () => {
4444 expect ( tag . props ( ) . src ) . to . endWith ( '/fps_25-/dog.webm' ) ;
4545 } ) ;
4646
47+ it ( 'should support startOffset parameter' , function ( ) {
48+ let tag = shallow (
49+ < Video cloudName = "demo" sourceTypes = { 'webm' } publicId = "dog" >
50+ < Transformation startOffset = "auto" />
51+ </ Video > ) ;
52+ expect ( tag . props ( ) . src ) . to . endWith ( '/so_auto/dog.webm' ) ;
53+ tag = shallow (
54+ < Video cloudName = "demo" sourceTypes = { 'webm' } publicId = "dog" >
55+ < Transformation startOffset = "2" />
56+ </ Video > ) ;
57+ expect ( tag . props ( ) . src ) . to . endWith ( '/so_2/dog.webm' ) ;
58+ tag = shallow (
59+ < Video cloudName = "demo" sourceTypes = { 'webm' } publicId = "dog" >
60+ < Transformation startOffset = "2.34" />
61+ </ Video > ) ;
62+ expect ( tag . props ( ) . src ) . to . endWith ( '/so_2.34/dog.webm' ) ;
63+ } ) ;
64+
4765 it ( "should include child transformation for multiple source types" , function ( ) {
4866 let tag = shallow (
4967 < Video cloudName = 'demo'
You can’t perform that action at this time.
0 commit comments