From bc1b25124819a2091400e93cc009eb2a69a31aad Mon Sep 17 00:00:00 2001 From: Diederik de Groot Date: Tue, 7 Apr 2020 12:54:51 +0200 Subject: [PATCH] Small fixes/cleanup Signed-off-by: Diederik de Groot --- lib/Crypto/Certificate.php | 2 +- lib/Crypto/Crypto.php | 1 + lib/Crypto/Signer.php | 4 ++-- tests/resolverTest.php | 28 ++++++++++++++-------------- 4 files changed, 18 insertions(+), 17 deletions(-) diff --git a/lib/Crypto/Certificate.php b/lib/Crypto/Certificate.php index 53ca2ef..575847a 100644 --- a/lib/Crypto/Certificate.php +++ b/lib/Crypto/Certificate.php @@ -12,4 +12,4 @@ class Certificate { return ""; } } -?> \ No newline at end of file +?> diff --git a/lib/Crypto/Crypto.php b/lib/Crypto/Crypto.php index 1278192..b70b0b2 100644 --- a/lib/Crypto/Crypto.php +++ b/lib/Crypto/Crypto.php @@ -10,3 +10,4 @@ class Crypto { .hashAsBase64($hashAlg); } } +?> diff --git a/lib/Crypto/Signer.php b/lib/Crypto/Signer.php index 5b37564..05625f2 100644 --- a/lib/Crypto/Signer.php +++ b/lib/Crypto/Signer.php @@ -1,8 +1,8 @@ \ No newline at end of file +?> diff --git a/tests/resolverTest.php b/tests/resolverTest.php index 2b92f6c..5045b1a 100644 --- a/tests/resolverTest.php +++ b/tests/resolverTest.php @@ -47,20 +47,20 @@ final class ResolverTest extends TestCase $config = $this->getConfig(); $resolve = new Resolve($config); - foreach($this->test_cases as $test) { - try { - $result = $resolve->resolve($test['request']); - if (is_string($result)) { - $this->assertStringContainsString($result, $base_path . $test['expected']); - } else { - $this->assertEquals($result, $test['expected']); - } - } catch (Exception $e) { - print("'" . $test['request'] . "' => throws error as expected\n"); - print("Exception: " . $e->getMessage() . "\n"); - } - } - unset($resolve); + foreach($this->test_cases as $test) { + try { + $result = $resolve->resolve($test['request']); + if (is_string($result)) { + $this->assertStringContainsString($result, $base_path . $test['expected']); + } else { + $this->assertEquals($result, $test['expected']); + } + } catch (Exception $e) { + print("'" . $test['request'] . "' => throws error as expected\n"); + print("Exception: " . $e->getMessage() . "\n"); + } + } + unset($resolve); } }