[RECOMMENDED] Setup a Github Personal Access Token as mentioned here, then skip to step 3.
If you would like to build required DCSA packages individually, begin with step 1.
-
Build DCSA-Core as described in DCSA-Core/README.md, then
-
Build DCSA-Event-Core as described in DCSA-Event-Core/README.md, then
-
Clone DCSA-JIT (with
--recurse-submodules
option.) and Build using,mvn package
-
Initialize your local postgresql database as described in datamodel/README.md
or If you have docker installed, you may skip this step and use the docker-compose command mentioned below to set it up (This will initialize the application along with the database). -
Run application,
mvn spring-boot:run [options]
options:
-Dspring-boot.run.arguments="--DB_HOSTNAME=localhost:5432 --LOG_LEVEL=DEBUG"
OR using docker-compose
docker-compose up -d -V --build
- Verify if the application is running,
curl http://localhost:9090/v2/actuator/health
The repo includes a postman/newman collection for testing all
valid and some invalid combinations of timestamps and their
input. The test input is generated via the script
generate_pm_test_data.py
using data from the
DCSA-Information-Model
submodule.
The flow is:
# Start the JIT application (and have it listen to localhost:9090)
$ python3 generate_pm_test_data.py iteration-data.csv
$ newman run -d iteration-data.csv postman_collection.combinatorial.json
Note that the iteration-data by default covers 4500+ test cases of both positive and negative test cases. Keep in mind that:
-
The test will generate a lot of timestamps (1900+ on a successful run)
-
The postman UI (at least at version
10.1.2
) may not handle the iteration data very gracefully performance-wise. We recommend you usenewman
for running the tests as it has considerably less overhead. -
You can split the iteration-data up into smaller parts. E.g.:
(head -n1 iteration-data.csv ; grep ,positive, iteration-data.csv) > only-positive.csv
Will give you a file
only-positive.csv
with only the positive tests.
If a test fail, you can read the corresponding row in the iteration-data.csv
file to see what the test covered. This includes the "timestamp name",
whether the test was positive (expected to be accepted) or negative (expected
to be rejected) as well as which fields are included/excluded.