Updated composer and optimized unit tests

This commit is contained in:
Kevin Frantz 2018-10-28 22:13:33 +01:00
parent de51649d63
commit 7848c90615
5 changed files with 72 additions and 74 deletions

View File

@ -1,6 +1,7 @@
(
cd $(dirname $(readlink -f ${0}))/../;
cp -v .env.dist docker-symfony/.env;
cp -v ./application/phpunit.xml.dist ./application/phpunit.xml;
cd docker-symfony;
docker-compose build;
docker-compose up -d;

View File

@ -0,0 +1 @@
(cd $(dirname $(readlink -f ${0}))/../docker-symfony/ && docker-compose exec php php -d memory_limit=128M /var/www/symfony/vendor/bin/phpunit --coverage-html var/test-coverage-report)

View File

@ -1283,16 +1283,16 @@
},
{
"name": "fresh/doctrine-enum-bundle",
"version": "v6.2.1",
"version": "v6.2.2",
"source": {
"type": "git",
"url": "https://github.com/fre5h/DoctrineEnumBundle.git",
"reference": "5ee610a02fdc4b8a0f3073fb2740dfc817ff6424"
"reference": "b1758044127fd1154c7b0ccb810e85335565918d"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/fre5h/DoctrineEnumBundle/zipball/5ee610a02fdc4b8a0f3073fb2740dfc817ff6424",
"reference": "5ee610a02fdc4b8a0f3073fb2740dfc817ff6424",
"url": "https://api.github.com/repos/fre5h/DoctrineEnumBundle/zipball/b1758044127fd1154c7b0ccb810e85335565918d",
"reference": "b1758044127fd1154c7b0ccb810e85335565918d",
"shasum": ""
},
"require": {
@ -1359,7 +1359,7 @@
"symfony",
"type"
],
"time": "2018-06-02T09:50:27+00:00"
"time": "2018-10-16T20:33:07+00:00"
},
{
"name": "friendsofsymfony/rest-bundle",
@ -1591,16 +1591,16 @@
},
{
"name": "jms/metadata",
"version": "1.6.0",
"version": "1.7.0",
"source": {
"type": "git",
"url": "https://github.com/schmittjoh/metadata.git",
"reference": "6a06970a10e0a532fb52d3959547123b84a3b3ab"
"reference": "e5854ab1aa643623dc64adde718a8eec32b957a8"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/schmittjoh/metadata/zipball/6a06970a10e0a532fb52d3959547123b84a3b3ab",
"reference": "6a06970a10e0a532fb52d3959547123b84a3b3ab",
"url": "https://api.github.com/repos/schmittjoh/metadata/zipball/e5854ab1aa643623dc64adde718a8eec32b957a8",
"reference": "e5854ab1aa643623dc64adde718a8eec32b957a8",
"shasum": ""
},
"require": {
@ -1623,9 +1623,13 @@
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"Apache-2.0"
"MIT"
],
"authors": [
{
"name": "Asmir Mustafic",
"email": "goetas@gmail.com"
},
{
"name": "Johannes M. Schmitt",
"email": "schmittjoh@gmail.com"
@ -1638,7 +1642,7 @@
"xml",
"yaml"
],
"time": "2016-12-05T10:18:33+00:00"
"time": "2018-10-26T12:40:10+00:00"
},
{
"name": "jms/parser-lib",
@ -2644,16 +2648,16 @@
},
{
"name": "sensio/framework-extra-bundle",
"version": "v5.2.1",
"version": "v5.2.2",
"source": {
"type": "git",
"url": "https://github.com/sensiolabs/SensioFrameworkExtraBundle.git",
"reference": "535b56b7b0325e87b15b9c57bd3631ae2a0b9f16"
"reference": "9ef408febe2f12e70118ef61c6515035a06c5830"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sensiolabs/SensioFrameworkExtraBundle/zipball/535b56b7b0325e87b15b9c57bd3631ae2a0b9f16",
"reference": "535b56b7b0325e87b15b9c57bd3631ae2a0b9f16",
"url": "https://api.github.com/repos/sensiolabs/SensioFrameworkExtraBundle/zipball/9ef408febe2f12e70118ef61c6515035a06c5830",
"reference": "9ef408febe2f12e70118ef61c6515035a06c5830",
"shasum": ""
},
"require": {
@ -2711,7 +2715,7 @@
"annotations",
"controllers"
],
"time": "2018-09-30T05:16:57+00:00"
"time": "2018-10-26T14:09:02+00:00"
},
{
"name": "simplethings/entity-audit-bundle",
@ -4886,16 +4890,16 @@
},
{
"name": "symfony/swiftmailer-bundle",
"version": "v3.2.3",
"version": "v3.2.4",
"source": {
"type": "git",
"url": "https://github.com/symfony/swiftmailer-bundle.git",
"reference": "7bd5de67552ee3f7e04df89d662d41eba346dc83"
"reference": "bd47db86d0b8415f6317c2be149bbacfab11a9cf"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/swiftmailer-bundle/zipball/7bd5de67552ee3f7e04df89d662d41eba346dc83",
"reference": "7bd5de67552ee3f7e04df89d662d41eba346dc83",
"url": "https://api.github.com/repos/symfony/swiftmailer-bundle/zipball/bd47db86d0b8415f6317c2be149bbacfab11a9cf",
"reference": "bd47db86d0b8415f6317c2be149bbacfab11a9cf",
"shasum": ""
},
"require": {
@ -4944,7 +4948,7 @@
],
"description": "Symfony SwiftmailerBundle",
"homepage": "http://symfony.com",
"time": "2018-08-29T08:49:17+00:00"
"time": "2018-10-27T16:17:38+00:00"
},
{
"name": "symfony/templating",
@ -6108,16 +6112,16 @@
},
{
"name": "friendsofphp/php-cs-fixer",
"version": "v2.13.0",
"version": "v2.13.1",
"source": {
"type": "git",
"url": "https://github.com/FriendsOfPHP/PHP-CS-Fixer.git",
"reference": "7136aa4e0c5f912e8af82383775460d906168a10"
"reference": "54814c62d5beef3ba55297b9b3186ed8b8a1b161"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/7136aa4e0c5f912e8af82383775460d906168a10",
"reference": "7136aa4e0c5f912e8af82383775460d906168a10",
"url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/54814c62d5beef3ba55297b9b3186ed8b8a1b161",
"reference": "54814c62d5beef3ba55297b9b3186ed8b8a1b161",
"shasum": ""
},
"require": {
@ -6128,7 +6132,7 @@
"ext-tokenizer": "*",
"php": "^5.6 || >=7.0 <7.3",
"php-cs-fixer/diff": "^1.3",
"symfony/console": "^3.2 || ^4.0",
"symfony/console": "^3.4.17 || ^4.1.6",
"symfony/event-dispatcher": "^3.0 || ^4.0",
"symfony/filesystem": "^3.0 || ^4.0",
"symfony/finder": "^3.0 || ^4.0",
@ -6164,11 +6168,6 @@
"php-cs-fixer"
],
"type": "application",
"extra": {
"branch-alias": {
"dev-master": "2.13-dev"
}
},
"autoload": {
"psr-4": {
"PhpCsFixer\\": "src/"
@ -6200,7 +6199,7 @@
}
],
"description": "A tool to automatically fix PHP code style",
"time": "2018-08-23T13:15:44+00:00"
"time": "2018-10-21T00:32:10+00:00"
},
{
"name": "myclabs/deep-copy",
@ -6252,16 +6251,16 @@
},
{
"name": "nikic/php-parser",
"version": "v4.0.4",
"version": "v4.1.0",
"source": {
"type": "git",
"url": "https://github.com/nikic/PHP-Parser.git",
"reference": "fa6ee28600d21d49b2b4e1006b48426cec8e579c"
"reference": "d0230c5c77a7e3cfa69446febf340978540958c0"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/fa6ee28600d21d49b2b4e1006b48426cec8e579c",
"reference": "fa6ee28600d21d49b2b4e1006b48426cec8e579c",
"url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/d0230c5c77a7e3cfa69446febf340978540958c0",
"reference": "d0230c5c77a7e3cfa69446febf340978540958c0",
"shasum": ""
},
"require": {
@ -6277,7 +6276,7 @@
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "4.0-dev"
"dev-master": "4.1-dev"
}
},
"autoload": {
@ -6299,7 +6298,7 @@
"parser",
"php"
],
"time": "2018-09-18T07:03:24+00:00"
"time": "2018-10-10T09:24:14+00:00"
},
{
"name": "phar-io/manifest",
@ -6519,16 +6518,16 @@
},
{
"name": "phpunit/php-code-coverage",
"version": "6.0.8",
"version": "6.1.3",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/php-code-coverage.git",
"reference": "848f78b3309780fef7ec8c4666b7ab4e6b09b22f"
"reference": "4d3ae9b21a7d7e440bd0cf65565533117976859f"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/848f78b3309780fef7ec8c4666b7ab4e6b09b22f",
"reference": "848f78b3309780fef7ec8c4666b7ab4e6b09b22f",
"url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/4d3ae9b21a7d7e440bd0cf65565533117976859f",
"reference": "4d3ae9b21a7d7e440bd0cf65565533117976859f",
"shasum": ""
},
"require": {
@ -6539,7 +6538,7 @@
"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",
"sebastian/environment": "^3.1 || ^4.0",
"sebastian/version": "^2.0.1",
"theseer/tokenizer": "^1.1"
},
@ -6552,7 +6551,7 @@
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "6.0-dev"
"dev-master": "6.1-dev"
}
},
"autoload": {
@ -6578,7 +6577,7 @@
"testing",
"xunit"
],
"time": "2018-10-04T03:41:23+00:00"
"time": "2018-10-23T05:59:32+00:00"
},
{
"name": "phpunit/php-file-iterator",
@ -6771,16 +6770,16 @@
},
{
"name": "phpunit/phpunit",
"version": "7.3.5",
"version": "7.4.3",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/phpunit.git",
"reference": "7b331efabbb628c518c408fdfcaf571156775de2"
"reference": "c151651fb6ed264038d486ea262e243af72e5e64"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/7b331efabbb628c518c408fdfcaf571156775de2",
"reference": "7b331efabbb628c518c408fdfcaf571156775de2",
"url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c151651fb6ed264038d486ea262e243af72e5e64",
"reference": "c151651fb6ed264038d486ea262e243af72e5e64",
"shasum": ""
},
"require": {
@ -6801,11 +6800,11 @@
"phpunit/php-timer": "^2.0",
"sebastian/comparator": "^3.0",
"sebastian/diff": "^3.0",
"sebastian/environment": "^3.1",
"sebastian/environment": "^3.1 || ^4.0",
"sebastian/exporter": "^3.1",
"sebastian/global-state": "^2.0",
"sebastian/object-enumerator": "^3.0.3",
"sebastian/resource-operations": "^1.0",
"sebastian/resource-operations": "^2.0",
"sebastian/version": "^2.0.1"
},
"conflict": {
@ -6825,7 +6824,7 @@
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "7.3-dev"
"dev-master": "7.4-dev"
}
},
"autoload": {
@ -6851,7 +6850,7 @@
"testing",
"xunit"
],
"time": "2018-09-08T15:14:29+00:00"
"time": "2018-10-23T05:57:41+00:00"
},
{
"name": "sebastian/code-unit-reverse-lookup",
@ -7333,25 +7332,25 @@
},
{
"name": "sebastian/resource-operations",
"version": "1.0.0",
"version": "2.0.1",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/resource-operations.git",
"reference": "ce990bb21759f94aeafd30209e8cfcdfa8bc3f52"
"reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/ce990bb21759f94aeafd30209e8cfcdfa8bc3f52",
"reference": "ce990bb21759f94aeafd30209e8cfcdfa8bc3f52",
"url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/4d7a795d35b889bf80a0cc04e08d77cedfa917a9",
"reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9",
"shasum": ""
},
"require": {
"php": ">=5.6.0"
"php": "^7.1"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.0.x-dev"
"dev-master": "2.0-dev"
}
},
"autoload": {
@ -7371,7 +7370,7 @@
],
"description": "Provides a list of PHP built-in functions that operate on resources",
"homepage": "https://www.github.com/sebastianbergmann/resource-operations",
"time": "2015-07-28T20:34:47+00:00"
"time": "2018-10-04T04:07:39+00:00"
},
{
"name": "sebastian/version",
@ -7737,16 +7736,16 @@
},
{
"name": "symfony/maker-bundle",
"version": "v1.7.0",
"version": "v1.8.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/maker-bundle.git",
"reference": "22a9bf33868f0fed6cab013fe5231e8485d15e20"
"reference": "26643943fe19b5b47d620744907f09d1d6b3f06f"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/maker-bundle/zipball/22a9bf33868f0fed6cab013fe5231e8485d15e20",
"reference": "22a9bf33868f0fed6cab013fe5231e8485d15e20",
"url": "https://api.github.com/repos/symfony/maker-bundle/zipball/26643943fe19b5b47d620744907f09d1d6b3f06f",
"reference": "26643943fe19b5b47d620744907f09d1d6b3f06f",
"shasum": ""
},
"require": {
@ -7799,7 +7798,7 @@
"scaffold",
"scaffolding"
],
"time": "2018-08-30T01:08:06+00:00"
"time": "2018-10-13T19:56:32+00:00"
},
{
"name": "symfony/panther",

View File

@ -19,20 +19,13 @@
<testsuites>
<testsuite name="Integration Test Suite">
<directory>./integration/</directory>
<directory>./tests/integration/</directory>
</testsuite>
<testsuite name="Unit Test Suite">
<directory>./src/</directory>
<directory>./tests/unit/</directory>
<file>*Test.php</file>
</testsuite>
</testsuites>
<filter>
<whitelist>
<directory>./src/</directory>
</whitelist>
</filter>
<listeners>
<listener class="Symfony\Bridge\PhpUnit\SymfonyTestsListener" />
</listeners>

View File

@ -29,6 +29,10 @@ class UserTest extends TestCase
$this->user->setPassword(self::PASSWORD);
}
public function testConstructor():void{
$this->assertInstanceOf(UserInterface::class, new User());
}
public function testUsername(): void
{