Skip to content

Commit

Permalink
Update e2e-test.py
Browse files Browse the repository at this point in the history
  • Loading branch information
detsch committed Oct 10, 2024
1 parent 1328c9f commit caa8bfd
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions e2e-test.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ class ReturnCodes:
prune = True

factory_name = "detsch-aklite-test"
base_target_version = 54
base_target_version = 89

def get_target_version(offset):
return base_target_version + offset
Expand Down Expand Up @@ -138,6 +138,7 @@ def get_device_name():
# os.getenv("DEVICE_NAME", "aklite-test-device")

def verify_events(target_version, expected_events = None, second_to_last_corr_id = False):
logger.info(f"Verifying events for version {target_version}")
headers = {'OSF-TOKEN': osf_token}
r = requests.get(f'https://api.foundries.io/ota/devices/{device_name}/updates/', headers=headers)
d = json.loads(r.text)
Expand Down Expand Up @@ -175,6 +176,7 @@ def clear_callbacks_log():

# TODO: verify additional callback variables
def verify_callback(expected_calls):
logger.info(f"Verifying callbacks")
calls = []
if os.path.isfile(callback_log_path):
with open(callback_log_path) as f:
Expand Down Expand Up @@ -547,16 +549,15 @@ def run_test_sequence_update_to_latest():
check_running_apps(apps)


# @pytest.mark.parametrize('offline_', [False, True])
@pytest.mark.parametrize('offline_', [False])
@pytest.mark.parametrize('offline_', [True, False])
@pytest.mark.parametrize('single_step_', [True, False])
def test_incremental_updates(offline_, single_step_):
global offline, single_step
offline = offline_
single_step = single_step_
run_test_sequence_incremental()

@pytest.mark.parametrize('offline_', [False])
@pytest.mark.parametrize('offline_', [True, False])
@pytest.mark.parametrize('single_step_', [True, False])
def test_update_to_latest(offline_, single_step_):
global offline, single_step
Expand Down

0 comments on commit caa8bfd

Please sign in to comment.