caradhras
v1.0.0
Published
SDK for integrating with Caradhras (Conductor) BAAS API
Downloads
2
Readme
BaaSCaradhrasAPIDocumentationLib
This API SDK was automatically generated by APIMATIC Code Generator.
Installation
The SDK relies on Node Package Manager (NPM) being available to resolve dependencies.
Once published you will need copy the folder baascaradhrasapidocumentationlib
in to your node_modules
folder.
Usage
The following shows how import and use the controller:
Import the module:
var baascaradhrasapidocumentationlib = require('baascaradhrasapidocumentationlib');
Configure any authentication parameters. For example:
var config = baascaradhrasapidocumentationlib.configuration; config.apikey = a_secret_key;
Access various controllers by:
var controller = baascaradhrasapidocumentationlib.XYZ; controller.getItems(id, callback);
Test Execution
These tests use Mocha framework for testing, coupled with Chai for assertions. These dependencies need to be installed for tests to run. Tests can be run in a number of ways:
Run All Tests
- Navigate to the root directory from command prompt. (/Node/)
- Type
mocha --recursive
to run all the tests.
Run All Tests (alternate)
- Navigate to the
../test/Controllers/
directory from command prompt. - Type
mocha *
to run all the tests (from all the controller files).
Run for a Particular Resource
- Navigate to the
../test/Controllers/
directory from command prompt. - Type
mocha XYZControllerTest
to run all the tests in that controller file.
To increase mocha's default timeout, you can change the TESTTIMEOUT
parameter's value in Configuration.js
.
NOTE: Changing default timeout is available for only Binary/File type endpoint tests