@super-coding/cli 0.2.2 → 0.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -1
- package/dist/bin/pc-darwin-arm64 +0 -0
- package/dist/bin/pc-linux-x64 +0 -0
- package/dist/cli.js +20 -2
- package/dist/daemon/agent/builtin/agent.md +120 -21
- package/dist/daemon/agent/builtin/load.js +1 -0
- package/dist/daemon/agent/builtin/parse.js +2 -0
- package/dist/daemon/agent/index.js +1 -0
- package/dist/daemon/agent/resolve.js +19 -1
- package/dist/daemon/index.js +43 -8
- package/dist/daemon/local-path.js +43 -0
- package/dist/daemon/manage.js +35 -3
- package/dist/daemon/orchestrator.js +116 -1
- package/dist/daemon/session/store.js +12 -0
- package/dist/daemon/urls.js +9 -0
- package/dist/pingcode/builtin/SKILL.md +41 -14
- package/dist/pingcode/builtin/reference-cross.md +172 -0
- package/dist/pingcode/builtin/reference-org-wiki.md +127 -0
- package/dist/pingcode/builtin/reference-ship.md +282 -0
- package/dist/pingcode/builtin/reference-testhub.md +172 -0
- package/dist/pingcode/builtin/reference.md +351 -50
- package/dist/pingcode/cli.js +14 -3
- package/dist/pingcode/detect.js +71 -11
- package/dist/pingcode/index.js +2 -1
- package/dist/pingcode/remote-config.js +69 -0
- package/dist/pingcode/skill.js +30 -7
- package/dist/setup/index.js +329 -0
- package/dist/setup/prompt.js +129 -0
- package/dist/setup/ui.js +78 -0
- package/package.json +3 -2
|
@@ -0,0 +1,282 @@
|
|
|
1
|
+
# ship 命令速查(产品 / 需求 / 工单)
|
|
2
|
+
|
|
3
|
+
ship 是 PingCode 的**产品与客户反馈**模块:`product` 是父级,其下挂 `idea`(需求 / 想法)与
|
|
4
|
+
`ticket`(工单 / 客户问题)。本文件是该模块的完整命令表,通用约定见 `reference.md`。
|
|
5
|
+
|
|
6
|
+
## 层级与 ID 关系
|
|
7
|
+
|
|
8
|
+
```
|
|
9
|
+
product(产品)
|
|
10
|
+
├── product-member / product-tag / product-suite / product-plan / product-user / product-customer
|
|
11
|
+
├── idea(需求池)
|
|
12
|
+
│ └── idea-state / idea-type 相关字典都按「产品」维度配置
|
|
13
|
+
└── ticket(工单)
|
|
14
|
+
└── ticket-state / ticket-type / ticket-solution 同样按「产品」维度配置
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
- **列表基本都要按产品过滤**:`idea list --product-id <PID>`、`ticket list --product-id <PID>`。
|
|
18
|
+
这两处 `--product-id` 语法上虽然可选,但**不传会跨产品混在一起**,基本等于查错了对象;
|
|
19
|
+
先 `pc ship product list --keywords "产品名"` 拿 ID。
|
|
20
|
+
- **状态 / 类型 / 优先级字典按产品查**,不同产品可能不一样,不要跨产品复用 ID:
|
|
21
|
+
`idea-state list --product-id <PID>`、`ticket-state list --product-id <PID>`。
|
|
22
|
+
- `*-plan` 类命令(`idea-plan` / `product-plan` / `idea-property-plan` …)是「方案」对象,
|
|
23
|
+
要按位置参数 `<ID>` 或 `--product-id` 查,不是全局列表。
|
|
24
|
+
|
|
25
|
+
## 写操作的必知事项
|
|
26
|
+
|
|
27
|
+
- **`idea` 与 `ticket` 没有 `delete` 子命令**。要「关闭」它们只能 `update` 改 `state_id`,
|
|
28
|
+
不要重复尝试 `delete`。
|
|
29
|
+
- `idea` / `ticket` 的 `create` / `update` 都用 `--data '<JSON>'`,字段名以接口为准;
|
|
30
|
+
不确定时先 `get` 一条同类对象,照着它的字段结构写。
|
|
31
|
+
- `ticket-solution`(解决方案)是独立字典,工单解决时用它填 `solution_id`。
|
|
32
|
+
- `product-customer` / `product-user` 是客户与使用者,和 `organization user`(内部成员)不是一回事。
|
|
33
|
+
|
|
34
|
+
## 命令表
|
|
35
|
+
|
|
36
|
+
### `ship idea` — 需求(想法)(list / get / create / update / search)
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
pc ship idea list [--product-id <ID>] [--state-id <ID>] [--priority-id <ID>] \
|
|
40
|
+
[--keywords <KEYWORDS>] [--include-public-image-token <FIELDS>] [--page-index <INDEX>] \
|
|
41
|
+
[--page-size <SIZE>]
|
|
42
|
+
pc ship idea get <IDEA_ID> [--include-public-image-token <FIELDS>] [--include-deleted]
|
|
43
|
+
pc ship idea create --data <JSON>
|
|
44
|
+
pc ship idea update --data <JSON> <IDEA_ID>
|
|
45
|
+
pc ship idea search --data <JSON>
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
### `ship idea-plan` — 需求排期(list-for-product)
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
pc ship idea-plan list-for-product <ID>
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### `ship idea-priority` — 需求优先级(list / list-for-product / get)
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
pc ship idea-priority list [--page-index <INDEX>] [--page-size <SIZE>]
|
|
58
|
+
pc ship idea-priority list-for-product <ID>
|
|
59
|
+
pc ship idea-priority get <PRIORITY_ID>
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
### `ship idea-property` — 需求属性定义(list / list-for-product / get / create / update)
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
pc ship idea-property list [--page-index <INDEX>] [--page-size <SIZE>]
|
|
66
|
+
pc ship idea-property list-for-product <ID>
|
|
67
|
+
pc ship idea-property get <PROPERTY_ID>
|
|
68
|
+
pc ship idea-property create --data <JSON>
|
|
69
|
+
pc ship idea-property update --data <JSON> <PROPERTY_ID>
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
### `ship idea-property-plan` — 需求属性方案(list / get / add-property / list-properties / get-property / remove-property)
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
pc ship idea-property-plan list [--page-index <INDEX>] [--page-size <SIZE>]
|
|
76
|
+
pc ship idea-property-plan get <PROPERTY_PLAN_ID>
|
|
77
|
+
pc ship idea-property-plan add-property --data <JSON> <PROPERTY_PLAN_ID>
|
|
78
|
+
pc ship idea-property-plan list-properties <PROPERTY_PLAN_ID>
|
|
79
|
+
pc ship idea-property-plan get-property <PROPERTY_PLAN_ID> <PROPERTY_ID>
|
|
80
|
+
pc ship idea-property-plan remove-property <PROPERTY_PLAN_ID> <PROPERTY_ID>
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### `ship idea-state` — 需求状态(list / list-for-product / get)
|
|
84
|
+
|
|
85
|
+
```bash
|
|
86
|
+
pc ship idea-state list [--page-index <INDEX>] [--page-size <SIZE>]
|
|
87
|
+
pc ship idea-state list-for-product <ID>
|
|
88
|
+
pc ship idea-state get <IDEA_STATE_ID>
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
### `ship idea-suite` — 需求集(list-for-product)
|
|
92
|
+
|
|
93
|
+
```bash
|
|
94
|
+
pc ship idea-suite list-for-product <ID>
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
### `ship idea-transition` — 需求流转(list / get)
|
|
98
|
+
|
|
99
|
+
```bash
|
|
100
|
+
pc ship idea-transition list <IDEA_ID>
|
|
101
|
+
pc ship idea-transition get <IDEA_ID> <TRANSITION_HISTORY_ID>
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
### `ship product` — 产品(list / get / create / update)
|
|
105
|
+
|
|
106
|
+
```bash
|
|
107
|
+
pc ship product list [--scope-type <SCOPE_TYPE>] [--scope-id <ID>] [--keywords <KEYWORDS>] \
|
|
108
|
+
[--member-type <TYPE>] [--member-id <ID>] [--created-between <RANGE>] \
|
|
109
|
+
[--updated-between <RANGE>] [--include-deleted] [--include-archived] \
|
|
110
|
+
[--page-index <INDEX>] [--page-size <SIZE>]
|
|
111
|
+
pc ship product get <PRODUCT_ID> [--include-deleted] [--include-archived]
|
|
112
|
+
pc ship product create --data <JSON>
|
|
113
|
+
pc ship product update --data <JSON> <PRODUCT_ID>
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
### `ship product-channel` — 客户渠道(list / get)
|
|
117
|
+
|
|
118
|
+
```bash
|
|
119
|
+
pc ship product-channel list <PRODUCT_ID>
|
|
120
|
+
pc ship product-channel get <PRODUCT_ID> <CHANNEL_ID>
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
### `ship product-customer` — 客户(list / get / create / update)
|
|
124
|
+
|
|
125
|
+
```bash
|
|
126
|
+
pc ship product-customer list <PRODUCT_ID>
|
|
127
|
+
pc ship product-customer get <PRODUCT_ID> <CUSTOMER_ID>
|
|
128
|
+
pc ship product-customer create --data <JSON> <PRODUCT_ID>
|
|
129
|
+
pc ship product-customer update --data <JSON> <PRODUCT_ID> <CUSTOMER_ID>
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
### `ship product-member` — 产品成员(list / get / add / remove)
|
|
133
|
+
|
|
134
|
+
```bash
|
|
135
|
+
pc ship product-member list <PRODUCT_ID>
|
|
136
|
+
pc ship product-member get <PRODUCT_ID> <MEMBER_ID>
|
|
137
|
+
pc ship product-member add --data <JSON> <PRODUCT_ID>
|
|
138
|
+
pc ship product-member remove <PRODUCT_ID> <MEMBER_ID>
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
### `ship product-plan` — 产品计划(list / get)
|
|
142
|
+
|
|
143
|
+
```bash
|
|
144
|
+
pc ship product-plan list <PRODUCT_ID>
|
|
145
|
+
pc ship product-plan get <PRODUCT_ID> <PLAN_ID>
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
### `ship product-suite` — 产品集(list / get / create / delete)
|
|
149
|
+
|
|
150
|
+
```bash
|
|
151
|
+
pc ship product-suite list <PRODUCT_ID>
|
|
152
|
+
pc ship product-suite get <PRODUCT_ID> <SUITE_ID>
|
|
153
|
+
pc ship product-suite create --data <JSON> <PRODUCT_ID>
|
|
154
|
+
pc ship product-suite delete <PRODUCT_ID> <SUITE_ID>
|
|
155
|
+
```
|
|
156
|
+
|
|
157
|
+
### `ship product-tag` — 产品标签(list / get / create / delete)
|
|
158
|
+
|
|
159
|
+
```bash
|
|
160
|
+
pc ship product-tag list <PRODUCT_ID>
|
|
161
|
+
pc ship product-tag get <PRODUCT_ID> <TAG_ID>
|
|
162
|
+
pc ship product-tag create --data <JSON> <PRODUCT_ID>
|
|
163
|
+
pc ship product-tag delete <PRODUCT_ID> <TAG_ID>
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
### `ship product-ticket-type` — 产品工单类型(list / get)
|
|
167
|
+
|
|
168
|
+
```bash
|
|
169
|
+
pc ship product-ticket-type list <PRODUCT_ID>
|
|
170
|
+
pc ship product-ticket-type get <PRODUCT_ID> <TICKET_TYPE_ID>
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
### `ship product-user` — 产品用户(list / get / create / update / delete)
|
|
174
|
+
|
|
175
|
+
```bash
|
|
176
|
+
pc ship product-user list <PRODUCT_ID>
|
|
177
|
+
pc ship product-user get <PRODUCT_ID> <USER_ID>
|
|
178
|
+
pc ship product-user create --data <JSON> <PRODUCT_ID>
|
|
179
|
+
pc ship product-user update --data <JSON> <PRODUCT_ID> <USER_ID>
|
|
180
|
+
pc ship product-user delete <PRODUCT_ID> <USER_ID>
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
### `ship ticket` — 工单(list / get / create / update / search)
|
|
184
|
+
|
|
185
|
+
```bash
|
|
186
|
+
pc ship ticket list [--product-id <ID>] [--type-id <ID>] [--state-id <ID>] \
|
|
187
|
+
[--priority-id <ID>] [--keywords <KEYWORDS>] [--include-public-image-token <FIELDS>] \
|
|
188
|
+
[--page-index <INDEX>] [--page-size <SIZE>]
|
|
189
|
+
pc ship ticket get <TICKET_ID> [--include-public-image-token <FIELDS>] [--include-deleted]
|
|
190
|
+
pc ship ticket create --data <JSON>
|
|
191
|
+
pc ship ticket update --data <JSON> <TICKET_ID>
|
|
192
|
+
pc ship ticket search --data <JSON>
|
|
193
|
+
```
|
|
194
|
+
|
|
195
|
+
### `ship ticket-channel` — 工单渠道(list-for-product)
|
|
196
|
+
|
|
197
|
+
```bash
|
|
198
|
+
pc ship ticket-channel list-for-product <ID>
|
|
199
|
+
```
|
|
200
|
+
|
|
201
|
+
### `ship ticket-priority` — 工单优先级(list / list-for-product / get)
|
|
202
|
+
|
|
203
|
+
```bash
|
|
204
|
+
pc ship ticket-priority list [--page-index <INDEX>] [--page-size <SIZE>]
|
|
205
|
+
pc ship ticket-priority list-for-product <ID>
|
|
206
|
+
pc ship ticket-priority get <PRIORITY_ID>
|
|
207
|
+
```
|
|
208
|
+
|
|
209
|
+
### `ship ticket-property` — 工单属性定义(list / list-for-product / get / create / update)
|
|
210
|
+
|
|
211
|
+
```bash
|
|
212
|
+
pc ship ticket-property list [--page-index <INDEX>] [--page-size <SIZE>]
|
|
213
|
+
pc ship ticket-property list-for-product <ID>
|
|
214
|
+
pc ship ticket-property get <PROPERTY_ID>
|
|
215
|
+
pc ship ticket-property create --data <JSON>
|
|
216
|
+
pc ship ticket-property update --data <JSON> <PROPERTY_ID>
|
|
217
|
+
```
|
|
218
|
+
|
|
219
|
+
### `ship ticket-property-plan` — 工单属性方案(list / get / add-property / list-properties / get-property / remove-property)
|
|
220
|
+
|
|
221
|
+
```bash
|
|
222
|
+
pc ship ticket-property-plan list [--page-index <INDEX>] [--page-size <SIZE>]
|
|
223
|
+
pc ship ticket-property-plan get <PROPERTY_PLAN_ID>
|
|
224
|
+
pc ship ticket-property-plan add-property --data <JSON> <PROPERTY_PLAN_ID>
|
|
225
|
+
pc ship ticket-property-plan list-properties <PROPERTY_PLAN_ID>
|
|
226
|
+
pc ship ticket-property-plan get-property <PROPERTY_PLAN_ID> <PROPERTY_ID>
|
|
227
|
+
pc ship ticket-property-plan remove-property <PROPERTY_PLAN_ID> <PROPERTY_ID>
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
### `ship ticket-solution` — 工单解决方案(list / list-for-product / get)
|
|
231
|
+
|
|
232
|
+
```bash
|
|
233
|
+
pc ship ticket-solution list [--page-index <INDEX>] [--page-size <SIZE>]
|
|
234
|
+
pc ship ticket-solution list-for-product <ID>
|
|
235
|
+
pc ship ticket-solution get <TICKET_SOLUTION_ID>
|
|
236
|
+
```
|
|
237
|
+
|
|
238
|
+
### `ship ticket-state` — 工单状态(list / list-for-product / get / create / update)
|
|
239
|
+
|
|
240
|
+
```bash
|
|
241
|
+
pc ship ticket-state list [--page-index <INDEX>] [--page-size <SIZE>]
|
|
242
|
+
pc ship ticket-state list-for-product <ID>
|
|
243
|
+
pc ship ticket-state get <TICKET_STATE_ID>
|
|
244
|
+
pc ship ticket-state create --data <JSON>
|
|
245
|
+
pc ship ticket-state update --data <JSON> <TICKET_STATE_ID>
|
|
246
|
+
```
|
|
247
|
+
|
|
248
|
+
### `ship ticket-state-plan` — 工单状态方案与流转(list / get / add-state / list-states / get-state / remove-state / add-flow / list-flows / get-flow / remove-flow)
|
|
249
|
+
|
|
250
|
+
```bash
|
|
251
|
+
pc ship ticket-state-plan list [--page-index <INDEX>] [--page-size <SIZE>]
|
|
252
|
+
pc ship ticket-state-plan get <STATE_PLAN_ID>
|
|
253
|
+
pc ship ticket-state-plan add-state --data <JSON> <STATE_PLAN_ID>
|
|
254
|
+
pc ship ticket-state-plan list-states <STATE_PLAN_ID>
|
|
255
|
+
pc ship ticket-state-plan get-state <STATE_PLAN_ID> <STATE_ID>
|
|
256
|
+
pc ship ticket-state-plan remove-state <STATE_PLAN_ID> <STATE_ID>
|
|
257
|
+
pc ship ticket-state-plan add-flow --data <JSON> <STATE_PLAN_ID>
|
|
258
|
+
pc ship ticket-state-plan list-flows <STATE_PLAN_ID>
|
|
259
|
+
pc ship ticket-state-plan get-flow <STATE_PLAN_ID> <STATE_FLOW_ID>
|
|
260
|
+
pc ship ticket-state-plan remove-flow <STATE_PLAN_ID> <STATE_FLOW_ID>
|
|
261
|
+
```
|
|
262
|
+
|
|
263
|
+
### `ship ticket-tag` — 工单标签(list-for-product)
|
|
264
|
+
|
|
265
|
+
```bash
|
|
266
|
+
pc ship ticket-tag list-for-product <ID>
|
|
267
|
+
```
|
|
268
|
+
|
|
269
|
+
### `ship ticket-transition` — 工单流转(list / get)
|
|
270
|
+
|
|
271
|
+
```bash
|
|
272
|
+
pc ship ticket-transition list <TICKET_ID>
|
|
273
|
+
pc ship ticket-transition get <TICKET_ID> <TRANSITION_HISTORY_ID>
|
|
274
|
+
```
|
|
275
|
+
|
|
276
|
+
### `ship ticket-type` — 工单类型(list / list-for-product / get)
|
|
277
|
+
|
|
278
|
+
```bash
|
|
279
|
+
pc ship ticket-type list [--page-index <INDEX>] [--page-size <SIZE>]
|
|
280
|
+
pc ship ticket-type list-for-product <ID>
|
|
281
|
+
pc ship ticket-type get <TICKET_TYPE_ID>
|
|
282
|
+
```
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
# testhub 命令速查(测试库 / 用例 / 计划 / 执行)
|
|
2
|
+
|
|
3
|
+
testhub 是 PingCode 的**测试管理**模块。本文件是该模块的完整命令表,通用约定见 `reference.md`。
|
|
4
|
+
|
|
5
|
+
## 层级与 ID 关系
|
|
6
|
+
|
|
7
|
+
```
|
|
8
|
+
library(测试库)
|
|
9
|
+
├── library-member / library-suite(用例目录树)
|
|
10
|
+
├── testcase(测试用例)
|
|
11
|
+
│ └── testcase-state / testcase-type / testcase-important-level 按「测试库」维度配置
|
|
12
|
+
├── testplan(测试计划)
|
|
13
|
+
└── testrun(测试执行记录:某计划下某用例的一次执行)
|
|
14
|
+
└── testrun-status 按「测试库」维度配置
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
- 典型链路:`library list` → `library-suite list <LIBRARY_ID>` → `testcase list --library-id` →
|
|
18
|
+
`testplan create` → `testrun list --testplan-id` 看执行情况。
|
|
19
|
+
- **状态字典按库查**:`testcase-state list-for-library --library-id <LID>`、
|
|
20
|
+
`testrun-status list-for-library --library-id <LID>`。不同库的 ID 不能混用。
|
|
21
|
+
- `testcase list` 的 `--library-id` 是**可选**的:不传会跨库返回,容易误判「用例属于哪个库」,
|
|
22
|
+
拿不准时先确认库再查。
|
|
23
|
+
- `testrun list` 用 `--testplan-id` / `--testcase-id` / `--suite-id` / `--status-id` 过滤,
|
|
24
|
+
**没有** `--library-id`;要按库筛就先从计划入手。
|
|
25
|
+
- `testcase histories <ID>` / `testrun histories <ID>` / `testrun get-history <ID> <HISTORY_ID>`
|
|
26
|
+
是变更历史,只读。
|
|
27
|
+
- `testrun plan-batch --data <JSON> <LIBRARY_ID> <TESTPLAN_ID>` 用于批量把执行记录并入计划。
|
|
28
|
+
- 批量写(`bulk-create` / `bulk-update`)的请求体形态各接口不一致:**先用 1~2 条验证结构再放大**,
|
|
29
|
+
不要一次性把上百条推进去。
|
|
30
|
+
|
|
31
|
+
## 命令表
|
|
32
|
+
|
|
33
|
+
### `testhub library` — 测试库(list / get / create / update)
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
pc testhub library list [--scope-type <SCOPE>] [--scope-id <ID>] [--keywords <KEYWORDS>] \
|
|
37
|
+
[--member-type <TYPE>] [--member-id <ID>] [--created-between <RANGE>] \
|
|
38
|
+
[--updated-between <RANGE>] [--include-deleted] [--include-archived]
|
|
39
|
+
pc testhub library get <LIBRARY_ID> [--include-deleted] [--include-archived]
|
|
40
|
+
pc testhub library create --data <JSON>
|
|
41
|
+
pc testhub library update --data <JSON> <LIBRARY_ID>
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
### `testhub library-member` — 测试库成员(list / get / add / update / remove)
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
pc testhub library-member list <LIBRARY_ID>
|
|
48
|
+
pc testhub library-member get <LIBRARY_ID> <MEMBER_ID>
|
|
49
|
+
pc testhub library-member add --data <JSON> <LIBRARY_ID>
|
|
50
|
+
pc testhub library-member update --data <JSON> <LIBRARY_ID> <MEMBER_ID>
|
|
51
|
+
pc testhub library-member remove <LIBRARY_ID> <MEMBER_ID>
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### `testhub library-suite` — 用例目录(list / get / create / update / remove)
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
pc testhub library-suite list <LIBRARY_ID> [--parent-id <PARENT>]
|
|
58
|
+
pc testhub library-suite get <LIBRARY_ID> <SUITE_ID>
|
|
59
|
+
pc testhub library-suite create --data <JSON> <LIBRARY_ID>
|
|
60
|
+
pc testhub library-suite update --data <JSON> <LIBRARY_ID> <SUITE_ID>
|
|
61
|
+
pc testhub library-suite remove <LIBRARY_ID> <SUITE_ID>
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
### `testhub testcase` — 测试用例(list / get / create / update / delete / search / bulk-create / bulk-update / histories)
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
pc testhub testcase list [--library-id <ID>] [--maintenance-id <ID>] [--state-id <ID>] \
|
|
68
|
+
[--important-level-id <ID>] [--tag-id <ID>] [--keywords <KEYWORDS>] \
|
|
69
|
+
[--include-public-image-token <FIELDS>] [--include-deleted]
|
|
70
|
+
pc testhub testcase get <TESTCASE_ID> [--include-public-image-token <FIELDS>] \
|
|
71
|
+
[--include-deleted]
|
|
72
|
+
pc testhub testcase create --data <JSON>
|
|
73
|
+
pc testhub testcase update --data <JSON> <TESTCASE_ID>
|
|
74
|
+
pc testhub testcase delete <TESTCASE_ID>
|
|
75
|
+
pc testhub testcase search --data <JSON>
|
|
76
|
+
pc testhub testcase bulk-create --data <JSON>
|
|
77
|
+
pc testhub testcase bulk-update --data <JSON>
|
|
78
|
+
pc testhub testcase histories <TESTCASE_ID>
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
### `testhub testcase-important-level` — 重要程度(list / get)
|
|
82
|
+
|
|
83
|
+
```bash
|
|
84
|
+
pc testhub testcase-important-level list
|
|
85
|
+
pc testhub testcase-important-level get <IMPORTANT_LEVEL_ID>
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
### `testhub testcase-property` — 用例属性定义(list / list-for-library / get / create / update)
|
|
89
|
+
|
|
90
|
+
```bash
|
|
91
|
+
pc testhub testcase-property list
|
|
92
|
+
pc testhub testcase-property list-for-library --library-id <ID>
|
|
93
|
+
pc testhub testcase-property get <PROPERTY_ID>
|
|
94
|
+
pc testhub testcase-property create --data <JSON>
|
|
95
|
+
pc testhub testcase-property update --data <JSON> <PROPERTY_ID>
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
### `testhub testcase-property-plan` — 用例属性方案(list / get / list-properties / get-property / add-property / remove-property)
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
pc testhub testcase-property-plan list [--library-id <ID>]
|
|
102
|
+
pc testhub testcase-property-plan get <PROPERTY_PLAN_ID>
|
|
103
|
+
pc testhub testcase-property-plan list-properties <PROPERTY_PLAN_ID>
|
|
104
|
+
pc testhub testcase-property-plan get-property <PROPERTY_PLAN_ID> <PROPERTY_ID>
|
|
105
|
+
pc testhub testcase-property-plan add-property --data <JSON> <PROPERTY_PLAN_ID>
|
|
106
|
+
pc testhub testcase-property-plan remove-property <PROPERTY_PLAN_ID> <PROPERTY_ID>
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
### `testhub testcase-state` — 用例状态(list / list-for-library / get)
|
|
110
|
+
|
|
111
|
+
```bash
|
|
112
|
+
pc testhub testcase-state list
|
|
113
|
+
pc testhub testcase-state list-for-library --library-id <ID>
|
|
114
|
+
pc testhub testcase-state get <STATE_ID>
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
### `testhub testcase-type` — 用例类型(list / list-for-library / get)
|
|
118
|
+
|
|
119
|
+
```bash
|
|
120
|
+
pc testhub testcase-type list
|
|
121
|
+
pc testhub testcase-type list-for-library --library-id <ID>
|
|
122
|
+
pc testhub testcase-type get <TYPE_ID>
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
### `testhub testplan` — 测试计划(list / get / create / update)
|
|
126
|
+
|
|
127
|
+
```bash
|
|
128
|
+
pc testhub testplan list <LIBRARY_ID> [--name <NAME>] [--created-between <RANGE>] \
|
|
129
|
+
[--updated-between <RANGE>]
|
|
130
|
+
pc testhub testplan get <LIBRARY_ID> <TESTPLAN_ID> [--include-deleted]
|
|
131
|
+
pc testhub testplan create --data <JSON> <LIBRARY_ID>
|
|
132
|
+
pc testhub testplan update --data <JSON> <LIBRARY_ID> <TESTPLAN_ID>
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
### `testhub testplan-state` — 计划状态(list / get)
|
|
136
|
+
|
|
137
|
+
```bash
|
|
138
|
+
pc testhub testplan-state list
|
|
139
|
+
pc testhub testplan-state get <STATE_ID>
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
### `testhub testplan-type` — 计划类型(list / get)
|
|
143
|
+
|
|
144
|
+
```bash
|
|
145
|
+
pc testhub testplan-type list <LIBRARY_ID>
|
|
146
|
+
pc testhub testplan-type get <LIBRARY_ID> <TESTPLAN_TYPE_ID>
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
### `testhub testrun` — 测试执行(list / get / create / update / replace / search / bulk-create / bulk-update / histories / get-history / plan-batch)
|
|
150
|
+
|
|
151
|
+
```bash
|
|
152
|
+
pc testhub testrun list [--testplan-id <ID>] [--testcase-id <ID>] [--suite-id <ID>] \
|
|
153
|
+
[--status-id <ID>] [--keywords <KEYWORDS>]
|
|
154
|
+
pc testhub testrun get <TESTRUN_ID> [--include-deleted]
|
|
155
|
+
pc testhub testrun create --data <JSON>
|
|
156
|
+
pc testhub testrun update --data <JSON> <TESTRUN_ID>
|
|
157
|
+
pc testhub testrun replace --data <JSON> <TESTRUN_ID>
|
|
158
|
+
pc testhub testrun search --data <JSON>
|
|
159
|
+
pc testhub testrun bulk-create --data <JSON>
|
|
160
|
+
pc testhub testrun bulk-update --data <JSON>
|
|
161
|
+
pc testhub testrun histories <TESTRUN_ID>
|
|
162
|
+
pc testhub testrun get-history <TESTRUN_ID> <HISTORY_ID>
|
|
163
|
+
pc testhub testrun plan-batch --data <JSON> <LIBRARY_ID> <TESTPLAN_ID>
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
### `testhub testrun-status` — 执行状态(list / list-for-library / get)
|
|
167
|
+
|
|
168
|
+
```bash
|
|
169
|
+
pc testhub testrun-status list
|
|
170
|
+
pc testhub testrun-status list-for-library --library-id <ID>
|
|
171
|
+
pc testhub testrun-status get <STATUS_ID>
|
|
172
|
+
```
|