Uh oh!
There was an error while loading. Please reload this page.
L1 tests reboot device - #84
Draft
StepanVovkPLV wants to merge 1 commit into
Draft
Conversation
StepanVovkPLV
requested review from
SerhiyBoikoPLV, anton7811 and yuriilisovskyiMarch 22, 2023 14:11
| yield | ||
| devices = await _get_dent_devs_from_testbed(testbed) | ||
| to_reboot = [dev.reboot() for dev in devices] | ||
| # up_ports = [dev.run_cmd("sudo onlpdump -S") for dev in devices] |
CollaboratorAuthor
There was a problem hiding this comment.
Can not perform onlpdump on the device. -> cmd not found
StepanVovkPLVforce-pushed
the
l1_tests_reboot_device
branch
4 times, most recently
from
March 28, 2023 16:25
bde955a to
4ba1a94CompareUh oh!
There was an error while loading. Please reload this page.
StepanVovkPLVforce-pushed
the
l1_tests_reboot_device
branch
3 times, most recently
from
April 6, 2023 06:56
761b676 to
35ca1d6Compareyuriilisovskyi
approved these changes
Apr 6, 2023
yuriilisovskyiforce-pushed
the
l1_tests_reboot_device
branch
from
April 20, 2023 14:38
35ca1d6 to
131ad5dCompare
This comment was marked as resolved.
This comment was marked as resolved.
StepanVovkPLVforce-pushed
the
l1_tests_reboot_device
branch
from
June 1, 2023 19:41
131ad5d to
20ffb68Compare
This comment was marked as resolved.
This comment was marked as resolved.
StepanVovkPLVforce-pushed
the
l1_tests_reboot_device
branch
from
June 1, 2023 19:44
f410ad9 to
5b01ffbCompareSerhiyBoikoPLV
requested changes
Jun 16, 2023
Comment on lines
+100
to
+103
| if reboot_after_test: | ||
| if reboot_after_test.name == item.name: |
Collaborator
There was a problem hiding this comment.
Suggested change
| ifreboot_after_test: | |
| ifreboot_after_test.name==item.name: | |
| ifreboot_after_testandreboot_after_test.name==item.name: |
Comment on lines
+176
to
+181
| to_reboot = [dev.reboot() for dev in devices] | ||
| up_ports = [dev.run_cmd('onlpd') for dev in devices] | ||
| await asyncio.gather(*to_reboot) | ||
| await asyncio.gather(*up_ports) |
Collaborator
There was a problem hiding this comment.
Suggested change
| to_reboot= [dev.reboot() fordevindevices] | |
| up_ports= [dev.run_cmd('onlpd') fordevindevices] | |
| awaitasyncio.gather(*to_reboot) | |
| awaitasyncio.gather(*up_ports) | |
| awaitasyncio.gather(*[dev.reboot() fordevindevices]) | |
| # https://github.com/dentproject/dentOS/issues/152#issuecomment-973264204 | |
| awaitasyncio.gather(*[dev.run_cmd('onlpd') fordevindevices]) |
Signed-off-by: Stepan Vovk <stepan.vovk@plvision.eu>
StepanVovkPLVforce-pushed
the
l1_tests_reboot_device
branch
from
July 20, 2023 07:47
2f19191 to
fe531c5Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Objective: if in collected tests we have at least one test_l1 we will sort the list with collected test items, and to the last test of the list(which will be last L1 test) we add additional fixture which will reboot device
def pytest_collection_modifyitems(session, config, items)will perform sorting of ALL the items based on the key providedpytest_collection_finish(session)hook we will select last test within current session and set the test where to add reboot fixtureasync def reboot_device(testbed)will perform reboot of the devicepytest_runtest_setup(item):we modify the last item in sortedsession.itemslist and addrebot_devicefixture