feat: 支持蝦皮批量创建 PDD 采集任务 (#185)
This commit is contained in:
@@ -234,6 +234,24 @@ func TestShopeePage_移除Excel入口且保留目录记录入口(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestShopeePage_批量创建Pdd采集任务入口(t *testing.T) {
|
||||
content, err := os.ReadFile("templates/shopee/list.html")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
page := string(content)
|
||||
for _, want := range []string{
|
||||
`action="/shopee/collect-batch"`, `data-modal-open="shopee-collect-modal"`,
|
||||
`data-collect-form="shopee-collect-form"`, `form="shopee-collect-form"`,
|
||||
`<label for="shopee-collect-client">执行客户端</label>`,
|
||||
`不指定(任意客户端可领取)`, `.AssignableClients`, `data-collect-submit`,
|
||||
} {
|
||||
if !strings.Contains(page, want) {
|
||||
t.Errorf("蝦皮批量采集入口缺少 %q", want)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func TestShopeeDetail_区分顺运宝观测与正式SKU(t *testing.T) {
|
||||
content, err := os.ReadFile("templates/shopee/detail_modal.html")
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user