Implemented async callbacks to PHP regardless of thread model, Sigv4 signing (#24)

* Updated to get latest aws-crt-ffi

* Added implementation for signing_result

* Added main thread queue and callback queueing to signing process

* Updated to get support for date on signing_config_aws

* added date support to SigningConfigAWS, fixed up reference issues on http message signing

* Broke C code into separate files, moved common stuff to php_aws_crt.h

* Use a unity build to make PHP do the right thing with our lib

* Updated aws-crt-ffi to v0.1.3 to get sigv4 changes

* Added CRT::isAvailable for safe runtime detection of CRT

* Fixed up test resource safety, added tests to prove it

* Added CI jobs for every version of PHP on linux (#26)
This commit is contained in:
Justin Boswell
2021-06-08 00:34:42 +00:00
committed by GitHub
parent a99fdeb9d3
commit 7d47316a7d
26 changed files with 3316 additions and 2396 deletions
+14
View File
@@ -6,10 +6,24 @@
use AWS\CRT\CRT as CRT;
abstract class CrtTestCase extends PHPUnit_Framework_TestCase {
private static $crt = null;
public static function setUpBeforeClass() {
self::$crt = new CRT();
}
public static function tearDownAfterClass() {
self::$crt = null;
}
// Ensure that after every test there are no errors in the CRT itself
protected function assertPostConditions() {
if (CRT::last_error()) {
$this->fail("Test left an error on the stack: " . CRT::error_name(CRT::last_error()));
}
}
// shim expectException -> setExpectedException for PHPUnit 4.8.x
public function expectException($exceptionName) {
$this->setExpectedException($exceptionName);
}
}