znt/test/api/products/update.php

18 lines
386 B
PHP
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#!/usr/bin/env php
<?php
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
/**
title=测试修改产品信息;
cid=1
pid=1
调用成功返回200 >> 200
*/
global $token;
$header = array('Token' => $token->token);
$pass = $rest->put('/products/1', array('name' => '测试正常产品1'), $header);
r($pass->status_code) && p() && e('200'); //调用成功返回200