test failed : test_2_library_instances ; position attribute not found
test_2_library_instances
fails time to time even on my local computer.
motors/test_tango_axis.py::test_2_library_instances[1-10] PASSED [ 10%]
motors/test_tango_axis.py::test_2_library_instances[2-10] PASSED [ 20%]
motors/test_tango_axis.py::test_2_library_instances[3-10] PASSED [ 30%]
motors/test_tango_axis.py::test_2_library_instances[4-10] FAILED [ 40%] <---------
motors/test_tango_axis.py::test_2_library_instances[5-10] PASSED [ 50%]
motors/test_tango_axis.py::test_2_library_instances[6-10] PASSED [ 60%]
motors/test_tango_axis.py::test_2_library_instances[7-10] PASSED [ 70%]
motors/test_tango_axis.py::test_2_library_instances[8-10] PASSED [ 80%]
motors/test_tango_axis.py::test_2_library_instances[9-10] FAILED [ 90%] <-------------
motors/test_tango_axis.py::test_2_library_instances[10-10] PASSED
=================================== FAILURES ===================================
___________________________ test_2_library_instances ___________________________
bliss_tango_server = ('tango://localhost:44581/id00/bliss/test', Bliss(id00/bliss/test))
s1hg = <bliss.common.axis.Axis object at 0x7f46799a76d8>
s1f = <bliss.common.axis.Axis object at 0x7f4679b79fd0>
s1b = <bliss.common.axis.Axis object at 0x7f4679c03240>
ports = Ports(redis_port=52653, tango_port=44581, beacon_port=60529, cfgapp_port=53147)
def test_2_library_instances(bliss_tango_server, s1hg, s1f, s1b, ports):
s1hg.dial = 1
s1hg.position = 1
assert s1f.position == 0.5
assert s1b.position == 0.5
assert s1hg.position == 1
dev_name, proxy = bliss_tango_server
tango_s1hg = DeviceProxy(
"tango://localhost:{}/id00/bliss_test/s1hg".format(ports.tango_port)
)
> assert tango_s1hg.read_attribute("position").value == 1
Failure appears here:
INFO 2019-06-13 17:07:52,565 session.controllers.Slits: [SLITS] real: {'front': 0.5, 'back': 0.5, 'up': 0.0, 'down': 0.0}
INFO ... calc: {'hoffset': 0.0, 'hgap': 1.0, 'voffset': 0.0, 'vgap': 0.0}
INFO ... calc_from_real()
INFO ... real: {'front': 0.5, 'back': 0.5, 'up': 0.0, 'down': 0.0}
INFO ... calc: {'hoffset': 0.0, 'hgap': 1.0, 'voffset': 0.0, 'vgap': 0.0}
Ready to accept request
FAILED
must be:
...
INFO Slits: [SLITS] calc_from_real()
INFO Slits: [SLITS] real: {'front': 1.0, 'back': 1.0, 'up': 0.0, 'down': 0.0}
INFO Slits: [SLITS] calc: {'hoffset': 0.0, 'hgap': 2.0, 'voffset': 0.0, 'vgap': 0.0}
PASSED
hummm
avec un petit sleep au debut ca a l'air de passer...
les vitesses de s1f
et s1b
on tpas l'air d'etres prises en copmte
du coup le test est assez long.