summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorjryannel <juergen@ryannel.org>2017-04-03 20:18:23 +0200
committerGitHub <noreply@github.com>2017-04-03 20:18:23 +0200
commitc82d515e541c31019784e884e50d093fb955d49a (patch)
tree14d81aaf05495739fcf250152d97626fde952743 /tests
parent7e116e10bf9ee1ef19c12e7c3d24f7ba3b8e9800 (diff)
downloadqtivi-qface-c82d515e541c31019784e884e50d093fb955d49a.tar.gz
yaml based inline annotations (#31)
* added support for inline yaml based annotations * CLI supports now livereloading of the documentation * updated the documentation to cover more annoations insights * added support for inline yaml based annotations * CLI supports now livereloading of the documentation * updated the documentation to cover more annoations insights * clarified that there should be one annotation per line
Diffstat (limited to 'tests')
-rw-r--r--tests/in/com.pelagicore.ivi.tuner.qface9
-rw-r--r--tests/in/com.pelagicore.test.qface2
-rw-r--r--tests/test_tags.py2
3 files changed, 8 insertions, 5 deletions
diff --git a/tests/in/com.pelagicore.ivi.tuner.qface b/tests/in/com.pelagicore.ivi.tuner.qface
index 46b029b..c50a4c8 100644
--- a/tests/in/com.pelagicore.ivi.tuner.qface
+++ b/tests/in/com.pelagicore.ivi.tuner.qface
@@ -1,9 +1,10 @@
module com.pelagicore.ivi.tuner 1.0;
/** Service Tuner */
-@service()
-@interface()
-@config(private, b=B, c=C)
+@service: true
+@interface: true
+@config: {private: true, b: B, c: C}
+@data: [1,2,3]
interface Tuner {
/** property currentStation */
readonly Station currentStation;
@@ -36,7 +37,7 @@ enum State {
}
/** enum Waveband */
-@default(value=FM)
+@default: {value: FM}
enum Waveband {
/** value Waveband.FM */
FM=0,
diff --git a/tests/in/com.pelagicore.test.qface b/tests/in/com.pelagicore.test.qface
index c3b5cbf..ae8a4f0 100644
--- a/tests/in/com.pelagicore.test.qface
+++ b/tests/in/com.pelagicore.test.qface
@@ -2,7 +2,7 @@ module com.pelagicore.test 1.0;
import common 1.0;
-@service(singleton=True)
+@service: { singleton: true}
interface ContactService {
State state;
int intValue;
diff --git a/tests/test_tags.py b/tests/test_tags.py
index a205d93..82f2c90 100644
--- a/tests/test_tags.py
+++ b/tests/test_tags.py
@@ -3,6 +3,7 @@ import logging
import logging.config
from path import Path
+
# logging.config.fileConfig('logging.ini')
logging.basicConfig()
@@ -54,6 +55,7 @@ def test_flag():
assert interface.attribute('config', 'a') == 'a' # use value from yaml
assert interface.attribute('config', 'b') == 'b' # use value from yaml
assert interface.attribute('config', 'c') == 'C' # use value from IDL
+ assert interface.tags['data'] == [1, 2, 3] # array annotatiom