Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
<?php declare(strict_types=1); namespace EasyWeChat\Tests\Pay; use EasyWeChat\Pay\Contr..
Decoded Output download
<?php
declare(strict_types=1);
namespace EasyWeChat\Tests\Pay;
use EasyWeChat\Pay\Contracts\Merchant;
use EasyWeChat\Pay\Server;
use EasyWeChat\Tests\TestCase;
use Nyholm\Psr7\ServerRequest;
class ServerTest extends TestCase
{
public function test_it_will_handle_validation_request()
{
$request = (new ServerRequest(
'POST',
'http://easywechat.com/',
[],
fopen(__DIR__.'/../fixtures/files/pay_demo.json', 'r')
));
$merchant = \Mockery::mock(Merchant::class);
$merchant->shouldReceive('getSecretKey')->andReturn('key');
$server = new Server($merchant, $request);
$response = $server->serve();
$this->assertSame('{"code":"SUCCESS","message":""}', \strval($response->getBody()));
}
}
?>
Did this file decode correctly?
Original Code
<?php
declare(strict_types=1);
namespace EasyWeChat\Tests\Pay;
use EasyWeChat\Pay\Contracts\Merchant;
use EasyWeChat\Pay\Server;
use EasyWeChat\Tests\TestCase;
use Nyholm\Psr7\ServerRequest;
class ServerTest extends TestCase
{
public function test_it_will_handle_validation_request()
{
$request = (new ServerRequest(
'POST',
'http://easywechat.com/',
[],
fopen(__DIR__.'/../fixtures/files/pay_demo.json', 'r')
));
$merchant = \Mockery::mock(Merchant::class);
$merchant->shouldReceive('getSecretKey')->andReturn('key');
$server = new Server($merchant, $request);
$response = $server->serve();
$this->assertSame('{"code":"SUCCESS","message":""}', \strval($response->getBody()));
}
}
Function Calls
None |
Stats
MD5 | 2b51a8394a0fda8ae8c99b9c07be697c |
Eval Count | 0 |
Decode Time | 95 ms |