Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VBLOCKS-2031 VBLOCKS-2412 | Tests and Promise return type #216

Merged
merged 1 commit into from
Nov 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,7 @@ commands:
- build
- run:
name: Running build checks
# command: npm run test:es5 && npm run test:esm && npm run test:typecheck && npm run lint && npm run test:unit
command: npm run test:es5 && npm run test:esm && npm run test:typecheck && npm run lint
command: npm run test:es5 && npm run test:esm && npm run test:typecheck && npm run lint && npm run test:unit
- store_artifacts:
path: coverage
destination: coverage
Expand Down
8 changes: 4 additions & 4 deletions lib/twilio/audiohelper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ class AudioHelper extends EventEmitter {
* Only one {@link AudioProcessor} can be added at this time.
* @param processor
*/
addProcessor(processor: AudioProcessor): void {
addProcessor(processor: AudioProcessor): Promise<void> {
if (this._processor) {
throw new NotSupportedError('Adding multiple AudioProcessors is not supported at this time.');
}
Expand All @@ -450,8 +450,8 @@ class AudioHelper extends EventEmitter {

this._log.debug('Adding processor');
this._processor = processor;
this._restartStreams();
this._audioProcessorEventObserver.emit('add');
return this._restartStreams();
}

/**
Expand Down Expand Up @@ -491,7 +491,7 @@ class AudioHelper extends EventEmitter {
*
* @param processor
*/
removeProcessor(processor: AudioProcessor): void {
removeProcessor(processor: AudioProcessor): Promise<void> {
if (typeof processor !== 'object' || processor === null) {
throw new InvalidArgumentError('Missing AudioProcessor argument.');
}
Expand All @@ -502,8 +502,8 @@ class AudioHelper extends EventEmitter {

this._destroyProcessedStream();
this._processor = null;
this._restartStreams();
this._audioProcessorEventObserver.emit('remove');
return this._restartStreams();
}

/**
Expand Down
Loading