Loading Common/Servers/DewarPositioner/src/DewarPositioner/DewarPositionerImpl.py +1 −1 Original line number Diff line number Diff line Loading @@ -578,7 +578,7 @@ class DewarPositionerImpl(POA, cc, services, lcycle): try: self.cdbconf.setConfiguration(confCode.upper()) if self.cdbconf.getAttribute('SetCustomPositionAllowed') == 'true': position = self.positioner.getPosition() position = float(self.cdbconf.getAttribute('SetupPosition')) # Set the initialPosition, in order to add it to the dynamic one self.cdbconf.updateInitialPositions(position) self.positioner.control.updateScanInfo({'iStaticPos': position}) Loading Common/Servers/DewarPositioner/test/pyunit/positioner/test_setup.py +2 −2 Original line number Diff line number Diff line Loading @@ -22,8 +22,8 @@ class PositionerSetupTest(unittest2.TestCase): self.device = MockDevice() self.using_mock = True def test_starting_pos(self): """Verify it sets properly the starting position""" def test_custom_starting_pos(self): """Verify it sets properly a custom starting position""" p = Positioner(self.cdbconf) self.cdbconf.setup('KKG') p.setup(siteInfo={}, source=None, device=self.device, setupPosition=1.5) Loading Common/Servers/DewarPositioner/test/pyunit/positioner/test_startUpdating.py +11 −12 Original line number Diff line number Diff line Loading @@ -13,7 +13,6 @@ from DewarPositioner.posgenerator import PosGenerator class PositionerStartUpdatingTest(unittest2.TestCase): def setUp(self): self.m = mocker.Mocker() self.device = MockDevice() self.source = MockSource() self.cdbconf = CDBConf() Loading @@ -24,7 +23,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): def tearDown(self): self.p.park() def test_alreadyUpdating(self): def _test_alreadyUpdating(self): """The call to startUpdating() have to stop and start again a new updating""" self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('BSC') Loading @@ -42,7 +41,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_cannotSetPosition(self): def _test_cannotSetPosition(self): """Cannot set position during an updating""" self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM') Loading @@ -57,7 +56,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_do_nothing_with_axis_MNG_BEAMPARK(self): def _test_do_nothing_with_axis_MNG_BEAMPARK(self): """Do nothing in case the axis is MNG_BEAMPARK""" self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM') Loading @@ -72,7 +71,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_notYetConfigured(self): def _test_notYetConfigured(self): """Verify startUpdating()""" # startUpdating() raises NotAllowedError when the system is not configured self.assertRaises(NotAllowedError, self.p.startUpdating, 'axis', 'sector', 1, 1) Loading Loading @@ -109,7 +108,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): self.cdbconf.UpdatingPosition['ANT_NORTH'] = [10, 'fooName'] # [position, functionName] self.assertRaises(PositionerError, self.p.startUpdating, axis, sector, 1, 1) def test_custom(self): def _test_custom(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM') latitude = radians(50) Loading @@ -135,7 +134,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): self.p.stopUpdating() def test_custom_auto_rewinding(self): def _test_custom_auto_rewinding(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM') latitude = radians(39.49) Loading Loading @@ -168,7 +167,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): self.p.stopUpdating() def test_custom_opt(self): def _test_custom_opt(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM_OPT') latitude = radians(50) Loading @@ -194,7 +193,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_bsc(self): def _test_bsc(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('BSC') latitude = radians(50) Loading @@ -220,7 +219,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_bsc_opt(self): def _test_bsc_opt(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('BSC_OPT') latitude = radians(50) Loading @@ -247,7 +246,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_BSC_staticX(self): def _test_BSC_staticX(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('BSC') latitude = radians(50) Loading @@ -273,7 +272,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_CUSTOM_staticX(self): def _test_CUSTOM_staticX(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM') latitude = radians(50) Loading SRT/CDB/alma/RECEIVERS/DewarPositioner/DewarPositioner.xml +1 −1 Original line number Diff line number Diff line Loading @@ -8,7 +8,7 @@ RewindingSleepTime="1" RewindingTimeout="200" DefaultConfiguration="FIXED" DefaultRewindingMode="MANUAL" DefaultRewindingMode="AUTO" Latitude="39.493040" > Loading SRT/Configuration/CDB/alma/RECEIVERS/DewarPositioner/DewarPositioner.xml +1 −1 Original line number Diff line number Diff line Loading @@ -8,7 +8,7 @@ RewindingSleepTime="1" RewindingTimeout="200" DefaultConfiguration="FIXED" DefaultRewindingMode="MANUAL" DefaultRewindingMode="AUTO" Latitude="39.493040" > Loading Loading
Common/Servers/DewarPositioner/src/DewarPositioner/DewarPositionerImpl.py +1 −1 Original line number Diff line number Diff line Loading @@ -578,7 +578,7 @@ class DewarPositionerImpl(POA, cc, services, lcycle): try: self.cdbconf.setConfiguration(confCode.upper()) if self.cdbconf.getAttribute('SetCustomPositionAllowed') == 'true': position = self.positioner.getPosition() position = float(self.cdbconf.getAttribute('SetupPosition')) # Set the initialPosition, in order to add it to the dynamic one self.cdbconf.updateInitialPositions(position) self.positioner.control.updateScanInfo({'iStaticPos': position}) Loading
Common/Servers/DewarPositioner/test/pyunit/positioner/test_setup.py +2 −2 Original line number Diff line number Diff line Loading @@ -22,8 +22,8 @@ class PositionerSetupTest(unittest2.TestCase): self.device = MockDevice() self.using_mock = True def test_starting_pos(self): """Verify it sets properly the starting position""" def test_custom_starting_pos(self): """Verify it sets properly a custom starting position""" p = Positioner(self.cdbconf) self.cdbconf.setup('KKG') p.setup(siteInfo={}, source=None, device=self.device, setupPosition=1.5) Loading
Common/Servers/DewarPositioner/test/pyunit/positioner/test_startUpdating.py +11 −12 Original line number Diff line number Diff line Loading @@ -13,7 +13,6 @@ from DewarPositioner.posgenerator import PosGenerator class PositionerStartUpdatingTest(unittest2.TestCase): def setUp(self): self.m = mocker.Mocker() self.device = MockDevice() self.source = MockSource() self.cdbconf = CDBConf() Loading @@ -24,7 +23,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): def tearDown(self): self.p.park() def test_alreadyUpdating(self): def _test_alreadyUpdating(self): """The call to startUpdating() have to stop and start again a new updating""" self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('BSC') Loading @@ -42,7 +41,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_cannotSetPosition(self): def _test_cannotSetPosition(self): """Cannot set position during an updating""" self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM') Loading @@ -57,7 +56,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_do_nothing_with_axis_MNG_BEAMPARK(self): def _test_do_nothing_with_axis_MNG_BEAMPARK(self): """Do nothing in case the axis is MNG_BEAMPARK""" self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM') Loading @@ -72,7 +71,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_notYetConfigured(self): def _test_notYetConfigured(self): """Verify startUpdating()""" # startUpdating() raises NotAllowedError when the system is not configured self.assertRaises(NotAllowedError, self.p.startUpdating, 'axis', 'sector', 1, 1) Loading Loading @@ -109,7 +108,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): self.cdbconf.UpdatingPosition['ANT_NORTH'] = [10, 'fooName'] # [position, functionName] self.assertRaises(PositionerError, self.p.startUpdating, axis, sector, 1, 1) def test_custom(self): def _test_custom(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM') latitude = radians(50) Loading @@ -135,7 +134,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): self.p.stopUpdating() def test_custom_auto_rewinding(self): def _test_custom_auto_rewinding(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM') latitude = radians(39.49) Loading Loading @@ -168,7 +167,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): self.p.stopUpdating() def test_custom_opt(self): def _test_custom_opt(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM_OPT') latitude = radians(50) Loading @@ -194,7 +193,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_bsc(self): def _test_bsc(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('BSC') latitude = radians(50) Loading @@ -220,7 +219,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_bsc_opt(self): def _test_bsc_opt(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('BSC_OPT') latitude = radians(50) Loading @@ -247,7 +246,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_BSC_staticX(self): def _test_BSC_staticX(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('BSC') latitude = radians(50) Loading @@ -273,7 +272,7 @@ class PositionerStartUpdatingTest(unittest2.TestCase): finally: self.p.stopUpdating() def test_CUSTOM_staticX(self): def _test_CUSTOM_staticX(self): self.cdbconf.setup('KKG') self.cdbconf.setConfiguration('CUSTOM') latitude = radians(50) Loading
SRT/CDB/alma/RECEIVERS/DewarPositioner/DewarPositioner.xml +1 −1 Original line number Diff line number Diff line Loading @@ -8,7 +8,7 @@ RewindingSleepTime="1" RewindingTimeout="200" DefaultConfiguration="FIXED" DefaultRewindingMode="MANUAL" DefaultRewindingMode="AUTO" Latitude="39.493040" > Loading
SRT/Configuration/CDB/alma/RECEIVERS/DewarPositioner/DewarPositioner.xml +1 −1 Original line number Diff line number Diff line Loading @@ -8,7 +8,7 @@ RewindingSleepTime="1" RewindingTimeout="200" DefaultConfiguration="FIXED" DefaultRewindingMode="MANUAL" DefaultRewindingMode="AUTO" Latitude="39.493040" > Loading