-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
test: add tests for star base class and config management #5356
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
Open
whatevertogo
wants to merge
14
commits into
AstrBotDevs:master
Choose a base branch
from
whatevertogo:test/core-star-config
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+1,933
−145
Open
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
f81d14f
test: add tests for star base class and config management
whatevertogo 6aacf01
Merge branch 'AstrBotDevs:master' into test/core-star-config
whatevertogo 587de55
test: fix plugin_manager test isolation issues
whatevertogo a122c7e
test: fix test isolation and compatibility issues
whatevertogo d611e4d
test: add unit tests for _version_info comparisons
whatevertogo f8d0e3b
test: enhance plugin manager tests with mock implementations and impr…
whatevertogo d2b831a
test: add mock plugin builder and updater for plugin management tests
whatevertogo 81469d5
Merge branch 'AstrBotDevs:master' into fix/test-plugin-manager-compat…
whatevertogo b7519c9
fix: resolve pipeline and star import cycles (#5353)
whatevertogo 5f7b326
test: update cron job scheduling tests and refactor star base tests f…
whatevertogo c7767ef
test: expand star base tests for comprehensive coverage
whatevertogo 91851d6
fix: address PR review feedback - use TYPE_CHECKING instead of Any
whatevertogo 0dad23a
merge: combine test/core-star-config with fix/test-plugin-manager-com…
whatevertogo 95ad804
fix: improve TYPE_CHECKING pattern for circular import resolution
whatevertogo File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,19 +1,22 @@ | ||
| from __future__ import annotations | ||
|
|
||
| from dataclasses import dataclass | ||
| from typing import Any | ||
| from typing import TYPE_CHECKING | ||
|
|
||
| from astrbot.core.config import AstrBotConfig | ||
|
|
||
| from .context_utils import call_event_hook, call_handler | ||
|
|
||
| if TYPE_CHECKING: | ||
| from astrbot.core.star import PluginManager | ||
|
|
||
|
|
||
| @dataclass | ||
| class PipelineContext: | ||
| """上下文对象,包含管道执行所需的上下文信息""" | ||
|
|
||
| astrbot_config: AstrBotConfig # AstrBot 配置对象 | ||
| plugin_manager: Any # 插件管理器对象 | ||
| plugin_manager: PluginManager # 插件管理器对象 | ||
| astrbot_config_id: str | ||
| call_handler = call_handler | ||
| call_event_hook = call_event_hook |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
whatevertogo marked this conversation as resolved.
Show resolved
Hide resolved
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.