diff --git a/Tethys.code-workspace b/Tethys.code-workspace index 779fe6a..9930a34 100644 --- a/Tethys.code-workspace +++ b/Tethys.code-workspace @@ -7,6 +7,12 @@ "settings": { // "phpfmt.php_bin": "\"C:\\ProgramData\\scoop\\apps\\php-nts\\current\\php.exe\"", "phpfmt.php_bin": "php", - "phpfmt.psr2": true + "phpfmt.psr2": true, + "phpcs.standard": "PSR2", + "phpcs.executablePath": "C:\\Users\\arno\\scoop\\apps\\composer\\current\\home\\vendor\\bin\\phpcs", + "phpsab.standard": "PSR2", + "phpsab.executablePathCBF": "C:\\Users\\arno\\scoop\\apps\\composer\\current\\home\\vendor\\bin\\phpcbf.bat", + "phpsab.executablePathCS":"C:\\Users\\arno\\scoop\\apps\\composer\\current\\home\\vendor\\bin\\phpcs.bat", + "phpsab.snifferEnable": true } } \ No newline at end of file diff --git a/app/Http/Controllers/DoiController.php b/app/Http/Controllers/DoiController.php new file mode 100644 index 0000000..7f0dcdb --- /dev/null +++ b/app/Http/Controllers/DoiController.php @@ -0,0 +1,203 @@ +doiClient = $DoiClient; + + $this->xml = new \DomDocument(); + $this->proc = new \XSLTProcessor(); + } + + /** + * Display a listing of the resource. + * + * @return \Illuminate\Http\Response + */ + public function index() + { + // + } + + /** + * Show the form for creating a new resource. + * + * @return \Illuminate\Http\Response + */ + public function create(Request $request) + { + // + } + + /** + * Store a newly created resource in storage. + * + * @param \Illuminate\Http\Request $request + * @return \Illuminate\Http\Response + */ + public function store(Request $request) + { + $dataId = $request->input('publish_id'); + + // Setup stylesheet + $this->loadStyleSheet(public_path() .'\prefixes\doi_datacite.xslt'); + + // set timestamp + $date = new \DateTime(); + $unixTimestamp = $date->getTimestamp(); + $this->proc->setParameter('', 'unixTimestamp', $unixTimestamp); + + $prefix = config('tethys.datacite_prefix'); + $this->proc->setParameter('', 'prefix', $prefix); + + $repIdentifier = "tethys"; + $this->proc->setParameter('', 'repIdentifier', $repIdentifier); + + $this->xml->appendChild($this->xml->createElement('Datasets')); + $dataset = Dataset::where('publish_id', '=', $dataId)->firstOrFail(); + if (is_null($dataset)) { + throw new OaiModelException('Dataset is not available for registering DOI!', OaiModelError::NORECORDSMATCH); + } + $dataset->fetchValues(); + $xmlModel = new \App\Library\Xml\XmlModel(); + $xmlModel->setModel($dataset); + $xmlModel->excludeEmptyFields(); + $cache = ($dataset->xmlCache) ? $dataset->xmlCache : new \App\Models\XmlCache(); + $xmlModel->setXmlCache($cache); + $domNode = $xmlModel->getDomDocument()->getElementsByTagName('Rdr_Dataset')->item(0); + $node = $this->xml->importNode($domNode, true); + $this->addSpecInformation($node, 'data-type:' . $dataset->type); + + $this->xml->documentElement->appendChild($node); + $xmlMeta = $this->proc->transformToXML($this->xml); + Log::alert($xmlMeta); + //create doiValue and correspunfing landingpage of tehtys + $doiValue = $prefix . '/tethys.' . $dataset->publish_id; + $appUrl = config('app.url'); + $landingPageUrl = $appUrl . "/dataset/" . $dataset->publish_id; + $response = $this->doiClient->registerDoi($doiValue, $xmlMeta, $landingPageUrl); + if ($response->getStatusCode() == 201) { + $doi = new DatasetIdentifier(); + $doi['value'] = $doiValue; + $doi['dataset_id'] = $dataset->id; + $doi['type'] = "doi"; + $doi['status'] = "registered"; + $doi['registration_ts'] = now(); + // $doi->save(); + } + } + + /** + * Display the specified resource. + * + * @param \App\Models\DatasetIdentifier $doi + * @return \Illuminate\Http\Response + */ + public function show(DatasetIdentifier $doi) + { + // + } + + /** + * Show the form for editing the specified resource. + * + * @param \App\Models\DatasetIdentifier $doi + * @return \Illuminate\Http\Response + */ + public function edit(DatasetIdentifier $doi) + { + // + } + + /** + * Update the specified resource in storage. + * + * @param \Illuminate\Http\Request $request + * @param \App\Models\DatasetIdentifier $doi + * @return \Illuminate\Http\Response + */ + public function update(Request $request, DatasetIdentifier $doi) + { + // + } + + /** + * Remove the specified resource from storage. + * + * @param \App\Models\DatasetIdentifier $doi + * @return \Illuminate\Http\Response + */ + public function destroy(DatasetIdentifier $doi) + { + // + } + + + + + /** + * Load an xslt stylesheet. + * + * @return void + */ + private function loadStyleSheet($stylesheet) + { + $this->xslt = new \DomDocument; + $this->xslt->load($stylesheet); + $this->proc->importStyleSheet($this->xslt); + if (isset($_SERVER['HTTP_HOST'])) { + $this->proc->setParameter('', 'host', $_SERVER['HTTP_HOST']); + } + //$this->proc->setParameter('', 'server', $this->getRequest()->getBaseUrl()); + } + + private function addSpecInformation(\DOMNode $document, $information) + { + $setSpecAttribute = $this->xml->createAttribute('Value'); + $setSpecAttributeValue = $this->xml->createTextNode($information); + $setSpecAttribute->appendChild($setSpecAttributeValue); + + $setSpecElement = $this->xml->createElement('SetSpec'); + //$setSpecElement =new \DOMElement("SetSpec"); + $setSpecElement->appendChild($setSpecAttribute); + $document->appendChild($setSpecElement); + } +} diff --git a/app/Interfaces/DoiInterface.php b/app/Interfaces/DoiInterface.php new file mode 100644 index 0000000..151bb62 --- /dev/null +++ b/app/Interfaces/DoiInterface.php @@ -0,0 +1,16 @@ +belongsTo(Dataset::class, 'document_id', 'id'); + } +} diff --git a/app/Providers/DoiServiceProvider.php b/app/Providers/DoiServiceProvider.php new file mode 100644 index 0000000..94de187 --- /dev/null +++ b/app/Providers/DoiServiceProvider.php @@ -0,0 +1,44 @@ +app->singleton('App\Interfaces\DoiInterface', function ($app) { + return new DoiService(); + }); + } + + public function provides() + { + return [DoiService::class]; + } +} diff --git a/app/Tethys/Utils/DoiClient.php b/app/Tethys/Utils/DoiClient.php new file mode 100644 index 0000000..ce300ea --- /dev/null +++ b/app/Tethys/Utils/DoiClient.php @@ -0,0 +1,212 @@ +username = config('tethys.datacite_test_username'); + $this->password = config('tethys.datacite_test_password'); + $this->serviceUrl = config('tethys.test_datacite_service_url'); + $this->prefix = config('tethys.datacite_prefix'); + } elseif ($datacite_environment == "production") { + $this->username = config('tethys.datacite_username'); + $this->password = config('tethys.datacite_password'); + $this->serviceUrl = config('tethys.datacite_service_url'); + $this->prefix = config('tethys.datacite_prefix'); + } + if (is_null($this->username) || is_null($this->password) || is_null($this->serviceUrl)) { + $message = 'missing configuration settings to properly initialize DOI client'; + Log::error($message); + throw new DoiClientException($message); + } + } + + /** + * Creates a DOI or ARK with the given identifier + * + * @param string $identifier The desired DOI identifier e.g. '10.5072/tethys.999', + * @param $xmlMeta + * @param $landingPageUrl e.g. https://www.tethys.at/dataset/1 + * + * @return GuzzleHttp\Psr7\Response The http response in the form of a Guzzle response + */ + public function registerDoi($doiValue, $xmlMeta, $landingPageUrl) + { + + // Schritt 1: Metadaten als XML registrieren + $response = null; + $url = $this->serviceUrl . '/metadata/' . $doiValue; + try { + $client = new Client([ + 'auth' => [$this->username, $this->password], + // 'base_uri' => $url, + 'verify' => false, + 'headers' => [ + 'Content-Type' => 'application/xml;charset=UTF-8', + ], + // 'body' => $xmlMeta, + ]); + // Provide the body as a string. + $response = $client->request('PUT', $url, [ + 'body' => $xmlMeta, + ]); + } catch (\Exception $e) { + $message = 'request to ' . $url . ' failed with ' . $e->getMessage(); + // $this->log($message, 'err'); + throw new DoiClientException($message); + } + // Response Codes + // 201 Created: operation successful + // 400 Bad Request: invalid XML, wrong prefix + // 401 Unauthorised: no login + // 403 Forbidden: login problem, quota exceeded + // 415 Wrong Content Type : Not including content type in the header. + // 422 Unprocessable Entity : invalid XML + if ($response->getStatusCode() != 201) { + $message = 'unexpected DataCite MDS response code ' . $response->getStatusCode(); + // $this->log($message, 'err'); + throw new DoiClientException($message); + } + + // Schritt 2: Register the DOI name + // DOI und URL der Frontdoor des zugehörigen Dokuments übergeben + $url = $this->serviceUrl . '/doi/' . $doiValue; + try { + $client = new Client( + [ + 'auth' => [$this->username, $this->password], + 'verify' => false, + 'headers' => [ + 'Content-Type' => 'text/plain;charset=UTF-8', + ], + ] + ); + $data = "doi=$doiValue\nurl=" . $landingPageUrl; + // $client->setRawData($data, 'text/plain;charset=UTF-8'); + $response = $client->request('PUT', $url, [ + 'body' => $data, + 'headers' => [ + 'Content-Type' => 'text/plain;charset=UTF-8', + ], + ]); + } catch (\Exception $e) { + $message = 'request to ' . $url . ' failed with ' . $e->getMessage(); + // $this->log($message, 'err'); + throw new DoiClientException($message); + } + // Response Codes + // 201 Created: operation successful + // 400 Bad Request: request body must be exactly two lines: DOI and URL; wrong domain, wrong prefix; + // 401 Unauthorised: no login + // 403 Forbidden: login problem, quota exceeded + // 412 Precondition failed: metadata must be uploaded first. + + // $this->log('DataCite response status code (expected 201): ' . $response->getStatus()); + // $this->log('DataCite response body: ' . $response->getBody()); + + if ($response->getStatusCode() != 201) { + $message = 'unexpected DataCite MDS response code ' . $response->getStatusCode(); + // $this->log($message, 'err'); + throw new DoiClientException($message); + } + return $response; + } + + /* Response Status Codes + * 200 OK: operation successful + * 204 No Content : DOI is known to DataCite Metadata Store (MDS), but is not minted (or not resolvable e.g. due + * to handle's latency) + * 401 Unauthorized: no login + * 403 Login problem or dataset belongs to another party + * 404 Not Found: DOI does not exist in our database (e.g. registration pending) + * + * @param $doiValue + * @param $landingPageURL + * + * @return bool Methode liefert true, wenn die DOI erfolgreich registiert wurde und die Prüfung positiv ausfällt. + * + * @throws ClientException + * + */ + public function checkDoi($doiValue, $landingPageURL): bool + { + $response = null; + $url = $this->serviceUrl . '/doi/' . $doiValue; + try { + $client = new Client([ + 'base_uri' => $this->serviceUrl . '/doi/' . $doiValue, + 'auth' => [$this->username, $this->password], + 'verify' => false, + ]); + $response = $client->request('GET'); + } catch (\Exception $e) { + $message = 'request to ' . $url . ' failed with ' . $e->getMessage(); + Log::error($message); + // throw new \Exception($message); + return false; + } + + $statusCode = $response->getStatusCode(); + // in $body steht die URL zur Frontdoor, die mit der DOI verknüpft wurde + $body = $response->getBody(); + + // $this->log('DataCite response status code (expected 200): ' . $statusCode); + // $this->log('DataCite response body (expected ' . $landingPageURL . '): ' . $body); + + return ($statusCode == 200 && $landingPageURL == $body); + } + + public function getMetadataForDoi($identifier) + { + // + } + + public function updateMetadataForDoi($identifier, $new_meta) + { + // + } + + /** + * Markiert den Datensatz zur übergebenen DOI als inaktiv. + * + * @param $doiValue + * + * @throws ClientException + */ + public function deleteMetadataForDoi($doiValue) + { + $response = null; + $url = $this->serviceUrl . '/metadata/' . $doiValue; + try { + $client = new Client([ + 'base_uri' => $url, + 'auth' => [$this->username, $this->password], + 'verify' => false, + ]); + $response = $client->request('DELETE'); + } catch (\Exception $e) { + $message = 'request to ' . $url . ' failed with ' . $e->getMessage(); + Log::error($message, 'err'); + throw new DoiClientException($message); + } + + // $this->log('DataCite response status code (expected 200): ' . $response->getStatus()); + + if ($response->getStatusCode() != 200) { + $message = 'unexpected DataCite MDS response code ' . $response->getStatusCode(); + Log::error($message, 'err'); + throw new DoiClientException($message); + } + } +} diff --git a/app/Tethys/Utils/DoiClientException.php b/app/Tethys/Utils/DoiClientException.php new file mode 100644 index 0000000..551b118 --- /dev/null +++ b/app/Tethys/Utils/DoiClientException.php @@ -0,0 +1,7 @@ +=5.5" + }, + "require-dev": { + "symfony/phpunit-bridge": "^4.4 || ^5.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.4-dev" + } + }, + "autoload": { + "psr-4": { + "GuzzleHttp\\Promise\\": "src/" + }, + "files": [ + "src/functions_include.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + } + ], + "description": "Guzzle promises library", + "keywords": [ + "promise" + ], + "support": { + "issues": "https://github.com/guzzle/promises/issues", + "source": "https://github.com/guzzle/promises/tree/1.4.0" + }, + "time": "2020-09-30T07:37:28+00:00" + }, + { + "name": "guzzlehttp/psr7", + "version": "1.7.0", + "source": { + "type": "git", + "url": "https://github.com/guzzle/psr7.git", + "reference": "53330f47520498c0ae1f61f7e2c90f55690c06a3" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/53330f47520498c0ae1f61f7e2c90f55690c06a3", + "reference": "53330f47520498c0ae1f61f7e2c90f55690c06a3", + "shasum": "" + }, + "require": { + "php": ">=5.4.0", + "psr/http-message": "~1.0", + "ralouphie/getallheaders": "^2.0.5 || ^3.0.0" + }, + "provide": { + "psr/http-message-implementation": "1.0" + }, + "require-dev": { + "ext-zlib": "*", + "phpunit/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5.8 || ^9.3.10" + }, + "suggest": { + "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.7-dev" + } + }, + "autoload": { + "psr-4": { + "GuzzleHttp\\Psr7\\": "src/" + }, + "files": [ + "src/functions_include.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + }, + { + "name": "Tobias Schultze", + "homepage": "https://github.com/Tobion" + } + ], + "description": "PSR-7 message implementation that also provides common utility methods", + "keywords": [ + "http", + "message", + "psr-7", + "request", + "response", + "stream", + "uri", + "url" + ], + "support": { + "issues": "https://github.com/guzzle/psr7/issues", + "source": "https://github.com/guzzle/psr7/tree/1.7.0" + }, + "time": "2020-09-30T07:37:11+00:00" + }, { "name": "halpdesk/zizaco-entrust-laravel-6.0", "version": "1.9.2", @@ -2609,6 +2836,111 @@ }, "time": "2017-02-14T16:28:37+00:00" }, + { + "name": "psr/http-client", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-client.git", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "shasum": "" + }, + "require": { + "php": "^7.0 || ^8.0", + "psr/http-message": "^1.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Http\\Client\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interface for HTTP clients", + "homepage": "https://github.com/php-fig/http-client", + "keywords": [ + "http", + "http-client", + "psr", + "psr-18" + ], + "support": { + "source": "https://github.com/php-fig/http-client/tree/master" + }, + "time": "2020-06-29T06:28:15+00:00" + }, + { + "name": "psr/http-message", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-message.git", + "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-message/zipball/f6561bf28d520154e4b0ec72be95418abe6d9363", + "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Http\\Message\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interface for HTTP messages", + "homepage": "https://github.com/php-fig/http-message", + "keywords": [ + "http", + "http-message", + "psr", + "psr-7", + "request", + "response" + ], + "support": { + "source": "https://github.com/php-fig/http-message/tree/master" + }, + "time": "2016-08-06T14:39:51+00:00" + }, { "name": "psr/log", "version": "1.1.3", @@ -2786,6 +3118,50 @@ }, "time": "2021-01-18T15:53:43+00:00" }, + { + "name": "ralouphie/getallheaders", + "version": "3.0.3", + "source": { + "type": "git", + "url": "https://github.com/ralouphie/getallheaders.git", + "reference": "120b605dfeb996808c31b6477290a714d356e822" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/120b605dfeb996808c31b6477290a714d356e822", + "reference": "120b605dfeb996808c31b6477290a714d356e822", + "shasum": "" + }, + "require": { + "php": ">=5.6" + }, + "require-dev": { + "php-coveralls/php-coveralls": "^2.1", + "phpunit/phpunit": "^5 || ^6.5" + }, + "type": "library", + "autoload": { + "files": [ + "src/getallheaders.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ralph Khattar", + "email": "ralph.khattar@gmail.com" + } + ], + "description": "A polyfill for getallheaders.", + "support": { + "issues": "https://github.com/ralouphie/getallheaders/issues", + "source": "https://github.com/ralouphie/getallheaders/tree/develop" + }, + "time": "2019-03-08T08:55:37+00:00" + }, { "name": "ramsey/uuid", "version": "3.9.3", @@ -5463,28 +5839,29 @@ }, { "name": "phar-io/manifest", - "version": "1.0.3", + "version": "2.0.1", "source": { "type": "git", "url": "https://github.com/phar-io/manifest.git", - "reference": "7761fcacf03b4d4f16e7ccb606d4879ca431fcf4" + "reference": "85265efd3af7ba3ca4b2a2c34dbfc5788dd29133" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/manifest/zipball/7761fcacf03b4d4f16e7ccb606d4879ca431fcf4", - "reference": "7761fcacf03b4d4f16e7ccb606d4879ca431fcf4", + "url": "https://api.github.com/repos/phar-io/manifest/zipball/85265efd3af7ba3ca4b2a2c34dbfc5788dd29133", + "reference": "85265efd3af7ba3ca4b2a2c34dbfc5788dd29133", "shasum": "" }, "require": { "ext-dom": "*", "ext-phar": "*", - "phar-io/version": "^2.0", - "php": "^5.6 || ^7.0" + "ext-xmlwriter": "*", + "phar-io/version": "^3.0.1", + "php": "^7.2 || ^8.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { @@ -5518,24 +5895,24 @@ "issues": "https://github.com/phar-io/manifest/issues", "source": "https://github.com/phar-io/manifest/tree/master" }, - "time": "2018-07-08T19:23:20+00:00" + "time": "2020-06-27T14:33:11+00:00" }, { "name": "phar-io/version", - "version": "2.0.1", + "version": "3.1.0", "source": { "type": "git", "url": "https://github.com/phar-io/version.git", - "reference": "45a2ec53a73c70ce41d55cedef9063630abaf1b6" + "reference": "bae7c545bef187884426f042434e561ab1ddb182" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/version/zipball/45a2ec53a73c70ce41d55cedef9063630abaf1b6", - "reference": "45a2ec53a73c70ce41d55cedef9063630abaf1b6", + "url": "https://api.github.com/repos/phar-io/version/zipball/bae7c545bef187884426f042434e561ab1ddb182", + "reference": "bae7c545bef187884426f042434e561ab1ddb182", "shasum": "" }, "require": { - "php": "^5.6 || ^7.0" + "php": "^7.2 || ^8.0" }, "type": "library", "autoload": { @@ -5567,9 +5944,9 @@ "description": "Library for handling version information and constraints", "support": { "issues": "https://github.com/phar-io/version/issues", - "source": "https://github.com/phar-io/version/tree/master" + "source": "https://github.com/phar-io/version/tree/3.1.0" }, - "time": "2018-07-08T19:19:57+00:00" + "time": "2021-02-23T14:00:09+00:00" }, { "name": "phpdocumentor/reflection-common", @@ -5798,40 +6175,44 @@ }, { "name": "phpunit/php-code-coverage", - "version": "6.1.4", + "version": "9.2.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d" + "reference": "f3e026641cc91909d421802dd3ac7827ebfd97e1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f3e026641cc91909d421802dd3ac7827ebfd97e1", + "reference": "f3e026641cc91909d421802dd3ac7827ebfd97e1", "shasum": "" }, "require": { "ext-dom": "*", + "ext-libxml": "*", "ext-xmlwriter": "*", - "php": "^7.1", - "phpunit/php-file-iterator": "^2.0", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.0", - "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^3.1 || ^4.0", - "sebastian/version": "^2.0.1", - "theseer/tokenizer": "^1.1" + "nikic/php-parser": "^4.10.2", + "php": ">=7.3", + "phpunit/php-file-iterator": "^3.0.3", + "phpunit/php-text-template": "^2.0.2", + "sebastian/code-unit-reverse-lookup": "^2.0.2", + "sebastian/complexity": "^2.0", + "sebastian/environment": "^5.1.2", + "sebastian/lines-of-code": "^1.0.3", + "sebastian/version": "^3.0.1", + "theseer/tokenizer": "^1.2.0" }, "require-dev": { - "phpunit/phpunit": "^7.0" + "phpunit/phpunit": "^9.3" }, "suggest": { - "ext-xdebug": "^2.6.0" + "ext-pcov": "*", + "ext-xdebug": "*" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "6.1-dev" + "dev-master": "9.2-dev" } }, "autoload": { @@ -5859,34 +6240,40 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/master" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.5" }, - "time": "2018-10-31T16:06:48+00:00" + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-11-28T06:44:49+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "2.0.3", + "version": "3.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "4b49fb70f067272b659ef0174ff9ca40fdaa6357" + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/4b49fb70f067272b659ef0174ff9ca40fdaa6357", - "reference": "4b49fb70f067272b659ef0174ff9ca40fdaa6357", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/aa4be8575f26070b100fccb67faabb28f21f66f8", + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -5913,7 +6300,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", - "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/2.0.3" + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.5" }, "funding": [ { @@ -5921,26 +6308,97 @@ "type": "github" } ], - "time": "2020-11-30T08:25:21+00:00" + "time": "2020-09-28T05:57:25+00:00" }, { - "name": "phpunit/php-text-template", - "version": "1.2.1", + "name": "phpunit/php-invoker", + "version": "3.1.1", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" + "url": "https://github.com/sebastianbergmann/php-invoker.git", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.3" + }, + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-pcntl": "*" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.1-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Invoke callables with a timeout", + "homepage": "https://github.com/sebastianbergmann/php-invoker/", + "keywords": [ + "process" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-invoker/issues", + "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:58:55+00:00" + }, + { + "name": "phpunit/php-text-template", + "version": "2.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, "autoload": { "classmap": [ "src/" @@ -5964,34 +6422,40 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-text-template/issues", - "source": "https://github.com/sebastianbergmann/php-text-template/tree/1.2.1" + "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" }, - "time": "2015-06-21T13:50:34+00:00" + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T05:33:50+00:00" }, { "name": "phpunit/php-timer", - "version": "2.1.3", + "version": "5.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "2454ae1765516d20c4ffe103d85a58a9a3bd5662" + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/2454ae1765516d20c4ffe103d85a58a9a3bd5662", - "reference": "2454ae1765516d20c4ffe103d85a58a9a3bd5662", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.1-dev" + "dev-master": "5.0-dev" } }, "autoload": { @@ -6017,7 +6481,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-timer/issues", - "source": "https://github.com/sebastianbergmann/php-timer/tree/2.1.3" + "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" }, "funding": [ { @@ -6025,117 +6489,59 @@ "type": "github" } ], - "time": "2020-11-30T08:20:02+00:00" - }, - { - "name": "phpunit/php-token-stream", - "version": "3.1.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "472b687829041c24b25f475e14c2f38a09edf1c2" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/472b687829041c24b25f475e14c2f38a09edf1c2", - "reference": "472b687829041c24b25f475e14c2f38a09edf1c2", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": ">=7.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.1-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", - "keywords": [ - "tokenizer" - ], - "support": { - "issues": "https://github.com/sebastianbergmann/php-token-stream/issues", - "source": "https://github.com/sebastianbergmann/php-token-stream/tree/3.1.2" - }, - "funding": [ - { - "url": "https://github.com/sebastianbergmann", - "type": "github" - } - ], - "abandoned": true, - "time": "2020-11-30T08:38:46+00:00" + "time": "2020-10-26T13:16:10+00:00" }, { "name": "phpunit/phpunit", - "version": "7.5.20", + "version": "9.5.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "9467db479d1b0487c99733bb1e7944d32deded2c" + "reference": "f661659747f2f87f9e72095bb207bceb0f151cb4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/9467db479d1b0487c99733bb1e7944d32deded2c", - "reference": "9467db479d1b0487c99733bb1e7944d32deded2c", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/f661659747f2f87f9e72095bb207bceb0f151cb4", + "reference": "f661659747f2f87f9e72095bb207bceb0f151cb4", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.1", + "doctrine/instantiator": "^1.3.1", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", "ext-mbstring": "*", "ext-xml": "*", - "myclabs/deep-copy": "^1.7", - "phar-io/manifest": "^1.0.2", - "phar-io/version": "^2.0", - "php": "^7.1", - "phpspec/prophecy": "^1.7", - "phpunit/php-code-coverage": "^6.0.7", - "phpunit/php-file-iterator": "^2.0.1", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-timer": "^2.1", - "sebastian/comparator": "^3.0", - "sebastian/diff": "^3.0", - "sebastian/environment": "^4.0", - "sebastian/exporter": "^3.1", - "sebastian/global-state": "^2.0", - "sebastian/object-enumerator": "^3.0.3", - "sebastian/resource-operations": "^2.0", - "sebastian/version": "^2.0.1" - }, - "conflict": { - "phpunit/phpunit-mock-objects": "*" + "ext-xmlwriter": "*", + "myclabs/deep-copy": "^1.10.1", + "phar-io/manifest": "^2.0.1", + "phar-io/version": "^3.0.2", + "php": ">=7.3", + "phpspec/prophecy": "^1.12.1", + "phpunit/php-code-coverage": "^9.2.3", + "phpunit/php-file-iterator": "^3.0.5", + "phpunit/php-invoker": "^3.1.1", + "phpunit/php-text-template": "^2.0.3", + "phpunit/php-timer": "^5.0.2", + "sebastian/cli-parser": "^1.0.1", + "sebastian/code-unit": "^1.0.6", + "sebastian/comparator": "^4.0.5", + "sebastian/diff": "^4.0.3", + "sebastian/environment": "^5.1.3", + "sebastian/exporter": "^4.0.3", + "sebastian/global-state": "^5.0.1", + "sebastian/object-enumerator": "^4.0.3", + "sebastian/resource-operations": "^3.0.3", + "sebastian/type": "^2.3", + "sebastian/version": "^3.0.2" }, "require-dev": { - "ext-pdo": "*" + "ext-pdo": "*", + "phpspec/prophecy-phpunit": "^2.0.1" }, "suggest": { "ext-soap": "*", - "ext-xdebug": "*", - "phpunit/php-invoker": "^2.0" + "ext-xdebug": "*" }, "bin": [ "phpunit" @@ -6143,12 +6549,15 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "7.5-dev" + "dev-master": "9.5-dev" } }, "autoload": { "classmap": [ "src/" + ], + "files": [ + "src/Framework/Assert/Functions.php" ] }, "notification-url": "https://packagist.org/downloads/", @@ -6171,34 +6580,156 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/7.5.20" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.2" }, - "time": "2020-01-08T08:45:45+00:00" + "funding": [ + { + "url": "https://phpunit.de/donate.html", + "type": "custom" + }, + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2021-02-02T14:45:58+00:00" }, { - "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.2", + "name": "sebastian/cli-parser", + "version": "1.0.1", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "1de8cd5c010cb153fcd68b8d0f64606f523f7619" + "url": "https://github.com/sebastianbergmann/cli-parser.git", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/1de8cd5c010cb153fcd68b8d0f64606f523f7619", - "reference": "1de8cd5c010cb153fcd68b8d0f64606f523f7619", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/442e7c7e687e42adc03470c7b668bc4b2402c0b2", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2", "shasum": "" }, "require": { - "php": ">=5.6" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for parsing CLI options", + "homepage": "https://github.com/sebastianbergmann/cli-parser", + "support": { + "issues": "https://github.com/sebastianbergmann/cli-parser/issues", + "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T06:08:49+00:00" + }, + { + "name": "sebastian/code-unit", + "version": "1.0.8", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit.git", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the PHP code units", + "homepage": "https://github.com/sebastianbergmann/code-unit", + "support": { + "issues": "https://github.com/sebastianbergmann/code-unit/issues", + "source": "https://github.com/sebastianbergmann/code-unit/tree/1.0.8" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:08:54+00:00" + }, + { + "name": "sebastian/code-unit-reverse-lookup", + "version": "2.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" } }, "autoload": { @@ -6220,7 +6751,7 @@ "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", "support": { "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues", - "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/1.0.2" + "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/2.0.3" }, "funding": [ { @@ -6228,34 +6759,34 @@ "type": "github" } ], - "time": "2020-11-30T08:15:22+00:00" + "time": "2020-09-28T05:30:19+00:00" }, { "name": "sebastian/comparator", - "version": "3.0.3", + "version": "4.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "1071dfcef776a57013124ff35e1fc41ccd294758" + "reference": "55f4261989e546dc112258c7a75935a81a7ce382" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/1071dfcef776a57013124ff35e1fc41ccd294758", - "reference": "1071dfcef776a57013124ff35e1fc41ccd294758", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/55f4261989e546dc112258c7a75935a81a7ce382", + "reference": "55f4261989e546dc112258c7a75935a81a7ce382", "shasum": "" }, "require": { - "php": ">=7.1", - "sebastian/diff": "^3.0", - "sebastian/exporter": "^3.1" + "php": ">=7.3", + "sebastian/diff": "^4.0", + "sebastian/exporter": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -6294,7 +6825,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/comparator/issues", - "source": "https://github.com/sebastianbergmann/comparator/tree/3.0.3" + "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.6" }, "funding": [ { @@ -6302,33 +6833,90 @@ "type": "github" } ], - "time": "2020-11-30T08:04:30+00:00" + "time": "2020-10-26T15:49:45+00:00" }, { - "name": "sebastian/diff", - "version": "3.0.3", + "name": "sebastian/complexity", + "version": "2.0.2", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "14f72dd46eaf2f2293cbe79c93cc0bc43161a211" + "url": "https://github.com/sebastianbergmann/complexity.git", + "reference": "739b35e53379900cc9ac327b2147867b8b6efd88" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/14f72dd46eaf2f2293cbe79c93cc0bc43161a211", - "reference": "14f72dd46eaf2f2293cbe79c93cc0bc43161a211", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/739b35e53379900cc9ac327b2147867b8b6efd88", + "reference": "739b35e53379900cc9ac327b2147867b8b6efd88", "shasum": "" }, "require": { - "php": ">=7.1" + "nikic/php-parser": "^4.7", + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5 || ^8.0", - "symfony/process": "^2 || ^3.3 || ^4" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "2.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for calculating the complexity of PHP code units", + "homepage": "https://github.com/sebastianbergmann/complexity", + "support": { + "issues": "https://github.com/sebastianbergmann/complexity/issues", + "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T15:52:27+00:00" + }, + { + "name": "sebastian/diff", + "version": "4.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/diff.git", + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3", + "symfony/process": "^4.2 || ^5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" } }, "autoload": { @@ -6360,7 +6948,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", - "source": "https://github.com/sebastianbergmann/diff/tree/3.0.3" + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.4" }, "funding": [ { @@ -6368,27 +6956,27 @@ "type": "github" } ], - "time": "2020-11-30T07:59:04+00:00" + "time": "2020-10-26T13:10:38+00:00" }, { "name": "sebastian/environment", - "version": "4.2.4", + "version": "5.1.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "d47bbbad83711771f167c72d4e3f25f7fcc1f8b0" + "reference": "388b6ced16caa751030f6a69e588299fa09200ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/d47bbbad83711771f167c72d4e3f25f7fcc1f8b0", - "reference": "d47bbbad83711771f167c72d4e3f25f7fcc1f8b0", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/388b6ced16caa751030f6a69e588299fa09200ac", + "reference": "388b6ced16caa751030f6a69e588299fa09200ac", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5" + "phpunit/phpunit": "^9.3" }, "suggest": { "ext-posix": "*" @@ -6396,7 +6984,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "4.2-dev" + "dev-master": "5.1-dev" } }, "autoload": { @@ -6423,7 +7011,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/environment/issues", - "source": "https://github.com/sebastianbergmann/environment/tree/4.2.4" + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.3" }, "funding": [ { @@ -6431,34 +7019,34 @@ "type": "github" } ], - "time": "2020-11-30T07:53:42+00:00" + "time": "2020-09-28T05:52:38+00:00" }, { "name": "sebastian/exporter", - "version": "3.1.3", + "version": "4.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "6b853149eab67d4da22291d36f5b0631c0fd856e" + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/6b853149eab67d4da22291d36f5b0631c0fd856e", - "reference": "6b853149eab67d4da22291d36f5b0631c0fd856e", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/d89cc98761b8cb5a1a235a6b703ae50d34080e65", + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65", "shasum": "" }, "require": { - "php": ">=7.0", - "sebastian/recursion-context": "^3.0" + "php": ">=7.3", + "sebastian/recursion-context": "^4.0" }, "require-dev": { "ext-mbstring": "*", - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -6500,7 +7088,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", - "source": "https://github.com/sebastianbergmann/exporter/tree/3.1.3" + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.3" }, "funding": [ { @@ -6508,27 +7096,30 @@ "type": "github" } ], - "time": "2020-11-30T07:47:53+00:00" + "time": "2020-09-28T05:24:23+00:00" }, { "name": "sebastian/global-state", - "version": "2.0.0", + "version": "5.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4" + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/a90ccbddffa067b51f574dea6eb25d5680839455", + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455", "shasum": "" }, "require": { - "php": "^7.0" + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "ext-dom": "*", + "phpunit/phpunit": "^9.3" }, "suggest": { "ext-uopz": "*" @@ -6536,7 +7127,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "5.0-dev" } }, "autoload": { @@ -6561,36 +7152,99 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", - "source": "https://github.com/sebastianbergmann/global-state/tree/2.0.0" + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.2" }, - "time": "2017-04-27T15:39:26+00:00" + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T15:55:19+00:00" }, { - "name": "sebastian/object-enumerator", - "version": "3.0.4", + "name": "sebastian/lines-of-code", + "version": "1.0.3", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "e67f6d32ebd0c749cf9d1dbd9f226c727043cdf2" + "url": "https://github.com/sebastianbergmann/lines-of-code.git", + "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/e67f6d32ebd0c749cf9d1dbd9f226c727043cdf2", - "reference": "e67f6d32ebd0c749cf9d1dbd9f226c727043cdf2", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/c1c2e997aa3146983ed888ad08b15470a2e22ecc", + "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc", "shasum": "" }, "require": { - "php": ">=7.0", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "nikic/php-parser": "^4.6", + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for counting the lines of code in PHP source code", + "homepage": "https://github.com/sebastianbergmann/lines-of-code", + "support": { + "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-11-28T06:42:11+00:00" + }, + { + "name": "sebastian/object-enumerator", + "version": "4.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/object-enumerator.git", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" } }, "autoload": { @@ -6612,7 +7266,7 @@ "homepage": "https://github.com/sebastianbergmann/object-enumerator/", "support": { "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", - "source": "https://github.com/sebastianbergmann/object-enumerator/tree/3.0.4" + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/4.0.4" }, "funding": [ { @@ -6620,32 +7274,32 @@ "type": "github" } ], - "time": "2020-11-30T07:40:27+00:00" + "time": "2020-10-26T13:12:34+00:00" }, { "name": "sebastian/object-reflector", - "version": "1.1.2", + "version": "2.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "9b8772b9cbd456ab45d4a598d2dd1a1bced6363d" + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/9b8772b9cbd456ab45d4a598d2dd1a1bced6363d", - "reference": "9b8772b9cbd456ab45d4a598d2dd1a1bced6363d", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", "shasum": "" }, "require": { - "php": ">=7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -6667,7 +7321,7 @@ "homepage": "https://github.com/sebastianbergmann/object-reflector/", "support": { "issues": "https://github.com/sebastianbergmann/object-reflector/issues", - "source": "https://github.com/sebastianbergmann/object-reflector/tree/1.1.2" + "source": "https://github.com/sebastianbergmann/object-reflector/tree/2.0.4" }, "funding": [ { @@ -6675,32 +7329,32 @@ "type": "github" } ], - "time": "2020-11-30T07:37:18+00:00" + "time": "2020-10-26T13:14:26+00:00" }, { "name": "sebastian/recursion-context", - "version": "3.0.1", + "version": "4.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "367dcba38d6e1977be014dc4b22f47a484dac7fb" + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/367dcba38d6e1977be014dc4b22f47a484dac7fb", - "reference": "367dcba38d6e1977be014dc4b22f47a484dac7fb", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/cd9d8cf3c5804de4341c283ed787f099f5506172", + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172", "shasum": "" }, "require": { - "php": ">=7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -6730,7 +7384,7 @@ "homepage": "http://www.github.com/sebastianbergmann/recursion-context", "support": { "issues": "https://github.com/sebastianbergmann/recursion-context/issues", - "source": "https://github.com/sebastianbergmann/recursion-context/tree/3.0.1" + "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.4" }, "funding": [ { @@ -6738,29 +7392,32 @@ "type": "github" } ], - "time": "2020-11-30T07:34:24+00:00" + "time": "2020-10-26T13:17:30+00:00" }, { "name": "sebastian/resource-operations", - "version": "2.0.2", + "version": "3.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "31d35ca87926450c44eae7e2611d45a7a65ea8b3" + "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/31d35ca87926450c44eae7e2611d45a7a65ea8b3", - "reference": "31d35ca87926450c44eae7e2611d45a7a65ea8b3", + "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", + "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -6782,7 +7439,7 @@ "homepage": "https://www.github.com/sebastianbergmann/resource-operations", "support": { "issues": "https://github.com/sebastianbergmann/resource-operations/issues", - "source": "https://github.com/sebastianbergmann/resource-operations/tree/2.0.2" + "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.3" }, "funding": [ { @@ -6790,29 +7447,85 @@ "type": "github" } ], - "time": "2020-11-30T07:30:19+00:00" + "time": "2020-09-28T06:45:17+00:00" }, { - "name": "sebastian/version", - "version": "2.0.1", + "name": "sebastian/type", + "version": "2.3.1", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/version.git", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019" + "url": "https://github.com/sebastianbergmann/type.git", + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/99732be0ddb3361e16ad77b68ba41efc8e979019", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/81cd61ab7bbf2de744aba0ea61fae32f721df3d2", + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2", "shasum": "" }, "require": { - "php": ">=5.6" + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "2.3-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the types of the PHP type system", + "homepage": "https://github.com/sebastianbergmann/type", + "support": { + "issues": "https://github.com/sebastianbergmann/type/issues", + "source": "https://github.com/sebastianbergmann/type/tree/2.3.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:18:59+00:00" + }, + { + "name": "sebastian/version", + "version": "3.0.2", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/version.git", + "reference": "c6c1022351a901512170118436c764e473f6de8c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c6c1022351a901512170118436c764e473f6de8c", + "reference": "c6c1022351a901512170118436c764e473f6de8c", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" } }, "autoload": { @@ -6835,9 +7548,15 @@ "homepage": "https://github.com/sebastianbergmann/version", "support": { "issues": "https://github.com/sebastianbergmann/version/issues", - "source": "https://github.com/sebastianbergmann/version/tree/master" + "source": "https://github.com/sebastianbergmann/version/tree/3.0.2" }, - "time": "2016-10-03T07:35:21+00:00" + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T06:39:44+00:00" }, { "name": "theseer/tokenizer", diff --git a/config/app.php b/config/app.php index a1648a7..f09095f 100755 --- a/config/app.php +++ b/config/app.php @@ -2,7 +2,7 @@ return [ - /* + /* |-------------------------------------------------------------------------- | Application Name |-------------------------------------------------------------------------- @@ -11,13 +11,13 @@ return [ | framework needs to place the application's name in a notification or | any other location as required by the application or its packages. | - */ + */ 'workspacePath' => storage_path() . DIRECTORY_SEPARATOR . "workspace", 'name' => env('APP_NAME', 'Tethys'), - - /* + + /* |-------------------------------------------------------------------------- | Application Environment |-------------------------------------------------------------------------- @@ -26,10 +26,10 @@ return [ | running in. This may determine how you prefer to configure various | services your application utilizes. Set this in your ".env" file. | - */ + */ 'env' => env('APP_ENV', 'production'), - + /* |-------------------------------------------------------------------------- | Application Debug Mode @@ -39,7 +39,7 @@ return [ | stack traces will be shown on every error that occurs within your | application. If disabled, a simple generic error page is shown. | - */ + */ 'debug' => env('APP_DEBUG', false), @@ -52,7 +52,7 @@ return [ | the Artisan command line tool. You should set this to the root of | your application so that it is used when running Artisan tasks. | - */ + */ 'url' => env('APP_URL', 'http://localhost'), @@ -65,7 +65,7 @@ return [ | will be used by the PHP date and date-time functions. We have gone | ahead and set this to a sensible default for you out of the box. | - */ + */ // https://www.php.net/manual/en/timezones.europe.php 'timezone' => 'Europe/Vienna', @@ -78,7 +78,7 @@ return [ | by the translation service provider. You are free to set this value | to any of the locales which will be supported by the application. | - */ + */ 'locale' => env('APP_LOCALE', 'en'), @@ -91,7 +91,7 @@ return [ | is not available. You may change the value to correspond to any of | the language folders that are provided through your application. | - */ + */ 'fallback_locale' => env('APP_FALLBACK_LOCALE', 'en'), @@ -104,7 +104,7 @@ return [ | to a random, 32 character string, otherwise these encrypted strings | will not be safe. Please do this before deploying an application! | - */ + */ 'key' => env('APP_KEY', 'SomeRandomString'), @@ -121,7 +121,7 @@ return [ | | Available Settings: "single", "daily", "syslog", "errorlog" | - */ + */ // 'log' => 'single', // //debug, info, notice, warning, error, critical, alert, emergency. @@ -136,7 +136,7 @@ return [ | request to your application. Feel free to add your own services to | this array to grant expanded functionality to your applications. | - */ + */ 'providers' => [ @@ -167,7 +167,7 @@ return [ 'Illuminate\Validation\ValidationServiceProvider', 'Illuminate\View\ViewServiceProvider', - /* + /* * Package Service Providers... */ // 'Illuminate\Html\HtmlServiceProvider', @@ -178,15 +178,15 @@ return [ /* * Application Service Providers... */ - 'App\Providers\AppServiceProvider', + App\Providers\AppServiceProvider::class, App\Providers\AuthServiceProvider::class, - // App\Providers\BroadcastServiceProvider::class, - 'App\Providers\ConfigServiceProvider', - 'App\Providers\EventServiceProvider', - 'App\Providers\RouteServiceProvider', - // List off others providers... - App\Providers\SolariumServiceProvider::class, - + // App\Providers\BroadcastServiceProvider::class, + App\Providers\ConfigServiceProvider::class, + App\Providers\EventServiceProvider::class, + App\Providers\RouteServiceProvider::class, + // List off others providers... + App\Providers\SolariumServiceProvider::class, + App\Providers\DoiServiceProvider::class, ], @@ -199,55 +199,56 @@ return [ | is started. However, feel free to register as many as you wish as | the aliases are "lazy" loaded so they don't hinder performance. | - */ + */ 'aliases' => [ - 'App' => 'Illuminate\Support\Facades\App', + 'App' => Illuminate\Support\Facades\App::class, 'Arr' => Illuminate\Support\Arr::class, - 'Artisan' => 'Illuminate\Support\Facades\Artisan', + 'Artisan' => Illuminate\Support\Facades\Artisan::class, 'Auth' => Illuminate\Support\Facades\Auth::class, 'Blade' => Illuminate\Support\Facades\Blade::class, 'Broadcast' => Illuminate\Support\Facades\Broadcast::class, - 'Bus' => 'Illuminate\Support\Facades\Bus', - 'Cache' => 'Illuminate\Support\Facades\Cache', - 'Config' => 'Illuminate\Support\Facades\Config', - 'Cookie' => 'Illuminate\Support\Facades\Cookie', - 'Crypt' => 'Illuminate\Support\Facades\Crypt', - 'DB' => 'Illuminate\Support\Facades\DB', - 'Eloquent' => 'Illuminate\Database\Eloquent\Model', - 'Event' => 'Illuminate\Support\Facades\Event', - 'File' => 'Illuminate\Support\Facades\File', + 'Bus' => 'Illuminate\Support\Facades\Bus', + 'Cache' => 'Illuminate\Support\Facades\Cache', + 'Config' => 'Illuminate\Support\Facades\Config', + 'Cookie' => 'Illuminate\Support\Facades\Cookie', + 'Crypt' => 'Illuminate\Support\Facades\Crypt', + 'DB' => 'Illuminate\Support\Facades\DB', + 'Eloquent' => 'Illuminate\Database\Eloquent\Model', + 'Event' => 'Illuminate\Support\Facades\Event', + 'File' => 'Illuminate\Support\Facades\File', 'Gate' => Illuminate\Support\Facades\Gate::class, - 'Hash' => 'Illuminate\Support\Facades\Hash', - 'Input' => 'Illuminate\Support\Facades\Input', + 'Hash' => Illuminate\Support\Facades\Hash::class, + 'Input' => Illuminate\Support\Facades\Input::class, // 'Inspiring' => 'Illuminate\Foundation\Inspiring', - 'Lang' => 'Illuminate\Support\Facades\Lang', + 'Lang' => Illuminate\Support\Facades\Lang::class, 'Log' => Illuminate\Support\Facades\Log::class, - 'Mail' => 'Illuminate\Support\Facades\Mail', + 'Mail' => 'Illuminate\Support\Facades\Mail', 'Notification' => Illuminate\Support\Facades\Notification::class, - 'Password' => 'Illuminate\Support\Facades\Password', - 'Queue' => 'Illuminate\Support\Facades\Queue', - 'Redirect' => 'Illuminate\Support\Facades\Redirect', - 'Redis' => 'Illuminate\Support\Facades\Redis', - 'Request' => 'Illuminate\Support\Facades\Request', - 'Response' => 'Illuminate\Support\Facades\Response', - 'Route' => 'Illuminate\Support\Facades\Route', - 'Schema' => 'Illuminate\Support\Facades\Schema', - 'Session' => 'Illuminate\Support\Facades\Session', - 'Storage' => 'Illuminate\Support\Facades\Storage', - 'URL' => 'Illuminate\Support\Facades\URL', + 'Password' => 'Illuminate\Support\Facades\Password', + 'Queue' => 'Illuminate\Support\Facades\Queue', + 'Redirect' => 'Illuminate\Support\Facades\Redirect', + 'Redis' => 'Illuminate\Support\Facades\Redis', + 'Request' => 'Illuminate\Support\Facades\Request', + 'Response' => 'Illuminate\Support\Facades\Response', + 'Route' => 'Illuminate\Support\Facades\Route', + 'Schema' => 'Illuminate\Support\Facades\Schema', + 'Session' => 'Illuminate\Support\Facades\Session', + 'Storage' => 'Illuminate\Support\Facades\Storage', + 'URL' => 'Illuminate\Support\Facades\URL', 'Validator' => 'Illuminate\Support\Facades\Validator', - 'View' => 'Illuminate\Support\Facades\View', + 'View' => 'Illuminate\Support\Facades\View', - /* + /* * Third Party Aliases */ // 'Form' => 'Illuminate\Html\FormFacade', // 'HTML' => 'Illuminate\Html\HtmlFacade', // 'Form' => 'Collective\Html\FormFacade', // 'Html' => 'Collective\Html\HtmlFacade', - 'Breadcrumbs' => DaveJamesMiller\Breadcrumbs\Facades\Breadcrumbs::class, + // 'Breadcrumbs' => DaveJamesMiller\Breadcrumbs\Facades\Breadcrumbs::class, + 'Breadcrumbs' => Diglactic\Breadcrumbs\Breadcrumbs::class, //'Datatables' => Yajra\DataTables\Facades\DataTables::class ], diff --git a/config/database.php b/config/database.php index 8e577f1..5f8887e 100755 --- a/config/database.php +++ b/config/database.php @@ -45,6 +45,18 @@ return [ */ 'connections' => [ + 'testing' => [ + 'driver' => 'pgsql', + 'host' => env('DB_HOST', 'pgsql'), + 'port' => env('DB_PORT', '5432'), + 'database' => env('DB_DATABASE'), + 'username' => env('DB_USERNAME'), + 'password' => env('DB_PASSWORD'), + 'charset' => 'utf8', + 'prefix' => '', + 'schema' => env('DB_SCHEMA', 'public'), + 'sslmode' => 'prefer', + ], 'sqlite' => [ 'driver' => 'sqlite', @@ -56,9 +68,9 @@ return [ 'driver' => 'pgsql', 'host' => env('DB_HOST', 'pgsql'), 'port' => env('DB_PORT', '5432'), - 'database' => env('DB_DATABASE', 'repository'), - 'username' => env('DB_USERNAME', 'opus4admin'), - 'password' => env('DB_PASSWORD', 'opus4admin007'), + 'database' => env('DB_DATABASE'), + 'username' => env('DB_USERNAME'), + 'password' => env('DB_PASSWORD'), 'charset' => 'utf8', 'prefix' => '', 'schema' => env('DB_SCHEMA', 'public'), @@ -68,10 +80,10 @@ return [ 'sqlsrv' => [ 'driver' => 'sqlsrv', - 'host' => env('DB_HOST', 'zontik\test'), - 'database' => env('DB_DATABASE', 'opusdb'), - 'username' => env('DB_USERNAME', 'opus4'), - 'password' => env('DB_PASSWORD', 'opus4007'), + 'host' => env('DB_HOST'), + 'database' => env('DB_DATABASE'), + 'username' => env('DB_USERNAME'), + 'password' => env('DB_PASSWORD'), 'prefix' => '', ], diff --git a/config/tethys.php b/config/tethys.php new file mode 100644 index 0000000..32ee19a --- /dev/null +++ b/config/tethys.php @@ -0,0 +1,13 @@ + 3156505, + 'ccBaseuri' => 'https://creativecommons.org/licenses/|/3.0/', + 'datacite_username' => env('DATACITE_USERNAME'), + // 'datacite_test_username' => env('DATACITE_TEST_USERNAME'), + 'datacite_password' => env('DATACITE_PASSWORD'), + // 'datacite_test_password' => env('DATACITE_TEST_PASSWORD'), + 'datacite_service_url' => env('DATACITE_SERVICE_URL'), + // 'datacite_test_service_url' => env('DATACITE_TEST_SERVICE_URL'), + 'datacite_prefix' => env('DATACITE_PREFIX'), + 'base_domain' => 'https://www.tethys.at/', +]; diff --git a/database/migrations/2021_02_26_153027_create_dataset_identifiers_table.php b/database/migrations/2021_02_26_153027_create_dataset_identifiers_table.php new file mode 100644 index 0000000..d7e2de4 --- /dev/null +++ b/database/migrations/2021_02_26_153027_create_dataset_identifiers_table.php @@ -0,0 +1,54 @@ +increments('id'); + + // foreign key to: documents.id + $table->integer('dataset_id')->unsigned(); + ; + $table->foreign('dataset_id')->references('id')->on('documents') + ->onUpdate('cascade')->onDelete('cascade'); + + // value of the identifier + $table->string('value', 255); + $table->enum( + 'type', + ["doi", "handle", "isbn", "issn", "url", "urn"] + ); + // DOI registration status + $table->enum( + 'status', + ['draft', 'registered', 'findable'] + )->nullable(); + // timestamp of DOI registration + $table->timestamp('registration_ts'); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::table('dataset_identifiers', function (Blueprint $table) { + // + }); + } +} diff --git a/doi_notes.txt b/doi_notes.txt new file mode 100644 index 0000000..5f7000c --- /dev/null +++ b/doi_notes.txt @@ -0,0 +1,10 @@ +doi_notes: + +php artisan make:controller DOIController --resource --model "Models\DatasetIdentifier" + + + +composer require guzzlehttp/guzzle + + +php artisan make:migration create_dataset_identifiers_table --table="dataset_identifiers" \ No newline at end of file diff --git a/phpunit.xml b/phpunit.xml index d66acd0..78e182a 100755 --- a/phpunit.xml +++ b/phpunit.xml @@ -1,23 +1,34 @@ - + ./tests/ + + + + ./tests/Feature + + + + ./app + + - - - + + + + + + + diff --git a/public/prefixes/doi_datacite.xslt b/public/prefixes/doi_datacite.xslt new file mode 100644 index 0000000..7b7c0e7 --- /dev/null +++ b/public/prefixes/doi_datacite.xslt @@ -0,0 +1,368 @@ + + + + + + + + + + + + + + + + + + + / + + . + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Dataset + + + + + + + + + + + + + + + + + + + datasets + + + + + + + + + + + + + + + + + + + + Available + + + + + + + Created + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + <xsl:if test="@Language != ''"> + <xsl:attribute name="xml:lang"> + <xsl:value-of select="@Language" /> + </xsl:attribute> + </xsl:if> + <xsl:if test="@Type != '' and @Type != 'Main'"> + <xsl:attribute name="titleType"> + <xsl:value-of select="@Type" /> + </xsl:attribute> + </xsl:if> + <xsl:value-of select="@Value"/> + + + + + <xsl:if test="@Language != ''"> + <xsl:attribute name="xml:lang"> + <xsl:value-of select="@Language" /> + </xsl:attribute> + </xsl:if> + <xsl:if test="@Type != '' and @Type != 'Main'"> + <xsl:attribute name="titleType"> + <xsl:value-of select="@Type" /> + </xsl:attribute> + </xsl:if> + <xsl:value-of select="@Value"/> + + + + + + + + + + + + + + + + + + url + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + , + + + + ( + + ) + + + + + + + + + + + + + + + GBA + + + + + + + + + + + + + + + + + + https://spdx.org/licenses/ + + + SPDX + + + CC-BY-NC-ND-4.0 + + + + + + + info:eu-repo/semantics/openAccess + + Open Access + + + + + \ No newline at end of file diff --git a/routes/breadcrumbs.php b/routes/breadcrumbs.php index 5c0cf27..92360de 100644 --- a/routes/breadcrumbs.php +++ b/routes/breadcrumbs.php @@ -1,5 +1,6 @@ call('GET', '/'); - $this->assertEquals(200, $response->getStatusCode()); } } diff --git a/tests/Feature/DoiClientTest.php b/tests/Feature/DoiClientTest.php new file mode 100644 index 0000000..6d78beb --- /dev/null +++ b/tests/Feature/DoiClientTest.php @@ -0,0 +1,68 @@ +get('/'); + // $response->assertStatus(200); + // } + + // public function testCheckDoi() + // { + // $client = new DoiClient(); + // // $this->setExpectedException('Opus\Doi\ClientException'); + // $result = $client->checkDoi( + // '10.5072/tethys-999', + // 'http://localhost/opus4/frontdoor/index/index/999' + // ); + // $this->assertTrue($result); + + // $result = $client->checkDoi( + // '10.5072/tethys-999', + // 'http://localhost/opus4/frontdoor/index/index/111' + // ); + // $this->assertFalse($result); + // } + + public function testRegisterDoiWithDataCiteTestAccount() + { + // $this->markTestSkipped( + // 'Test kann nur manuell gestartet werden (Zugangsdaten zum MDS-Testservice von DataCite erforderlich)' + // ); + + $myRequest = new Request(); + $myRequest->setMethod('POST'); + + $myRequest->request->add( + [ + 'publish_id' => 1, + 'path' => 'https://www.demo.laudatio-repository.org/foo' + ] + ); + + $doiController = new \App\Http\Controllers\DoiController(new DoiClient()); + $doiController->store($myRequest); + + + // $client = new DoiClient(); + // $client->registerDoi( + // '10.5072/tethys-999', + // xmlMeta, + // 'http://localhost/opus4/frontdoor/index/index/999' + // ); + } +} diff --git a/tests/TestCase.php b/tests/TestCase.php index 069f0b8..db891b9 100755 --- a/tests/TestCase.php +++ b/tests/TestCase.php @@ -1,6 +1,10 @@ make('Illuminate\Contracts\Console\Kernel')->bootstrap(); - + $app = require __DIR__ . '/../bootstrap/app.php'; + $app->make(Kernel::class)->bootstrap(); return $app; } }