xonsh/tests
Peter Ye 08b302364a
Update terminal title before executing subprocess (#4916)
* Update terminal title before executing subprocess

This eliminates the need to use `pause_call_resume()`, which causes issues
when it sends SIGSTOP to a process that is in the middle of a syscall
(for example, the `swaymsg` command fails when it gets stopped during
a `recv` syscall).

Additionally, this approach is more flexible, as it allows captured
commands and callable aliases to also be updated as expected in the
terminal's title.

* Clear prompt cache in readline shell

* Add type annotation

* Use reset_key() to only reset current_job

* Convert into PromptField class

* Support PromptField with value of None

Allows {current_job:{} | } to work as expected when current_job is a
PromptField.

* Add tests
2022-08-10 09:50:09 +05:30
..
aliases test: update tests 2022-03-24 19:49:30 +05:30
bin style: isort imports 2022-01-31 11:16:51 -05:00
completers Fixing bash completion bug when prefix started with '>', '<', or ':' (#4826) 2022-08-06 14:37:09 +05:30
histories Fix tests 2020-09-23 21:15:37 +02:00
man1 improve completers (#4648) 2022-01-27 21:22:36 +05:30
procs Change ![] to return an object for background command (#4823) 2022-06-05 21:10:21 +05:30
prompt Update terminal title before executing subprocess (#4916) 2022-08-10 09:50:09 +05:30
scripts xonsh script.xsh should not fail over 2017-01-11 21:59:42 +08:00
test_lib chore: update tests 2022-03-24 19:49:30 +05:30
xontribs feat: filter completions from fish (#4765) 2022-05-22 22:44:36 +05:30
xoreutils Add uname command, Update uptime comand (#3909) 2022-01-08 18:28:46 +05:30
xpack fix: do not append empty/comment-only input to history (#4822) 2022-05-26 17:50:08 +05:30
.somedotfile dotfile matching 2018-09-12 18:12:02 -04:00
bashrc.sh added tests for foreign shells 2015-10-10 19:52:53 -04:00
batch.bat Add test for sourcing bat file on windows 2016-04-18 00:41:11 +02:00
conftest.py Fix vox env dir (#4736) 2022-03-27 17:12:52 +05:30
run_pwd.xsh more fixes 2016-09-09 00:58:32 -04:00
sample.xsh fixed up dashing 2018-11-08 13:16:44 -05:00
test_aliases.py We can't be sure there's a python binary (#4917) 2022-08-09 21:12:40 +05:30
test_ansi_colors.py style: isort imports 2022-01-31 11:16:51 -05:00
test_ast.py style: sort imports 2022-03-24 19:49:30 +05:30
test_base_shell.py fix: do not append empty/comment-only input to history (#4822) 2022-05-26 17:50:08 +05:30
test_bashisms.py style: isort imports 2022-01-31 11:16:51 -05:00
test_builtins.py style: sort imports 2022-03-24 19:49:30 +05:30
test_cli_utils.py history transfer (#4604) 2021-12-20 08:36:29 +05:30
test_color_tools.py Fix tests 2020-09-23 21:15:37 +02:00
test_commands_cache.py style: sort imports 2022-03-24 19:49:30 +05:30
test_completer.py style: isort imports 2022-01-31 11:16:51 -05:00
test_completion_context.py Fixing bash completion bug when prefix started with '>', '<', or ':' (#4826) 2022-08-06 14:37:09 +05:30
test_contexts.py style: isort imports 2022-01-31 11:16:51 -05:00
test_dirstack.py style: isort imports 2022-01-31 11:16:51 -05:00
test_dirstack_unc.py test: python completers have become flaky 2022-03-22 19:13:11 +05:30
test_environ.py style: sort imports 2022-03-24 19:49:30 +05:30
test_events.py style: isort imports 2022-01-31 11:16:51 -05:00
test_execer.py chore: update tests 2022-03-24 19:49:30 +05:30
test_foreign_shells.py style: sort imports 2022-03-24 19:49:30 +05:30
test_history_dummy.py history transfer (#4604) 2021-12-20 08:36:29 +05:30
test_history_json.py style: isort imports 2022-01-31 11:16:51 -05:00
test_history_sqlite.py style: isort imports 2022-01-31 11:16:51 -05:00
test_imphooks.py fix: do not append empty/comment-only input to history (#4822) 2022-05-26 17:50:08 +05:30
test_integrations.py Fix job control for callable aliases (#4901) 2022-08-03 11:37:26 +05:30
test_jobs.py Fix job control for callable aliases (#4901) 2022-08-03 11:37:26 +05:30
test_jsonutils.py style: isort imports 2022-01-31 11:16:51 -05:00
test_lazyasd.py black tests 2018-08-30 09:18:49 -05:00
test_lazyjson.py style: isort imports 2022-01-31 11:16:51 -05:00
test_lexer.py style: isort imports 2022-01-31 11:16:51 -05:00
test_main.py Pr5 xontrib entrypoints (#4827) 2022-06-17 12:39:12 -04:00
test_man.py style: sort imports 2022-03-24 19:49:30 +05:30
test_news.py style: isort imports 2022-01-31 11:16:51 -05:00
test_parser.py fix: string literal concatenation (#4838) 2022-06-18 08:34:34 +05:30
test_pipelines.py Fix job control for callable aliases (#4901) 2022-08-03 11:37:26 +05:30
test_platform.py style: isort imports 2022-01-31 11:16:51 -05:00
test_pretty.py fix: item order of pretty-printed dictionaries (#4786) 2022-04-30 08:25:52 +05:30
test_ptk_completer.py style: isort imports 2022-01-31 11:16:51 -05:00
test_ptk_highlight.py style: sort imports 2022-03-24 19:49:30 +05:30
test_ptk_history.py refactor: remove xonsh.ptk2 module (#4570) 2021-11-30 08:22:31 -05:00
test_ptk_multiline.py style: isort imports 2022-01-31 11:16:51 -05:00
test_ptk_shell.py fix: do not append empty/comment-only input to history (#4822) 2022-05-26 17:50:08 +05:30
test_pyghooks.py fix(pyghooks): Fix some errors caused by an unset Xonsh session env when using XonshLexer as a Pygments plugin. (#4860) 2022-06-30 10:40:58 -04:00
test_readline_shell.py Add test for readline shell (#4447) 2021-09-02 22:15:20 +03:00
test_shell.py style: isort imports 2022-01-31 11:16:51 -05:00
test_tools.py style: sort imports 2022-03-24 19:49:30 +05:30
test_tracer.py pre-commit hook for pyupgrade (#4583) 2021-12-06 14:42:26 -05:00
test_virtualenv_activator.py We can't be sure there's a python binary (#4802) 2022-05-10 15:55:03 +05:30
test_vox.py Fix vox env dir (#4736) 2022-03-27 17:12:52 +05:30
test_wizard.py style: isort imports 2022-01-31 11:16:51 -05:00
test_xonfig.py test: add back xonfig-info test 2022-03-25 10:41:42 -04:00
test_xonsh.xsh Remove globals (#4280) 2021-05-20 13:14:26 +03:00
test_xontribs.py xontrib load/unload (#4817) 2022-05-30 15:33:17 +05:30