- up.
This commit is contained in:
@@ -57,13 +57,21 @@ func TestSkuList(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestSkuCreate(t *testing.T) {
|
||||
result, err := api.SkuCreate(testShopID, map[string]interface{}{
|
||||
"name": "测试商品",
|
||||
"status": SkuStatusOnline,
|
||||
"left_num": MaxLeftNum,
|
||||
"sale_price": 100,
|
||||
"market_price": 100,
|
||||
"custom_sku_id": 1,
|
||||
result, err := api.SkuCreate(testShopID, 114, map[string]interface{}{
|
||||
"name": "测试商品",
|
||||
"status": SkuStatusOnline,
|
||||
"left_num": MaxLeftNum,
|
||||
"sale_price": 100,
|
||||
"market_price": 100,
|
||||
"cat1_id": 151301831158987,
|
||||
"cat2_id": 15347484581335,
|
||||
"cat3_id": 15347484581339,
|
||||
"photos": []map[string]interface{}{
|
||||
map[string]interface{}{
|
||||
"is_master": true,
|
||||
"url": "http://image.jx.scaqda.com/8536c76779333f53517006f88ea7174c.jpg?imageView2/1/w/80/h/80",
|
||||
},
|
||||
},
|
||||
})
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
|
||||
Reference in New Issue
Block a user