Hi,
I forked this repo and tried adding support to xonsh shell but i have problems with tests. Can someone more experienced with python/pytest look at these errors and tell me if I did something wrong (and what)?
Xonsh must be treated similarly to ptpython, so PrettyDir.__repr__() method should print self.repr_str not return it (just like for ptpython). So I made small changes in https://github.com/tkossak/pdir2/commit/24c43ba9bb05b732c66ae09e665dbb5dc4f0e95c and it works for me. The problem is with tests, which now return these errors. For me it seems like for xonsh and ptpython this assert: result.repr_str == repr(result) should always fail because __repr__() always returns null string for these shells. If so, why the tests work for ptpython and not for xonsh?
Thank you.
Hi,
I forked this repo and tried adding support to xonsh shell but i have problems with tests. Can someone more experienced with python/pytest look at these errors and tell me if I did something wrong (and what)?
Xonsh must be treated similarly to ptpython, so
PrettyDir.__repr__()method should printself.repr_strnot return it (just like for ptpython). So I made small changes in https://github.com/tkossak/pdir2/commit/24c43ba9bb05b732c66ae09e665dbb5dc4f0e95c and it works for me. The problem is with tests, which now return these errors. For me it seems like for xonsh and ptpython this assert:result.repr_str == repr(result)should always fail because__repr__()always returns null string for these shells. If so, why the tests work for ptpython and not for xonsh?Thank you.