Commit graph

28 commits

Author SHA1 Message Date
andrew000
9820de1025
ADD tests for HistoryManager 2023-11-22 01:20:01 +02:00
andrew000
decd5e4ac2
Refactor ObserverDecorator to use on.message syntax in test_scene.py
Cover `Scene::__init_subclass__::if isinstance(value, ObserverDecorator):`
2023-11-21 23:18:53 +02:00
andrew000
44a0539954
ADD tests for Scene 2023-11-21 22:24:45 +02:00
andrew000
50ac7adaa7
ADD tests for SceneWizard 2023-11-21 19:18:56 +02:00
Andrew
afbad8df6e
Scenes Tests (#1369)
* ADD tests for `SceneRegistry`

* ADD tests for `ScenesManager`

* ADD Changelog

* Revert "ADD Changelog"

This reverts commit 6dd9301252.

* Remove `@pytest.mark.asyncio`, Reformat code
2023-11-20 21:36:36 +02:00
JRoot Junior
9514e60b98
Merge branch 'dev-3.x' into scenes 2023-11-19 16:24:45 +02:00
JRoot Junior
dd1e8085bf
Fixed Py3.12 tests 2023-11-18 21:28:34 +02:00
Nachtalb
c1bafea3e8
Upgrade to py12 (#1354)
* Upgrade to py12 compatible aiohttp beta version

* Fix uvloop deprecation warning causing pytest not to run

* Fix test due to asyncio task scheduling race condition

* Fix test_state_in_unknown_class for Python 3.12+ due to PEP 678 changes

* Add Python 3.12 support in GitHub Actions and project configurations

* Add changelog entry

---------

Co-authored-by: Alex Root Junior <jroot.junior@gmail.com>
2023-11-18 21:24:19 +02:00
JRoot Junior
b5f7867451
Compatibility... 2023-11-18 01:43:03 +02:00
JRoot Junior
2c1c2fcc03
Compatibility... 2023-11-18 01:37:44 +02:00
JRoot Junior
835c2c2f4e
Compatibility... 2023-11-18 01:34:06 +02:00
JRoot Junior
36aab46754
Change mock return_value 2023-11-18 01:31:33 +02:00
JRoot Junior
2b36338ca2
Skip some tests on PyPy 2023-11-17 00:42:06 +02:00
JRoot Junior
5d168b369f
Reformat code 2023-11-17 00:30:34 +02:00
JRoot Junior
da63394146
Expand test coverage for test_fsm module
The commit enhances tests for the test_fsm module to improve code reliability. It includes additional unit tests for the ObserverDecorator and ActionContainer classes and introduces new tests for the SceneHandlerWrapper class. This ensures the correct functionality of the decorator methods, the action container execution, and the handler wrapper.
2023-11-17 00:21:28 +02:00
JRoot Junior
85b024cf78
Fixed test 2023-11-16 22:59:53 +02:00
JRoot Junior
82f1c8a418
Merge branch 'dev-3.x' into scenes
# Conflicts:
#	tests/test_dispatcher/test_event/test_handler.py
2023-11-16 22:55:36 +02:00
Alex Root Junior
3ad5ed6bc2
Fixed ResourceWarnings in tests (#1366)
* #1320 Update pytest configuration and tests cleanup

This commit modifies the pytest's configuration file, `pyproject.toml`, to remove filterwarnings settings. It also makes changes in various test files; the Redis isolation test is now using the provided `redis_storage` fixture instead of setting up its own connection, pytest.mark.filterwarnings is no longer used in `test_isolation.py` and `test_aiohttp_session.py` properly closes off sessions.

* Added changelog

* Fixed coverage for the RedisEventIsolation
2023-11-16 02:08:36 +02:00
JRoot Junior
a8c790a030
Merge branch 'dev-3.x' into scenes 2023-11-09 23:59:54 +02:00
Alex Root Junior
28da0e8f1b
Init tests 2023-11-09 21:18:15 +02:00
ZeroN
d8e7801963
Add new FSM strategy CHAT_TOPIC strategy.py (#1344)
* Create 1343.feature.rst

* Add new FSM strategy CHAT_TOPIC strategy.py

* ADD CHAT_TOPIC tests test_strategy.py

* Update 1343.feature.rst

* Update strategy.py

* add typing  user_id: Optional[int] = None, middleware.py

* add typing  user_id: Optional[int] = None  base.py

* Update strategy.py

* Update strategy.py

* Update middleware.py

* Update base.py

* Update test_strategy.py

* Update base.py

* Update strategy.py
2023-10-22 00:41:13 +03:00
Oleg A
eacea996d4
Handle expected warnings & raise unexpected warnings (#1315)
* chore: replace fixture loop with event_loop

* chore: mark expected warnings

* chore: raise unexpected warnings

* chore: rm unused record

* fix: rm parenthesized context manager

* chore: warnings shall not pass

* chore: replace fixture loop with event_loop

* chore: mark expected warnings

* chore: raise unexpected warnings

* chore: rm unused record

* fix: rm parenthesized context manager

* chore: warnings shall not pass

* Revert "chore: raise unexpected warnings"

This reverts commit 4c91df243d.

* chore: warnings shall not pass v2

* fix: graceful aiohttp session close

* chore: minor typo

* chore: mark expected warnings

* fix: temporary mute ResourceWarning

#1320

* fix: close pool with redis

* chore: code reformat and lint

* chore: simplify tests with fixture

* chore: make aresponses clear

* chore: divide asserts with blank line

* chore: rm duplicated assertions

* chore: rm unnecessary extra

* chore: bump test dependencies

* chore: bump test dependencies (fix)
2023-10-01 15:28:54 +03:00
Alex Root Junior
066d16b522
#1186 Renamed USER_IN_THREAD to USER_IN_TOPIC 2023-07-01 21:53:34 +03:00
Alex Root Junior
942ba0d520
Forum topic in FSM (#1161)
* Base implementation

* Added tests, fixed arguments priority

* Use `Optional[X]` instead of `X | None`

* Added changelog

* Added tests
2023-04-22 19:35:41 +03:00
RootShinobi
dbaf6fabcb
storage cleanup (#1144)
* storage cleanup

* storage cleanup
2023-04-08 18:01:11 +03:00
Alex Root Junior
f4ce4431f9
Migrate to hatchling (#1095)
* Migrate to hatchling instead of poetry, ruff instead of flake8

* Migrate to hatchling instead of poetry, ruff instead of flake8

* Update tests suite

* venv?

* -m venv?

* Change dependencies

* Remove venv

* Change mypy config

* Added changelog

* Mark uvloop incompatible with pypy

* Update release script

* Use internal caching for dependencies

* Re-disable cov branches

* Added contributing guide
2023-01-12 02:49:58 +02:00
Alex Root Junior
655b3a2d48
Remove warnings about pytest asyncio mode 2022-12-30 16:10:06 +02:00
Alex Root Junior
4315ecf1a2
Dev 3.x flat package (#961)
* Move packages

* Added changelog

* Update examples/echo_bot.py

Co-authored-by: Oleg A. <t0rr@mail.ru>

* Rename `handler` -> `handlers`

* Update __init__.py

Co-authored-by: Oleg A. <t0rr@mail.ru>
2022-08-14 01:07:52 +03:00