summaryrefslogtreecommitdiff
path: root/test.py
diff options
context:
space:
mode:
authoryvesf <yvesf-git@xapek.org>2010-07-08 23:37:01 +0200
committeryvesf <yvesf-git@xapek.org>2010-07-08 23:37:01 +0200
commit0db87a811fef3a08d9f547d53388f1f8ef80422b (patch)
tree300e8d6327679e9224723914976450b0fedb5fea /test.py
parent7a57ef77a3093f480ab414400d44d546f283d81c (diff)
downloadebus-alt-0db87a811fef3a08d9f547d53388f1f8ef80422b.tar.gz
ebus-alt-0db87a811fef3a08d9f547d53388f1f8ef80422b.zip
fehler im model behoben und test.py aktualisiert
Diffstat (limited to 'test.py')
-rw-r--r--test.py13
1 files changed, 10 insertions, 3 deletions
diff --git a/test.py b/test.py
index 82df5b6..958c7b1 100644
--- a/test.py
+++ b/test.py
@@ -17,11 +17,18 @@ session = Session()
t1_sensor = model.Sensor("foosensor", "blatest")
session.add(t1_sensor)
-for i in xrange(10000):
- session.add( model.Value(t1_sensor, 0.5) )
+for i in xrange(10):
+ m = model.ValueInt(t1_sensor, 1)
+ session.add( m )
-session.commit()
+ m = model.ValueFloat(t1_sensor, 1.2)
+ session.add( m )
+
+ m = model.ValueString(t1_sensor, "foobar")
+ session.add( m )
+
+session.commit()
session.close()