Skip to content

Commit

Permalink
Merge pull request #219 from opentok/dev
Browse files Browse the repository at this point in the history
v2.9.2 - updates node modules and some other fixes
  • Loading branch information
jeffswartz authored Jan 28, 2020
2 parents cab30af + f7767c9 commit 152bb29
Show file tree
Hide file tree
Showing 11 changed files with 764 additions and 1,612 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ node_js:
- 8
- 9
- 10
before_script:
- npm install -g grunt-cli
env:
- CMD="npm test"
notifications:
slack:
secure: CEhTJBzvdIEOWdjylkoDl+ioI5dHIBCgoHsRHAQFY0H7hhcuPHlJSr5MKNo65TRZfvDYUcVvbw62jBMmAIr878NQBnEPnhF/DusMB0JiZoIT2fKB2jMMzlql1NyzlEpIT1fnONBWewOeRSzp4fIu6xct4pvBja044o6PUw+TVRg=
13 changes: 4 additions & 9 deletions DEVELOPING.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,26 +4,21 @@ This document describes tools, tasks and workflow that one needs to be familiar
this project. If you use this package within your own software as is but don't plan on modifying it, this guide is
**not** for you.

## Tools

* [Grunt](http://gruntjs.com/): used to run predefined tasks. Install all development dependencies (`npm install`)
and also install the grunt CLI (`npm install -g grunt-cli`).

## Tasks

### Testing

This project's tests are written with Mocha and with Jasmine. Common tasks:

* `grunt` - run the complete test suite.
* `grunt mochaTest` - run just the mocha tests
* `grunt jasmine_node` - run just the jasmine tests
* `npm run test` - run the complete test suite.
* `npm run mochaTest` - run just the mocha tests
* `npm run jasmine_node` - run just the jasmine tests

### Releasing

In order to create a release, the following should be completed in order.

1. Ensure all the tests are passing (`grunt`) and that there is enough test coverage.
1. Ensure all the tests are passing (`pm run test`) and that there is enough test coverage.
1. Ensure package-lock.json and yarn.lock have been updated and committed if any dependency has been added/removed.
1. Make sure you are on the `dev` branch of the repository, with all changes merged/committed
already.
Expand Down
26 changes: 0 additions & 26 deletions Gruntfile.js

This file was deleted.

5 changes: 1 addition & 4 deletions lib/archiving.js
Original file line number Diff line number Diff line change
Expand Up @@ -169,10 +169,7 @@ function Archive(config, properties) {

api = function (config, method, path, body, callback) {
var rurl = config.apiEndpoint + '/v2/project/' + config.apiKey + path;
if ('defaults' in request) {
request = request.defaults(_.pick(config, 'proxy', 'timeout'));
}
request({
request.defaults(_.pick(config, 'proxy', 'timeout'))({
url: rurl,
method: method,
headers: generateHeaders(config),
Expand Down
5 changes: 1 addition & 4 deletions lib/callbacks.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,7 @@ var generateJwt = require('./generateJwt');

var api = function (config, method, path, body, callback) {
var rurl = config.apiEndpoint + '/v2/project/' + config.apiKey + path;
if ('defaults' in request) {
request = request.defaults(_.pick(config, 'proxy', 'timeout'));
}
request({
request.defaults(_.pick(config, 'proxy', 'timeout'))({
url: rurl,
method: method,
headers: {
Expand Down
5 changes: 1 addition & 4 deletions lib/moderation.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,7 @@ var api = function (config, method, session, connection, body, callback) {
if (connection) {
rurl += '/connection/' + connection;
}
if ('defaults' in request) {
request = request.defaults(_.pick(config, 'proxy', 'timeout'));
}
request({
request.defaults(_.pick(config, 'proxy', 'timeout'))({
url: rurl,
method: method,
headers: {
Expand Down
3 changes: 1 addition & 2 deletions lib/opentok.js
Original file line number Diff line number Diff line change
Expand Up @@ -900,8 +900,7 @@ OpenTok = function (apiKey, apiSecret, env) {
* <ul>
* <li>
* <code>headers</code> (Object) &mdash; Custom headers to be added to the SIP INVITE
* request iniated from OpenTok to the third-party SIP platform. All headers must start
* with the "X-" prefix, or a Bad Request (400) will be thrown.
* request iniated from OpenTok to the third-party SIP platform.
* </li>
* <li>
* <code>auth</code> (Object) &mdash; The credentials to be used for HTTP Digest authentication
Expand Down
5 changes: 1 addition & 4 deletions lib/signaling.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,7 @@ var api = function (config, method, session, connection, body, callback) {
rurl += '/connection/' + connection;
}
rurl += '/signal';
if ('defaults' in request) {
request = request.defaults(_.pick(config, 'proxy', 'timeout'));
}
request({
request.defaults(_.pick(config, 'proxy', 'timeout'))({
url: rurl,
method: method,
headers: {
Expand Down
Loading

0 comments on commit 152bb29

Please sign in to comment.