OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
cream
/
reader
/
aws-ses
/
vendor
/
aws
/
aws-sdk-php
/
tests
/
S3
/
UseArnRegion
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
05/19/2025 10:07:15 AM
rwxr-xr-x
📄
ConfigurationProviderTest.php
12.56 KB
05/19/2025 10:07:15 AM
rw-r--r--
📄
ConfigurationTest.php
1.36 KB
05/19/2025 10:07:15 AM
rw-r--r--
Editing: ConfigurationTest.php
Close
<?php namespace Aws\Test\S3\UseArnRegion; use Aws\S3\UseArnRegion\Configuration; use Yoast\PHPUnitPolyfills\TestCases\TestCase; /** * @covers \Aws\S3\UseArnRegion\Configuration */ class ConfigurationTest extends TestCase { /** * @dataProvider correctValueCases * * @param $param * @param $expected */ public function testGetsCorrectValues($param, $expected) { $config = new Configuration($param); $this->assertEquals($expected, $config->isUseArnRegion()); } public function correctValueCases() { return [ [true, true], [false, false], ['1', true], ['0', false], ['true', true], ['false', false], [1, true], [0, false], ]; } public function testToArray() { $config = new Configuration(true); $expected = [ 'use_arn_region' => true, ]; $this->assertEquals($expected, $config->toArray()); } public function testThrowsOnInvalidEndpointsType() { $this->expectExceptionMessage("'use_arn_region' config option must be a boolean value."); $this->expectException(\Aws\S3\UseArnRegion\Exception\ConfigurationException::class); new Configuration('not a boolean'); } }