/mobject-graph-test-client

This is a command line test tool for testing the functionality of mobject-graph using ADS

Primary LanguageJavaScriptMIT LicenseMIT

mobject-graph-test-client

This is a node.js test tool for testing implementations of mobject-graph. You create <yourtest>.test.js in the tests folder. Use the existing tests as an example.

Prerequisites

Before running this project, make sure you have:

  • Node.js installed on your system.
  • mobject-graph TwinCAT project, with mobject-graph-test-project active and running.

Installation

  1. Clone the Repository:
    git clone https://github.com/Mobject-Dev-Team/mobject-graph-test-client.git
    cd mobject-graph-test-client
  2. Install Dependencies:
    npm install

Configuration

Create a .env file in the root directory of the project and add your TwinCAT Net Id as follows:

NET_ID=127.0.0.1.1.1

Running the tests

Run the tests using the following command:

npm test

Running the tests on file change

If you are authoring tests and want the tests to restart on change then you can use the following command:

npm run test:watch

Playground

There are a few inbuilt playground options which allow you to see what is returned from the server. To run the the playground type the following command:

npm start

Versions

Requires mobject-graph v0.5.0