← 返回 Skills 市场
liuyun2025

Server Test Converter

作者 liuyun2025 · GitHub ↗ · v1.0.1 · MIT-0
cross-platform ⚠ suspicious
241
总下载
0
收藏
0
当前安装
2
版本数
在 OpenClaw 中安装
/install server-test-converter
功能描述
将服务器测试命令 txt 文件转换为 pytest 测试用例。每个 txt 文件对应生成一个独立的 pytest 文件,命令合并到一个函数中执行。包含通用框架 test_framework.py,适配各种测试环境。
安全使用建议
This skill appears to do what it says, but take these precautions before installing/using it: 1) Inspect your txt input files for sensitive data (passwords, tokens, IPs) because the generated pytest files will contain the command strings in cleartext. 2) Review and control the test_framework.py you use — the converter assumes you will implement send_a_cmd(); avoid hard-coding credentials in that implementation and prefer SSH keys or a secure credential store. 3) Run the converter and the produced tests in an isolated environment (non-production) until you verify behavior. 4) Verify output paths and permissions (the script writes to /home/admin/.openclaw/tytest). 5) If you need the tool to operate on a different path, update INPUT_DIR/OUTPUT_DIR in the script before running.
功能分析
Type: OpenClaw Skill Name: server-test-converter Version: 1.0.1 The skill converts server test command files into pytest scripts but contains a code injection vulnerability in `convert_commands.py`. The `escape_cmd` function fails to properly sanitize input by only doubling single quotes without handling backslashes; a crafted command like `\'); <malicious_code> #` could break out of the string literal in the generated Python file to execute arbitrary code. While the tool's behavior aligns with its stated purpose, this lack of robust input sanitization in a code-generation context represents a significant security risk.
能力评估
Purpose & Capability
Name/description match the implementation: the script reads txt files, parses commands, groups them by executor type, and emits pytest files and a reference test_framework. No unrelated binaries, services, or credentials are required.
Instruction Scope
SKILL.md and the script tightly bound to local paths under /home/admin/.openclaw and instruct the user to implement send_a_cmd() (SSH/subprocess/other). That is within scope, but the docs show examples with hard-coded credentials and the generated tests will contain the original command text verbatim — review inputs for sensitive data before generating or sharing outputs.
Install Mechanism
No install spec; this is instruction-only plus a Python script. Nothing is downloaded or written outside the declared output directory by the script itself.
Credentials
The skill declares no required environment variables or credentials. The examples in SKILL.md mention using paramiko or subprocess, but those are implementation suggestions the user must provide and do not create hidden credential requests.
Persistence & Privilege
always is false and the skill does not request persistent/autonomous privileges or modify other skills or global config.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install server-test-converter
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /server-test-converter 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.1
- 新增通用测试框架 test_framework.py,支持自定义命令执行逻辑,适配多种测试环境 - 生成的 pytest 文件现在依赖 test_framework.py,简化了环境集成和命令适配 - SKILL.md 文档优化,详细说明框架用法、配置步骤和 send_a_cmd() 实现方法 - 保持每个 txt 文件生成一个独立的 pytest 文件机制,并支持自动命令去重
v1.0.0
- Initial release of server-test-converter. - Converts server/network test command txt files into Pytest test cases, one Pytest file per txt file. - Merges commands from each txt into a single function, supporting both R5 card and host shell execution. - Automatically deduplicates commands and filters out invalid lines (variables, templates, comments, blanks). - Supports batch conversion, outputs to standardized locations, and handles Chinese file names and name conflicts.
元数据
Slug server-test-converter
版本 1.0.1
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 2
常见问题

Server Test Converter 是什么?

将服务器测试命令 txt 文件转换为 pytest 测试用例。每个 txt 文件对应生成一个独立的 pytest 文件,命令合并到一个函数中执行。包含通用框架 test_framework.py,适配各种测试环境。 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 241 次。

如何安装 Server Test Converter?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install server-test-converter」即可一键安装,无需额外配置。

Server Test Converter 是免费的吗?

是的,Server Test Converter 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

Server Test Converter 支持哪些平台?

Server Test Converter 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Server Test Converter?

由 liuyun2025(@liuyun2025)开发并维护,当前版本 v1.0.1。

💬 留言讨论