forked from M-Labs/artiq
test/full_stack: use Ethernet
This commit is contained in:
parent
8a19766278
commit
dc14728264
|
@ -5,7 +5,7 @@ from fractions import Fraction
|
||||||
|
|
||||||
from artiq import *
|
from artiq import *
|
||||||
from artiq.language.units import DimensionError
|
from artiq.language.units import DimensionError
|
||||||
from artiq.coredevice import comm_serial, core, runtime_exceptions, rtio
|
from artiq.coredevice import comm_tcp, core, runtime_exceptions, rtio
|
||||||
from artiq.sim import devices as sim_devices
|
from artiq.sim import devices as sim_devices
|
||||||
|
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@ core_device = os.getenv("ARTIQ_CORE_DEVICE")
|
||||||
|
|
||||||
|
|
||||||
def _run_on_device(k_class, **parameters):
|
def _run_on_device(k_class, **parameters):
|
||||||
comm = comm_serial.Comm(serial_dev=core_device)
|
comm = comm_tcp.Comm(host=core_device)
|
||||||
try:
|
try:
|
||||||
coredev = core.Core(comm=comm)
|
coredev = core.Core(comm=comm)
|
||||||
k_inst = k_class(core=coredev, **parameters)
|
k_inst = k_class(core=coredev, **parameters)
|
||||||
|
@ -208,7 +208,7 @@ class ExecutionCase(unittest.TestCase):
|
||||||
self.assertEqual(l_device, l_host)
|
self.assertEqual(l_device, l_host)
|
||||||
|
|
||||||
def test_misc(self):
|
def test_misc(self):
|
||||||
comm = comm_serial.Comm(serial_dev=core_device)
|
comm = comm_tcp.Comm(host=core_device)
|
||||||
try:
|
try:
|
||||||
coredev = core.Core(comm=comm)
|
coredev = core.Core(comm=comm)
|
||||||
uut = _Misc(core=coredev)
|
uut = _Misc(core=coredev)
|
||||||
|
@ -249,7 +249,7 @@ class ExecutionCase(unittest.TestCase):
|
||||||
self.assertEqual(t_device, t_host)
|
self.assertEqual(t_device, t_host)
|
||||||
|
|
||||||
def test_rpc_exceptions(self):
|
def test_rpc_exceptions(self):
|
||||||
comm = comm_serial.Comm(serial_dev=core_device)
|
comm = comm_tcp.Comm(host=core_device)
|
||||||
try:
|
try:
|
||||||
uut = _RPCExceptions(core=core.Core(comm=comm))
|
uut = _RPCExceptions(core=core.Core(comm=comm))
|
||||||
with self.assertRaises(_MyException):
|
with self.assertRaises(_MyException):
|
||||||
|
@ -312,7 +312,7 @@ class RTIOCase(unittest.TestCase):
|
||||||
# (C11 and C13 on Papilio Pro)
|
# (C11 and C13 on Papilio Pro)
|
||||||
def test_loopback(self):
|
def test_loopback(self):
|
||||||
npulses = 4
|
npulses = 4
|
||||||
comm = comm_serial.Comm(serial_dev=core_device)
|
comm = comm_tcp.Comm(host=core_device)
|
||||||
try:
|
try:
|
||||||
coredev = core.Core(comm=comm)
|
coredev = core.Core(comm=comm)
|
||||||
uut = _RTIOLoopback(
|
uut = _RTIOLoopback(
|
||||||
|
@ -327,7 +327,7 @@ class RTIOCase(unittest.TestCase):
|
||||||
comm.close()
|
comm.close()
|
||||||
|
|
||||||
def test_underflow(self):
|
def test_underflow(self):
|
||||||
comm = comm_serial.Comm(serial_dev=core_device)
|
comm = comm_tcp.Comm(host=core_device)
|
||||||
try:
|
try:
|
||||||
coredev = core.Core(comm=comm)
|
coredev = core.Core(comm=comm)
|
||||||
uut = _RTIOUnderflow(
|
uut = _RTIOUnderflow(
|
||||||
|
@ -340,7 +340,7 @@ class RTIOCase(unittest.TestCase):
|
||||||
comm.close()
|
comm.close()
|
||||||
|
|
||||||
def test_sequence_error(self):
|
def test_sequence_error(self):
|
||||||
comm = comm_serial.Comm(serial_dev=core_device)
|
comm = comm_tcp.Comm(host=core_device)
|
||||||
try:
|
try:
|
||||||
coredev = core.Core(comm=comm)
|
coredev = core.Core(comm=comm)
|
||||||
uut = _RTIOSequenceError(
|
uut = _RTIOSequenceError(
|
||||||
|
|
Loading…
Reference in New Issue