1.0.0 • Published 4 years ago

caradhras v1.0.0

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

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:

  1. Import the module:

    var baascaradhrasapidocumentationlib = require('baascaradhrasapidocumentationlib');
  2. Configure any authentication parameters. For example:

    var config = baascaradhrasapidocumentationlib.configuration;
    config.apikey = a_secret_key;
  3. 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

  1. Navigate to the root directory from command prompt. (/Node/)
  2. Type mocha --recursive to run all the tests.

Run All Tests (alternate)

  1. Navigate to the ../test/Controllers/ directory from command prompt.
  2. Type mocha * to run all the tests (from all the controller files).

Run for a Particular Resource

  1. Navigate to the ../test/Controllers/ directory from command prompt.
  2. 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