aboutsummaryrefslogtreecommitdiffstats
path: root/docs/WriteYourTests/1_BindingConfiguration.md
diff options
context:
space:
mode:
Diffstat (limited to 'docs/WriteYourTests/1_BindingConfiguration.md')
-rw-r--r--docs/WriteYourTests/1_BindingConfiguration.md74
1 files changed, 74 insertions, 0 deletions
diff --git a/docs/WriteYourTests/1_BindingConfiguration.md b/docs/WriteYourTests/1_BindingConfiguration.md
index 9980357..90b7e8d 100644
--- a/docs/WriteYourTests/1_BindingConfiguration.md
+++ b/docs/WriteYourTests/1_BindingConfiguration.md
@@ -35,4 +35,78 @@ Here is an example:
}
}
}
+```
+
+and another example which tests the low-can api:
+
+```json
+{
+ "id": "http://iot.bzh/download/public/schema/json/ctl-schema.json#",
+ "$schema": "http://iot.bzh/download/public/schema/json/ctl-schema.json#",
+ "metadata": {
+ "uid": "Test",
+ "version": "1.0",
+ "api": "aft-aftest",
+ "info": "Binding made to test other bindings",
+ "require": [
+ "low-can"
+ ]
+ },
+ "testVerb": {
+ "uid": "launch_all_tests",
+ "info": "Launch all the tests",
+ "action": "lua://AFT#_launch_test",
+ "args": {
+ "trace": "low-can",
+ "files": [ "aftTest.lua", "mapis-tests.lua" ]
+ }
+ },
+ "mapis": [{
+ "uid": "low-can",
+ "info": "Faked low-can API",
+ "libs": "mapi_low-can.lua",
+ "verbs": [
+ {
+ "uid": "subscribe",
+ "info": "Subscribe to CAN signals events",
+ "action": "lua://low-can#_subscribe"
+ },
+ {
+ "uid": "unsubscribe",
+ "info": "Unsubscribe previously suscribed signals.",
+ "action": "lua://low-can#_unsubscribe"
+ },
+ {
+ "uid": "get",
+ "info": "get a current value of CAN message",
+ "action": "lua://low-can#_get"
+ },
+ {
+ "uid": "list",
+ "info": "get a supported CAN message list",
+ "action": "lua://low-can#_list"
+ },
+ {
+ "uid": "auth",
+ "info": "Authenticate session to be raise Level Of Assurance.",
+ "action": "lua://low-can#_auth"
+ },
+ {
+ "uid": "write",
+ "info": "Write a CAN messages to the CAN bus.",
+ "action": "lua://low-can#_write"
+ }
+ ],
+ "events": [{
+ "uid": "low-can/diagnostic_messages",
+ "action": "lua://AFT#_evt_catcher_"
+ },{
+ "uid": "low-can/messages_engine_speed",
+ "action": "lua://AFT#_evt_catcher_"
+ },{
+ "uid": "low-can/messages_vehicle_speed",
+ "action": "lua://AFT#_evt_catcher_"
+ }]
+ }]
+}
``` \ No newline at end of file