@fakes/media-devices
Version:
A interactive fake implementation of MediaDevices interface in the browser for testing
26 lines (25 loc) • 746 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.MediaDeviceInfoFake = void 0;
class MediaDeviceInfoFake {
constructor(_context, mediaDeviceDescription) {
this._context = _context;
this.mediaDeviceDescription = mediaDeviceDescription;
}
get deviceId() {
return this.mediaDeviceDescription.deviceId;
}
get groupId() {
return this.mediaDeviceDescription.groupId;
}
get kind() {
return this.mediaDeviceDescription.kind;
}
get label() {
return this.mediaDeviceDescription.label;
}
toJSON() {
this._context.notImplemented.call('MediaDeviceInfo.toJSON()');
}
}
exports.MediaDeviceInfoFake = MediaDeviceInfoFake;