org-arl / unet-contrib

Unet user contributions
BSD 3-Clause "New" or "Revised" License
11 stars 15 forks source link

Test cases for UnetStack Python API #35

Closed prasadtiru closed 4 years ago

prasadtiru commented 4 years ago

Please review the test.py which deploys a simulation and tests the python UnetSocket API.

NOTE: Since unetpy has a dependency on fjagepy. The tests assume that the fjagepy is installed and tests the unetpy development.

> make
[ -d test/unet ] || (mkdir -p test/unet ; curl -o test/unet/unet-community-3.1.0.tgz https://unetstack.net/downloads/unet-community-3.1.0.tgz ; cd test/unet && tar xvzf unet-community-3.1.0.tgz)
python test/test.py
Starting 2-node simulation...
Starting tests...
Test agents
.Test bind and connect
.Test cancel
.Test communication
.Test gateway
.Test unet socket
.Test timeout
.
----------------------------------------------------------------------
Ran 7 tests in 6.224s

OK
Stopping 2-node simulation...
Simulation interrupted!