WechatCheckControllerTest.php 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. namespace Tests\Video\Http\Controllers;
  3. use Modules\Video\Http\Controllers\WechatCheckController;
  4. use PHPUnit\Framework\TestCase;
  5. use Tests\UsedTestCase;
  6. class WechatCheckControllerTest extends UsedTestCase
  7. {
  8. public function testAdd()
  9. {
  10. $res = $this->withHeaders([
  11. 'Authorization' => 'Bearer '. $this->token,
  12. ])->json('post','http://localhost/api/videoStock/wechatCheck/add', [
  13. 'video_id' => 12,
  14. 'producer' => 'zzz',
  15. 'playwright' => 'xxxx',
  16. 'production_license_img' => 'https://minifile-cdn.zvyhjkx.com/uploads/images/20230531/9NUcrj2Dfz1685513143.png',
  17. 'authorized_img' => 'https://minifile-cdn.zvyhjkx.com/uploads/images/20230531/9NUcrj2Dfz1685513143.png'
  18. ]);
  19. $res->dump();
  20. }
  21. public function testList()
  22. {
  23. $res = $this->withHeaders([
  24. 'Authorization' => 'Bearer '. $this->token,
  25. ])->json('get','http://localhost/api/videoStock/wechatCheck/list', [
  26. // 'video_id' => 12,
  27. // 'producer' => 'zzz',
  28. // 'playwright' => 'xxxx',
  29. 'status' => '5'
  30. ]);
  31. $this->dumpJson($res);
  32. }
  33. }