mirror of https://github.com/m-labs/artiq.git
test_lda: more thorough and consistent test of simulation mode
This commit is contained in:
parent
3ed70afaa1
commit
0ae5e6d8b1
|
@ -1,8 +1,9 @@
|
||||||
import unittest
|
import unittest
|
||||||
|
import sys
|
||||||
|
|
||||||
from artiq.devices.lda.driver import Ldasim
|
from artiq.devices.lda.driver import Ldasim
|
||||||
from artiq.language.units import dB
|
from artiq.language.units import dB
|
||||||
from artiq.test.hardware_testbench import ControllerCase
|
from artiq.test.hardware_testbench import GenericControllerCase, ControllerCase
|
||||||
|
|
||||||
|
|
||||||
class GenericLdaTest:
|
class GenericLdaTest:
|
||||||
|
@ -24,6 +25,20 @@ class TestLda(ControllerCase, GenericLdaTest):
|
||||||
self.cont = self.device_mgr.get("lda")
|
self.cont = self.device_mgr.get("lda")
|
||||||
|
|
||||||
|
|
||||||
class TestLdaSim(GenericLdaTest, unittest.TestCase):
|
class TestLdaSim(GenericControllerCase, GenericLdaTest):
|
||||||
|
def get_device_db(self):
|
||||||
|
return {
|
||||||
|
"lda": {
|
||||||
|
"type": "controller",
|
||||||
|
"host": "::1",
|
||||||
|
"port": 3253,
|
||||||
|
"command": (sys.executable.replace("\\", "\\\\")
|
||||||
|
+ " -m artiq.frontend.aqctl_lda "
|
||||||
|
+ "-p {port} --simulation")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
def setUp(self):
|
def setUp(self):
|
||||||
self.cont = Ldasim()
|
GenericControllerCase.setUp(self)
|
||||||
|
self.start_controller("lda")
|
||||||
|
self.cont = self.device_mgr.get("lda")
|
||||||
|
|
Loading…
Reference in New Issue