Pārlūkot izejas kodu

添加测试用例

ajun 5 gadi atpakaļ
vecāks
revīzija
01f8351f7a

+ 26 - 0
tests/Services/CacheShelfService/GetTasksTest.php

@@ -0,0 +1,26 @@
+<?php
+
+
+namespace Tests\Services\CacheShelfService;
+use App\Services\CacheShelfService;
+use Tests\TestCase;
+
+class GetTasksTest extends TestCase
+{
+    /** @var CacheShelfService $service */
+    protected $service;
+
+    protected function setup(): void
+    {
+        $this->service = app(CacheShelfService::class);
+
+        parent::setup(); // todo: change the autogenerated stub
+    }
+
+    protected function tearDown(): void
+    {
+        parent::tearDown(); // TODO: Change the autogenerated stub
+    }
+
+
+}

+ 26 - 0
tests/Services/CacheShelfService/LightOnTest.php

@@ -0,0 +1,26 @@
+<?php
+
+
+namespace Tests\Services\CacheShelfService;
+
+use App\Services\CacheShelfService;
+use Tests\TestCase;
+
+class LightOnTest extends testcase
+{
+    /** @var CacheShelfService $service */
+    protected $service;
+
+    protected function setup(): void
+    {
+        $this->service = app(CacheShelfService::class);
+
+        parent::setup(); // todo: change the autogenerated stub
+    }
+
+    protected function tearDown(): void
+    {
+        parent::tearDown(); // TODO: Change the autogenerated stub
+    }
+
+}

+ 26 - 0
tests/Services/CacheShelfService/PutBinToStoreTest.php

@@ -0,0 +1,26 @@
+<?php
+
+
+namespace Tests\Services\CacheShelfService;
+use App\Services\CacheShelfService;
+use Tests\TestCase;
+
+
+class PutBinToStoreTest extends TestCase
+{
+    /** @var CacheShelfService $service */
+    protected $service;
+
+    protected function setup(): void
+    {
+        $this->service = app(CacheShelfService::class);
+
+        parent::setup(); // todo: change the autogenerated stub
+    }
+
+    protected function tearDown(): void
+    {
+        parent::tearDown(); // TODO: Change the autogenerated stub
+    }
+
+}

+ 14 - 0
tests/webApi/cacheShelf.http

@@ -0,0 +1,14 @@
+###
+# 推送任务
+POST http://bswas/api/station/cacheShelf/pushTask
+Content-Type: application/json
+
+{}
+###
+
+###
+#获取任务
+GET http://bswas/api/station/cacheShelf/getTasks
+Content-Type: application/json
+
+###