cockpit icon indicating copy to clipboard operation
cockpit copied to clipboard

add MachineCase.reboot and MachineCase.wait_reboot functions

Open Akshat2Jain opened this issue 1 year ago • 7 comments

. added two functions in the machine class reboot(self, timeout_sec), wait_reboot(self, timeout_sec) . adjusted the m.wait_reboot to self.wait_reboot

This pr is related to the issue

Akshat2Jain avatar Jun 07 '23 14:06 Akshat2Jain

Hey @jelly Can you review this, I added the conditions

Akshat2Jain avatar Jun 14 '23 06:06 Akshat2Jain

Do you still want to continue on this, or want me to take over and finish it? This PR is a bit stale. The new API can be applied to more tests (such as test/verify/check-system-info testCryptoPolicies), but of course we can do that in follow-ups.

Thanks!

I requested for review but did not get any. I will update the changes you suggested Thanks

Akshat2Jain avatar Nov 13 '23 12:11 Akshat2Jain

@Akshat2Jain are you still interested in this?

martinpitt avatar Dec 05 '23 07:12 martinpitt

@Akshat2Jain I see the unit tests failing, it's mostly whitespace and empty lines, like one introduced in this commit and an extra ':' at https://github.com/cockpit-project/cockpit/pull/18897/files#diff-fdfce066f8a78233d7423f73a8ab6f0e060584f8623b8558f0b2a0f131b79319R2176.

Please fix those. You can run test/static-code locally in your tasks container to see the issues. Some of them can be fixed with ruff check --fix .

subhoghoshX avatar Dec 06 '23 06:12 subhoghoshX

@Akshat2Jain you latest commits fixes some of the white space and blank line issues, there are still a few more left. Thanks!

subhoghoshX avatar Dec 10 '23 07:12 subhoghoshX

@Akshat2Jain you latest commits fixes some of the white space and blank line issues, there are still a few more left. Thanks!

I fixed it in the commit (there are too many commits now, it has to be squashed at the end...). tox and uni-tests doesn't complain anymore \o/. Please pull it.

Let's land it after it's approved.

subhoghoshX avatar Dec 10 '23 07:12 subhoghoshX

More generally, in the current form this doesn't feel like a good trade: It replaces one allow_messages() call with two more new APIs

martinpitt avatar Dec 11 '23 11:12 martinpitt