Skip to content

Repository files navigation

OpenGate.js API

OpenGate.js is an EC6 JavaScript library that helps you integrate OpenGate easily in your JavaScript projects. Although it's an EC6 project it compiles into compliant EC5 JavaScript thanks to Babel and gulp, therefore you can use OpenGate.js in your browser application and in your Node.js server.

Features

Documentation

To generate the API documentation you can execute gulp build and open the generated HTML on: documentation/index.html

In order to generate the documentation in relearn format (always after last step):

yarn docs:relearn

You must copy the content from ogapi-docs/.md to the odm-documentation-hugo project in *content/libs/ogapi-docs folder.

Generate version

Can generate version of the project with the jenkins job http://constructor.amplia.es:8080/jenkins/job/og-ux_generate_release_from_github/

  1. Click on "Build with Parameters"
  2. Select "incrementVersion"
  3. Introduce Project "opengate-js"
  4. Click on button Ejecución

Once the version is generated, update dependencies:

  1. Update into package.json
$ yarn upgrade opengate-js@[version]
  1. Update the version into the project
import {} from 'opengate-js/dist/opengate-api-bower-[version]'

Tests

Before running the tests you must configure the following values:

  • features/support/world.js -- this.test_url_north -- this.test_url_south -- this.apikey - API_KEY of the user used to create the different entities in the test -- this.YOUR_EMAIL - email of the user used to create the different entities in the test. If it is not configured here, it must be configured in each of the features to be executed if necessary -- this.YOUR_PASSWORD - password of the user used to create the different entities in the test. If it is not configured here, it must be configured in each of the features to be executed if necessary

  • features/feaures/**.feature -- require-real-apikey: API_KEY of the user used to create the different entities in the test -- YOUR_EMAIL: email of the user used to create the different entities in the test. If it is not configured here, it must be configured in features/suppport/world.js file -- YOUR_PASSWORD: password of the user used to create the different entities in the test. If it is not configured here, it must be configured in features/suppport/world.js file

You can run the tests by running the following command:

$ gulp cucumber [--tags @[tags]]

About

OpenGate JavaScript API wrapper

Topics

Resources

Stars

5 stars

Watchers

4 watching

Forks

Releases

Packages

Used by

Contributors

Languages