mirror of
https://github.com/awslabs/aws-crt-php.git
synced 2026-08-17 17:47:12 +00:00
* 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)
22 lines
543 B
PHP
22 lines
543 B
PHP
<?php
|
|
/**
|
|
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
* SPDX-License-Identifier: Apache-2.0.
|
|
*/
|
|
use AWS\CRT\CRT;
|
|
|
|
final class ErrorTest extends PHPUnit_Framework_TestCase {
|
|
|
|
public function testNoInitialError() {
|
|
$this->assertEquals(0, CRT::last_error());
|
|
}
|
|
|
|
public function testCanResolveErrorName() {
|
|
$this->assertEquals("AWS_ERROR_SUCCESS", CRT::error_name(0));
|
|
}
|
|
|
|
public function testCanResolveErrorStr() {
|
|
$this->assertEquals("Success.", CRT::error_str(0));
|
|
}
|
|
}
|