Compare commits

...

6 Commits

Author SHA1 Message Date
tracer 9a59a2563d extends from BindApiControllerTest 2022-10-08 10:45:54 +02:00
tracer 620e762dfc extends from BindApiControllerTest 2022-10-08 10:45:39 +02:00
tracer 5efa996d1d initial commit 2022-10-08 10:45:09 +02:00
tracer 82018976cf added reports 2022-10-08 10:43:41 +02:00
tracer 26e2934e40 added more verbose version 2022-10-08 10:43:06 +02:00
tracer b554c751ae minor updates 2022-10-08 10:42:03 +02:00
7 changed files with 911 additions and 205 deletions

4
.gitignore vendored
View File

@ -6,3 +6,7 @@
/config.json.local
/bindAPI.log
/reports/
/bindAPI.test.log
/.phpunit.result.cache
/config.json.test

View File

@ -1,48 +1,53 @@
{
"name": "tracer/bindapi",
"decription": "fo",
"authors": [
{
"name": "Micha Espey",
"email": "tracer@24unix.net"
}
],
"type": "project",
"license": "proprietary",
"minimum-stability": "stable",
"prefer-stable": true,
"require": {
"php": ">=8.1",
"ext-curl": "*",
"ext-json": "*",
"ext-pdo": "*",
"arubacao/tld-checker": "^1.2",
"monolog/monolog": "^3.1",
"php-di/php-di": "^6.3",
"phplucidframe/console-table": "^1.2",
"zircote/swagger-php": "^4.2",
"ext-posix": "*",
"ext-openssl": "*"
},
"config": {
"optimize-autoloader": true,
"preferred-install": {
"*": "dist"
},
"sort-packages": true
"name": "tracer/bindapi",
"decription": "fo",
"authors": [
{
"name": "Micha Espey",
"email": "tracer@24unix.net"
}
],
"type": "project",
"license": "proprietary",
"minimum-stability": "stable",
"prefer-stable": true,
"require": {
"php": ">=8.1",
"ext-curl": "*",
"ext-json": "*",
"ext-mbstring": "*",
"ext-openssl": "*",
"ext-pdo": "*",
"ext-posix": "*",
"ext-sodium": "*",
"arubacao/tld-checker": "^1.2",
"monolog/monolog": "^3.1",
"netresearch/jsonmapper": "^4.0",
"php-di/php-di": "^6.3",
"phplucidframe/console-table": "^1.2",
"symfony/property-access": "^6.1",
"symfony/serializer": "^6.1",
"zircote/swagger-php": "^4.2"
},
"config": {
"optimize-autoloader": true,
"preferred-install": {
"*": "dist"
},
"autoload": {
"psr-4": {
"App\\": "src/"
}
},
"autoload-dev": {
"psr-4": {
"Src\\": "src/"
}
},
"require-dev": {
"escapestudios/symfony2-coding-standard": "3.x-dev",
"phpunit/phpunit": "^9.5"
}
"sort-packages": true
},
"autoload": {
"psr-4": {
"App\\": "src/"
}
},
"autoload-dev": {
"psr-4": {
"Src\\": "src/"
}
},
"require-dev": {
"escapestudios/symfony2-coding-standard": "3.x-dev",
"phpunit/phpunit": "^9.5"
}
}

948
composer.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -1,8 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit bootstrap="vendor/autoload.php">
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.5/phpunit.xsd"
bootstrap="vendor/autoload.php"
cacheResultFile=".phpunit.cache/test-results"
executionOrder="depends,defects"
forceCoversAnnotation="false"
beStrictAboutCoversAnnotation="true"
beStrictAboutOutputDuringTests="true"
beStrictAboutTodoAnnotatedTests="true"
convertDeprecationsToExceptions="true"
failOnRisky="true"
failOnWarning="true"
verbose="true">
<testsuites>
<testsuite name="bindAPI Test Suite">
<directory suffix=".php">./tests/</directory>
<testsuite name="default">
<directory>tests</directory>
</testsuite>
</testsuites>
</phpunit>
<coverage cacheDirectory=".phpunit.cache/code-coverage"
processUncoveredFiles="true">
<include>
<directory suffix=".php">src</directory>
</include>
</coverage>
</phpunit>

View File

@ -11,14 +11,13 @@ use PDOException;
* @covers \App\Controller\DatabaseConnection
* @covers \App\Controller\ConfigController
*/
class DatabaseConnectionTest extends BindApiTestController
class DatabaseConnectionTest extends BindApiControllerTest
{
private PDO $dbConnection;
public function testGetConnection()
{
$configController = new ConfigController(test: true);
$configController = new ConfigController(test: true);
$dbHost = $configController->getConfig(configKey: 'dbHost');
$dbPort = $configController->getConfig(configKey: 'dbPort');

View File

@ -7,22 +7,22 @@ use PHPUnit\Framework\TestCase;
/**
*
*/
class NameserverControllerTest extends TestCase
class NameserverControllerTest extends BindApiControllerTest
{
public function setUp(): void
{
//$this->fixture =
}
public function tearDown(): void
{
}
public function testUpdate()
{
self::assertEquals(expected: true, actual: true);
}
}

View File

@ -0,0 +1,23 @@
<?php
namespace Unit\Controller;
use PHPUnit\Framework\TestCase;
/**
*
*/
class RequestControllerTest extends BindApiControllerTest
{
public function setUp(): void
{
}
public function tearDown(): void
{
}
}