REDROOM
PHP 7.4.33
Path:
Logout
Edit File
Size: 1.29 KB
Close
/home/godevadmin/www/admin/braintree/tests/integration/IndexPageTest.php
Text
Base64
<?php require_once("tests/TestHelper.php"); class IndexPageTest extends PHPUnit_Framework_TestCase { function test_returnsHttpSuccess() { $curl = curl_init(); curl_setopt($curl, CURLOPT_URL, "localhost:3000"); curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); curl_exec($curl); $httpStatus = curl_getinfo($curl, CURLINFO_HTTP_CODE); curl_close($curl); $this->assertEquals($httpStatus, 200); } function test_clientTokenOnPage() { $curl = curl_init(); curl_setopt($curl, CURLOPT_URL, "localhost:3000"); curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); $output = curl_exec($curl); curl_close($curl); $this->assertRegExp('/var client_token = ".*";/', $output); } function test_checkoutFormOnPage() { $curl = curl_init(); curl_setopt($curl, CURLOPT_URL, "localhost:3000"); curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); $output = curl_exec($curl); curl_close($curl); $this->assertRegExp('/<form method="post" id="payment-form"/', $output); $this->assertRegExp('/<div id="bt-dropin"/', $output); $this->assertRegExp('/<input id="amount" name="amount" type="tel"/', $output); } }
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 0 × Files: 3
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
CheckoutPageTest.php
5.79 KB
lrwxrwxr-x
2023-11-07 19:59:46
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
IndexPageTest.php
1.29 KB
lrwxrwxr-x
2023-11-07 19:59:46
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
TransactionPageTest.php
1.38 KB
lrwxrwxr-x
2023-11-07 19:59:46
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).