Compare commits
No commits in common. "3c5020b80ba0d66e49d2e12708354e9af54ad801" and "d9cf1f12b4f8844d6e57c0f2d5d6b839fec54f2c" have entirely different histories.
3c5020b80b
...
d9cf1f12b4
@ -2,7 +2,7 @@
|
||||
"name": "maiyoule/mqttclient_author",
|
||||
"type": "library",
|
||||
"description": "MQTT管理模块操作库",
|
||||
"version": "1.1.1",
|
||||
"version": "1.1.0",
|
||||
"license": "MIT",
|
||||
"authors": [
|
||||
{
|
||||
|
@ -1,37 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace cn\com\maiyoule\mqttclient\biz;
|
||||
|
||||
use cn\com\maiyoule\mqttclient\IRequest;
|
||||
|
||||
class AppUpdateCallbackRequest extends IRequest
|
||||
{
|
||||
|
||||
public function path(): string
|
||||
{
|
||||
return 'app/callback/update';
|
||||
}
|
||||
|
||||
public function body(): array
|
||||
{
|
||||
return [
|
||||
'url' => $this->getUrl()
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
private string $url;
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getUrl(): string
|
||||
{
|
||||
return $this->url;
|
||||
}
|
||||
|
||||
public function setUrl(string $url): void
|
||||
{
|
||||
$this->url = $url;
|
||||
}
|
||||
}
|
@ -2,13 +2,11 @@
|
||||
|
||||
namespace cn\com\maiyoule\mqttclient\test;
|
||||
|
||||
use cn\com\maiyoule\mqttclient\biz\AppUpdateCallbackRequest;
|
||||
use cn\com\maiyoule\mqttclient\biz\AppUserCreateRequest;
|
||||
use cn\com\maiyoule\mqttclient\biz\AppUserDeleteRequest;
|
||||
use cn\com\maiyoule\mqttclient\biz\AppUserUpdateRequest;
|
||||
use cn\com\maiyoule\mqttclient\exception\ApiException;
|
||||
use cn\com\maiyoule\mqttclient\AuthorServerClient;
|
||||
use GuzzleHttp\Exception\GuzzleException;
|
||||
use PHPUnit\Framework\Assert;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
@ -82,16 +80,4 @@ class AppManagerTest extends TestCase
|
||||
}
|
||||
}
|
||||
|
||||
public function testUpdateAppUrl()
|
||||
{
|
||||
$request = new AppUpdateCallbackRequest();
|
||||
$request->setUrl('http://202.200.18.46:8000/api.php');
|
||||
try {
|
||||
$biz = $this->manager->exec($request);
|
||||
$this->assertTrue($biz->isSuccess(), $biz->getMessage());
|
||||
} catch (GuzzleException|ApiException $e) {
|
||||
$this->fail($e->getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user