Socket
Socket
Sign inDemoInstall

bigscreen-player

Package Overview
Dependencies
Maintainers
3
Versions
189
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bigscreen-player - npm Package Compare versions

Comparing version 1.4.0 to 1.5.0

2

package.json
{
"name": "bigscreen-player",
"version": "1.4.0",
"version": "1.5.0",
"description": "Simplified media playback for bigscreen devices.",

@@ -5,0 +5,0 @@ "main": "script/bigscreenplayer.js",

@@ -964,3 +964,3 @@ require(

it('should publish a media state update of fatal if playback is live hls simulcast', function () {
it('should publish a media state update of fatal when playing a hls simulcast', function () {
spyOn(mockStrategy, 'getDuration').and.returnValue(100);

@@ -981,3 +981,3 @@ spyOn(mockStrategy, 'getCurrentTime').and.returnValue(94);

it('should publish a media state update of fatal if playback is live hls webcast with playable', function () {
it('should publish a media state update of fatal when playing a hls webcast on a restartable device', function () {
spyOn(mockStrategy, 'getDuration').and.returnValue(100);

@@ -987,3 +987,3 @@ spyOn(mockStrategy, 'getCurrentTime').and.returnValue(94);

setUpPlayerComponent({multiCdn: true, manifestType: 'm3u8', windowType: WindowTypes.GROWING, liveSupport: LiveSupport.PLAYABLE});
setUpPlayerComponent({multiCdn: true, manifestType: 'm3u8', windowType: WindowTypes.GROWING, liveSupport: LiveSupport.RESTARTABLE});

@@ -999,3 +999,3 @@ mockStrategy.mockingHooks.fireErrorEvent({errorProperties: {}});

it('should cdn failover on hls webcast with seekable', function () {
it('should failover on a seekable device when playing hls webcasts', function () {
var secondCdn = 'b';

@@ -1008,3 +1008,3 @@ var currentTime = 10;

setUpPlayerComponent({multiCdn: true, manifestType: 'm3u8', windowType: WindowTypes.GROWING, liveSupport: 'seekable', type: type});
setUpPlayerComponent({multiCdn: true, manifestType: 'm3u8', windowType: WindowTypes.GROWING, liveSupport: LiveSupport.SEEKABLE, type: type});

@@ -1033,2 +1033,34 @@ // Set playback cause to normal

it('should failover on a playable device when playing hls webcasts', function () {
var secondCdn = 'b';
var currentTime = 10;
var type = 'application/vnd.apple.mpegurl';
spyOn(mockStrategy, 'load');
spyOn(mockStrategy, 'getCurrentTime').and.returnValue(currentTime);
setUpPlayerComponent({multiCdn: true, manifestType: 'm3u8', windowType: WindowTypes.GROWING, liveSupport: LiveSupport.PLAYABLE, type: type});
// Set playback cause to normal
mockStrategy.mockingHooks.fireEvent(MediaState.PLAYING);
mockStrategy.mockingHooks.fireEvent(MediaState.WAITING);
jasmine.clock().tick(19999);
expect(mockStrategy.load).toHaveBeenCalledTimes(1);
expect(corePlaybackData.media.urls.length).toBe(3);
expect(corePlaybackData.media.urls).toContain(jasmine.objectContaining({cdn: 'cdn-a'}));
jasmine.clock().tick(1);
expect(mockStrategy.load).toHaveBeenCalledTimes(2);
expect(mockStrategy.load).toHaveBeenCalledWith(secondCdn, type, currentTime);
expect(corePlaybackData.media.urls.length).toBe(2);
expect(corePlaybackData.media.urls).not.toContain(jasmine.objectContaining({cdn: 'cdn-a'}));
});
it('should failover after buffering for 20 seconds on live dash playback', function () {

@@ -1035,0 +1067,0 @@ var secondCdn = 'b';

@@ -219,3 +219,3 @@ define(

var canVodFailover = windowType === WindowTypes.STATIC && !aboutToEndVod;
var canHlsLiveFailover = windowType === WindowTypes.GROWING && liveSupport === LiveSupport.SEEKABLE;
var canHlsLiveFailover = windowType === WindowTypes.GROWING && (liveSupport === LiveSupport.SEEKABLE || liveSupport === LiveSupport.PLAYABLE) && transferFormat === 'hls';
var canDashLiveFailover = windowType !== WindowTypes.STATIC && transferFormat === 'dash';

@@ -222,0 +222,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc