2023-12-22 14:59:06 +08:00
|
|
|
<?php
|
|
|
|
|
2024-01-03 18:02:57 +08:00
|
|
|
namespace Yansongda\Pay\Tests\Plugin\Alipay\V2\Member\FaceVerification;
|
2023-12-22 14:59:06 +08:00
|
|
|
|
2024-01-11 21:45:27 +08:00
|
|
|
use Yansongda\Artful\Direction\ResponseDirection;
|
2024-01-03 18:02:57 +08:00
|
|
|
use Yansongda\Pay\Plugin\Alipay\V2\Member\FaceVerification\AppQueryPlugin;
|
2024-01-11 21:45:27 +08:00
|
|
|
use Yansongda\Artful\Rocket;
|
2023-12-22 14:59:06 +08:00
|
|
|
use Yansongda\Pay\Tests\TestCase;
|
|
|
|
|
|
|
|
class AppQueryPluginTest extends TestCase
|
|
|
|
{
|
|
|
|
protected AppQueryPlugin $plugin;
|
|
|
|
|
|
|
|
protected function setUp(): void
|
|
|
|
{
|
|
|
|
parent::setUp();
|
|
|
|
|
|
|
|
$this->plugin = new AppQueryPlugin();
|
|
|
|
}
|
|
|
|
|
|
|
|
public function testNormal()
|
|
|
|
{
|
|
|
|
$rocket = (new Rocket())
|
|
|
|
->setParams([]);
|
|
|
|
|
|
|
|
$result = $this->plugin->assembly($rocket, function ($rocket) { return $rocket; });
|
|
|
|
|
|
|
|
self::assertNotEquals(ResponseDirection::class, $result->getDirection());
|
|
|
|
self::assertStringContainsString('datadigital.fincloud.generalsaas.face.verification.query', $result->getPayload()->toJson());
|
|
|
|
}
|
|
|
|
}
|