- 京东COOKIE增加:lsp-store1.jddj.com
This commit is contained in:
@@ -6,12 +6,12 @@ import (
|
||||
)
|
||||
|
||||
func TestCreatePromotionSingle(t *testing.T) {
|
||||
infoId, err := api.CreatePromotionInfosSingle("测试1", time.Now(), time.Now().Add(24*time.Hour), "", "")
|
||||
infoId, err := api.CreatePromotionInfosSingle("测试1", time.Now(), time.Now().Add(24*time.Hour), "", "", "")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
t.Log(infoId)
|
||||
err = api.CreatePromotionRulesSingle(infoId, "", 1, 1, 1, 1)
|
||||
err = api.CreatePromotionRulesSingle(infoId, "", 1, 1, 1, 1, "")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
@@ -22,24 +22,24 @@ func TestCreatePromotionSingle(t *testing.T) {
|
||||
PromotionPrice: 500,
|
||||
LimitSkuCount: 2,
|
||||
},
|
||||
})
|
||||
}, "")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
t.Log(skuInfos)
|
||||
err = api.ConfirmPromotionSingle(infoId, "")
|
||||
err = api.ConfirmPromotionSingle(infoId, "", "")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
}
|
||||
|
||||
func TestCreatePromotionLimitTime(t *testing.T) {
|
||||
infoId, err := api.CreatePromotionInfosLimitTime("测试1", time.Now(), time.Now().Add(24*time.Hour), "", "")
|
||||
infoId, err := api.CreatePromotionInfosLimitTime("测试1", time.Now(), time.Now().Add(24*time.Hour), "", "", "")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
t.Log(infoId)
|
||||
err = api.CreatePromotionRulesLimitTime(infoId, "", 1, 1, 5, 1)
|
||||
err = api.CreatePromotionRulesLimitTime(infoId, "", 1, 1, 5, 1, "")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
@@ -50,12 +50,12 @@ func TestCreatePromotionLimitTime(t *testing.T) {
|
||||
PromotionPrice: 300,
|
||||
LimitSkuCount: 2,
|
||||
},
|
||||
})
|
||||
}, "")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
t.Log(skuInfos)
|
||||
err = api.ConfirmPromotionLimitTime(infoId, "")
|
||||
err = api.ConfirmPromotionLimitTime(infoId, "", "")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user