Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix test_pager_as_cat test case on Solaris #663

Merged
merged 2 commits into from
Feb 6, 2022

Conversation

kulikjak
Copy link
Contributor

@kulikjak kulikjak commented Oct 19, 2020

On Solaris (and possibly other systems as I don't think this is standardized), the sleep manual page uses a lowercase name in the header, hence SLEEP is not found.

After this change, the test case will look for the section name, which AFAICT is always uppercase.

Alternatively, the assert can be changed to something like this:
assert 'SLEEP' in res.upper(), res

EDIT: The section name approach doesn't work (not sure why it seemed to work yesterday), so I changed it to the res.upper() approach instead. Thinking about that now, it is more robust and platform independent as well.

@rantala
Copy link

rantala commented Dec 22, 2020

Also the test should check that man is available:
FAILED tests/test_replwrap.py::REPLWrapTestCase::test_pager_as_cat - AssertionError: bash: man: command not found

@kulikjak
Copy link
Contributor Author

You are right, but I guess that a separate PR/Issue should be opened for that as that is not a problem on Solaris and fixes a slightly different thing.

@Red-M Red-M merged commit 7f14b2b into pexpect:master Feb 6, 2022
@Red-M
Copy link
Member

Red-M commented Feb 6, 2022

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants