|
@@ -3319,18 +3319,25 @@ class TestRefill extends TestCase
|
|
// $resp = $provider->notify($params);
|
|
// $resp = $provider->notify($params);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ public function testGetXMLEncoding()
|
|
|
|
+ {
|
|
|
|
+ $header = '<?xml version="1.0" encoding="GB2312"?>';
|
|
|
|
+/* $ret = preg_match("/<?xml\s+[\s\S]*?>/", $header, $res);*/
|
|
|
|
+ $ret = preg_match("/<?xml\s+[\s\S]*encoding=[\"']([^\"']*)[\"'][\s\S]*?>/", $header, $res);
|
|
|
|
+ }
|
|
|
|
+
|
|
public function testfeihan()
|
|
public function testfeihan()
|
|
{
|
|
{
|
|
-// $provider = $this->getProvider('feihan', 'RefillOil');
|
|
|
|
-// $resp = $provider->balance();
|
|
|
|
-// $resp = $provider->add(9030230005180327, 1, 200, ['order_sn' => $this->make_sn()]);
|
|
|
|
-// $resp = $provider->query(['order_sn' => '18141682668825332400']);
|
|
|
|
|
|
+ $provider = $this->getProvider('feihan', 'RefillOil');
|
|
|
|
+ $resp = $provider->balance();
|
|
|
|
+ $resp = $provider->add(9030230005180327, 1, 200, ['order_sn' => $this->make_sn()]);
|
|
|
|
+ $resp = $provider->query(['order_sn' => '18141682668825332400']);
|
|
|
|
|
|
- $body = '{"err_msg":"","ordersuccesstime":"20230428161615","sporder_id":"18141682668825332400","ret_code":"1"}';
|
|
|
|
- $params = json_decode($body, true);
|
|
|
|
- $provider = $this->getProvider('feihan', 'RefillCallBack');
|
|
|
|
- $ret = $provider->verify($params);
|
|
|
|
- $resp = $provider->notify($params);
|
|
|
|
|
|
+// $body = '{"err_msg":"","ordersuccesstime":"20230428161615","sporder_id":"18141682668825332400","ret_code":"1"}';
|
|
|
|
+// $params = json_decode($body, true);
|
|
|
|
+// $provider = $this->getProvider('feihan', 'RefillCallBack');
|
|
|
|
+// $ret = $provider->verify($params);
|
|
|
|
+// $resp = $provider->notify($params);
|
|
}
|
|
}
|
|
|
|
|
|
public function testAmingjd()
|
|
public function testAmingjd()
|