Skip to content
Merged
2 changes: 1 addition & 1 deletion .github/workflows/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
permissions: {}
name: API
runs-on: ubuntu-20.04
timeout-minutes: 40
timeout-minutes: 60
steps:
- name: Checkout source
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
Expand Down
10 changes: 8 additions & 2 deletions framework/python/src/api/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,8 +253,14 @@ def _generate_msg(self, success, message):
def _start_test_run(self):
self._test_run.start()

async def stop_test_run(self):
LOGGER.debug("Received stop command. Stopping Testrun")
async def stop_test_run(self, response: Response):
LOGGER.debug("Received stop command")

# Check if Testrun is running
if (self._test_run.get_session().get_status() not in
["In Progress", "Waiting for Device", "Monitoring"]):
response.status_code = 404
return self._generate_msg(False, "Testrun is not currently running")

self._test_run.stop()

Expand Down
9 changes: 0 additions & 9 deletions framework/python/src/common/testreport.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,6 @@ def __init__(self,
def get_mac_addr(self):
return self._mac_addr

def get_mac_addr(self):
return self._mac_addr

def add_module_reports(self, module_reports):
self._module_reports = module_reports

Expand Down Expand Up @@ -93,12 +90,6 @@ def set_report_url(self, url):

def get_report_url(self):
return self._report_url

def set_mac_addr(self, mac_addr):
self._mac_addr = mac_addr

def set_mac_addr(self, mac_addr):
self._mac_addr = mac_addr

def set_mac_addr(self, mac_addr):
self._mac_addr = mac_addr
Expand Down
2 changes: 1 addition & 1 deletion make/DEBIAN/prerm
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,5 @@ docker_images=$(sudo docker images --filter=reference="test-run/*" -q)
if [ -z "$docker_images" ]; then
echo No docker images to delete
else
sudo docker rmi $docker_images > /dev/null
sudo docker rmi -f $docker_images > /dev/null
fi
2 changes: 1 addition & 1 deletion modules/test/tls/python/src/tls_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ def __init__(self,
# # cert_table = (f'| Property | Value |\n'
# # f'|---|---|\n'
# # f"| {'Version':<17} | {version_value:^25} |\n"
# # f"| {'Signature Alg.':<17} |
# # f"| {'Signature Alg.':<17} |
# {signature_alg_value:^25} |\n"
# # f"| {'Validity from':<17} | {not_before:^25} |\n"
# # f"| {'Valid to':<17} | {not_after:^25} |")
Expand Down
2 changes: 1 addition & 1 deletion testing/api/mockito/invalid_request.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"error": "Invalid request received"
"detail": "Not Found"
}
4 changes: 2 additions & 2 deletions testing/api/test_api
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ sudo docker network create -d macvlan -o parent=endev0b endev0
# Start OVS
sudo /usr/share/openvswitch/scripts/ovs-ctl start

# Build Test Container
sudo docker build ./testing/docker/ci_test_device1 -t ci_test_device1 -f ./testing/docker/ci_test_device1/Dockerfile
# Build test container
sudo docker build ./testing/docker/ci_test_device1 -t test-run/ci_device_1 -f ./testing/docker/ci_test_device1/Dockerfile

sudo chown -R $USER local

Expand Down
Loading