-
Notifications
You must be signed in to change notification settings - Fork 1
tests
The hub has a command-line interface which implements the HubConnector interface to be able to test the ASAPHub manually.
Each instance of the CLI represents an ASAPPeer.
The CLI instances could be started on different machine to communicate with Hub over the network (TCP-IP).
It's also possible to start multiple CLI instances on one machine.
Before you can use the CLI a Hub instance must be started. The CLI provides the following commands:
-
set-id [peer-id] [multichannel false/true]sets the peer-id -
peersgets all registered peers from the hub -
connect [target-peer-id]establishes a connection with the peer "target-peer-id" and sends the message "hello world" -
helpprints all available commands to the console -
historyprints the command history, which could be used as input (testplan) for the automated CLI tests -
exitterminates the application
The automated CLI tests can be used to implement integration tests. The test class reads all test plans from the testplans directory.
A test plan is defined as .txt file which has one CLI command at each line. Each test plan file represents one test.
This approach makes it possible to trace back bugs which were found while manual testing.