Commit graph

19 commits

Author SHA1 Message Date
pre-commit-ci[bot]
66c0490d37
[pre-commit.ci] pre-commit autoupdate (#5271)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/psf/black: 23.12.1 → 24.1.1](https://github.com/psf/black/compare/23.12.1...24.1.1)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-01-30 12:23:50 +01:00
Noortheen Raja
78091a22f3 style: isort imports
fix #4584
2022-01-31 11:16:51 -05:00
Noorhteen Raja NJ
7c4e207abd
update test xsh usage (#4581)
* todo

* test: remove usage of DummyEnv and setting .env attribute on xession fixture

one step closer to making too much of tweaking to xession during tests

* test: fix tests vox and gitstatus-prompt

* docs: update test-fixture usage

* fix: import flake8 error

* test: remove direct access to XSH in tests

* test: remove usage of XSH in test files

* todo

* test: use tmp-dir to create stubs

* refactor: use fixture factory to mock out XonshSession

* refactor: remove direct access of XSH from functions

* refactor: remove direct access of XSH from functions

* fix: qa checks

* refactor: rename variables to match their values

* test: update failing tests because it had no PATH set previously

* fix: remove builtins usage from pyghooks.py

* style:

* refactor: update tests to use fixtures

* fix: env varialbe is setup per function

some tests accidentally update the env variables and that is leaking
into next tests

* fix: failing vox tests

* test: set commands_cache per test

* test: fix failing tests

* fix: failing tests on linux

ptk-highlight

* fix: failing tests on Windows

cwd-prompt

* test: copy env as to not affect original object

* fix: lazily evaluate cmds-cache in pyghooks

* test: fix failing tests

* fix: qa errors import

* test: set commands-cache per test

while caching path results

* test: speedup test_thread_local_swap

* fix: failing tests on windows

* refactor: Execer doesn't control session

* refactor: XSH.unload will take care of reversing builtins attrs set

* test: use env.update over monkeypatch

* Revert "test: use env.update over monkeypatch"

This reverts commit 010a5022247a098f1741966b8af1bf758663480e.
2022-01-07 17:33:22 -05:00
Anthony Scopatz
634a8ec9f2 black tests 2018-08-30 09:18:49 -05:00
Anthony Scopatz
fa3730cf44 rewrite of xonsh contexts to be based off of macros. 2017-01-10 01:58:21 -05:00
Matthias Bussonnier
c42b1fa135 Don't reuse variables names in tests.
Since http://bugs.python.org/issue27999, global after use is a
SyntaxError; reusing variable name in tests/test_contexts.py
lead to failure.

Should close #1718
2016-09-12 10:01:16 -07:00
laerus
bea8c62829 tests bugs fixing/test_parser & test_tools to go 2016-07-01 21:52:37 +03:00
Konstantinos Tsakiltzidis
2c6fb2e6f7 'need more fixtures' 2016-06-25 13:38:43 +03:00
Gil Forsyth
6f4fc7564e cleanup and extra fixes 2016-06-22 18:23:36 -04:00
Gil Forsyth
81ab922a12 port ast and contexts to pytest 2016-06-22 17:12:33 -04:00
Gil Forsyth
39a0167c11 fix setup in test_contexts 2016-06-22 10:06:55 -04:00
Anthony Scopatz
037b9e002b have functor 2016-06-05 21:44:03 -04:00
Anthony Scopatz
67b6d2abe9 suppress syntax warnings thrown by compile 2016-06-05 20:01:26 -04:00
Anthony Scopatz
bb5c420446 more context function tests 2016-06-05 18:34:37 -04:00
Anthony Scopatz
6e387e521b functional tests 2016-06-05 18:25:52 -04:00
Anthony Scopatz
a1d3b73a71 many closing test 2016-06-05 17:49:12 -04:00
Anthony Scopatz
9fab87a743 ending close paren 2016-06-05 17:44:21 -04:00
Anthony Scopatz
b5d90b5a88 block test refactor 2016-06-05 17:02:10 -04:00
Anthony Scopatz
1643e1692e oh, yeah, blocks 2016-06-05 16:25:43 -04:00