diff --git a/example_designs/make.py b/example_designs/make.py old mode 100644 new mode 100755 diff --git a/test/Makefile b/test/Makefile index 0f3ccc2..36575a1 100644 --- a/test/Makefile +++ b/test/Makefile @@ -3,12 +3,12 @@ PYTHON = python3 CMD = $(PYTHON) model_tb: - PYTHONPATH=./ $(CMD) ./model/mac.py - PYTHONPATH=./ $(CMD) ./model/arp.py - PYTHONPATH=./ $(CMD) ./model/ip.py - PYTHONPATH=./ $(CMD) ./model/udp.py - PYTHONPATH=./ $(CMD) ./model/icmp.py - PYTHONPATH=./ $(CMD) ./model/etherbone.py + cd ../ && PYTHONPATH=./ $(CMD) test/model/mac.py + cd ../ && PYTHONPATH=./ $(CMD) test/model/arp.py + cd ../ && PYTHONPATH=./ $(CMD) test/model/ip.py + cd ../ && PYTHONPATH=./ $(CMD) test/model/udp.py + cd ../ && PYTHONPATH=./ $(CMD) test/model/icmp.py + cd ../ && PYTHONPATH=./ $(CMD) test/model/etherbone.py example_designs: cd ../example_designs && $(PYTHON) make.py -t base -s BaseSoC -p kc705 -Ob run False build-bitstream diff --git a/test/model/arp.py b/test/model/arp.py index 1604730..6b9eba4 100644 --- a/test/model/arp.py +++ b/test/model/arp.py @@ -124,8 +124,8 @@ class ARP(Module): request.target_ip = ip_address if __name__ == "__main__": - from model.dumps import * - from model.mac import * + from test.model.dumps import * + from test.model.mac import * errors = 0 # ARP request packet = MACPacket(arp_request) diff --git a/test/model/icmp.py b/test/model/icmp.py index 8ab900e..1b2b200 100644 --- a/test/model/icmp.py +++ b/test/model/icmp.py @@ -85,9 +85,9 @@ class ICMP(Module): pass if __name__ == "__main__": - from model.dumps import * - from model.mac import * - from model.ip import * + from test.model.dumps import * + from test.model.mac import * + from test.model.ip import * errors = 0 # ICMP packet packet = MACPacket(ping_request) diff --git a/test/model/ip.py b/test/model/ip.py index 36264be..0ca3785 100644 --- a/test/model/ip.py +++ b/test/model/ip.py @@ -132,8 +132,8 @@ class IP(Module): self.icmp_callback(packet) if __name__ == "__main__": - from model.dumps import * - from model.mac import * + from test.model.dumps import * + from test.model.mac import * errors = 0 # UDP packet packet = MACPacket(udp) diff --git a/test/model/mac.py b/test/model/mac.py index 5eab4ac..765ff02 100644 --- a/test/model/mac.py +++ b/test/model/mac.py @@ -135,7 +135,7 @@ class MAC(Module): raise ValueError # XXX handle this properly if __name__ == "__main__": - from model.dumps import * + from test.model.dumps import * errors = 0 packet = MACPacket(arp_request) packet.decode_remove_header() diff --git a/test/model/udp.py b/test/model/udp.py index 495e3fe..322bf03 100644 --- a/test/model/udp.py +++ b/test/model/udp.py @@ -96,9 +96,9 @@ class UDP(Module): self.etherbone_callback(packet) if __name__ == "__main__": - from model.dumps import * - from model.mac import * - from model.ip import * + from test.model.dumps import * + from test.model.mac import * + from test.model.ip import * errors = 0 # UDP packet packet = MACPacket(udp)