• 暂时停更一段时间!
  • 近期网站将陆续进行前端页面改造!
  • 招募网站编辑,联系站长!

从零到企业级SSM电商项目验收测试(五)收货地址管理模块测试

文章目录[隐藏]

1.添加地址

/shipping/add.do

http://localhost:8080/shipping/add.do?userId=1&receiverName=geely&receiverPhone=010&receiverMobile=18688888888&receiverProvince=四川省&receiverCity=成都市&receiverAddress=锦江区&receiverZip=100000

request
userId=1
receiverName=geely
receiverPhone=010
receiverMobile=18688888888
receiverProvince=北京
receiverCity=北京市
receiverAddress=中关村
receiverZip=100000

response

success

{
    "status": 0,
    "msg": "新建地址成功",
    "data": {
        "shippingId": 28
    }
}

fail

{
    "status": 1,
    "msg": "新建地址失败"
}

2.删除地址

/shipping/del.do

request

shippingId

response

success

{
    "status": 0,
    "msg": "删除地址成功"
}


fail

{
    "status": 1,
    "msg": "删除地址失败"
}

3.登录状态更新地址

/shipping/update.do

request
id=1
receiverName=geely
receiverPhone=010
receiverMobile=18688888888
receiverProvince=北京
receiverCity=北京市
receiverAddress=中关村
receiverZip=100000

http://localhost:8080/shipping/update.do?id=31&receiverName=geekerstar&receiverPhone=010&receiverMobile=18688888888&receiverProvince=四川省&receiverCity=成都市&receiverAddress=锦江区&receiverZip=100000

response

success

{
    "status": 0,
    "msg": "更新地址成功"
}

fail

{
    "status": 1,
    "msg": "更新地址失败"
}

4.选中查看具体的地址

/shipping/select.do

request

shippingId

response

success

{
    "status": 0,
    "data": {
        "id": 4,
        "userId": 13,
        "receiverName": "geely",
        "receiverPhone": "010",
        "receiverMobile": "18688888888",
        "receiverProvince": "北京",
        "receiverCity": "北京市",
        "receiverAddress": "中关村",
        "receiverZip": "100000",
        "createTime": 1485066385000,
        "updateTime": 1485066385000
    }
}


fail

{
    "status": 1,
    "msg": "请登录之后查询"
}

5.地址列表

/shipping/list.do

http://localhost:8080/shipping/list.do

request
pageNum(默认 1),pageSize(默认 10)

response

success

{
    "status": 0,
    "data": {
        "pageNum": 1,
        "pageSize": 10,
        "size": 2,
        "orderBy": null,
        "startRow": 1,
        "endRow": 2,
        "total": 2,
        "pages": 1,
        "list": [
            {
                "id": 4,
                "userId": 13,
                "receiverName": "geely",
                "receiverPhone": "010",
                "receiverMobile": "18688888888",
                "receiverProvince": "北京",
                "receiverCity": "北京市",
                "receiverAddress": "中关村",
                "receiverZip": "100000",
                "createTime": 1485066385000,
                "updateTime": 1485066385000
            },
            {
                "id": 5,
                "userId": 13,
                "receiverName": "AAA",
                "receiverPhone": "010",
                "receiverMobile": "18688888888",
                "receiverProvince": "北京",
                "receiverCity": "北京市",
                "receiverAddress": "中关村",
                "receiverZip": "100000",
                "createTime": 1485066392000,
                "updateTime": 1485075875000
            }
        ],
        "firstPage": 1,
        "prePage": 0,
        "nextPage": 0,
        "lastPage": 1,
        "isFirstPage": true,
        "isLastPage": true,
        "hasPreviousPage": false,
        "hasNextPage": false,
        "navigatePages": 8,
        "navigatepageNums": [
            1
        ]
    }
}


fail

{
    "status": 1,
    "msg": "请登录之后查询"
}

丨极客文库, 版权所有丨如未注明 , 均为原创丨
本网站采用知识共享署名-非商业性使用-相同方式共享 3.0 中国大陆许可协议进行授权
转载请注明原文链接:从零到企业级 SSM 电商项目验收测试(五)收货地址管理模块测试
喜欢 (0)
[247507792@qq.com]
分享 (0)

邀请您免费 注册账号 登录 即可参与讨论!