Do not install Symfony Flex - php

Everytime i run composer install it creates controller directory and adds kernel.php
I am not sure whats happening, i have doubt that symphony flex is doing something.
This kernel.php is of no use to me and due to this file, my app breaks
my composer.json
{
"name": "My App",
"description": "my app",
"keywords": ["app"],
"license": "MIT",
"type": "project",
"minimum-stability": "dev",
"prefer-stable": true,
"require": {
"php": ">=7.2.0"
},
"require-dev": {
"fzaninotto/faker": "~1.0",
"mockery/mockery": "~1.0",
"phpunit/phpunit": "~7.0",
"squizlabs/php_codesniffer": "~3.0",
"phpmd/phpmd": "~2.0",
"phing/phing": "~2.0",
"phpdocumentor/phpdocumentor": "~3.0",
"sebastian/phpcpd": "~4.0",
"phploc/phploc": "~4.0",
"vektah/bugfree-dangerzone": "~0.4",
"amnuts/opcache-gui": "~2.0",
"rlerdorf/opcache-status": "dev-master",
"peehaa/opcachegui": "master",
"friendsofphp/php-cs-fixer": "~2.0",
"johnkary/phpunit-speedtrap": "~3.0"
},
"autoload": {
"exclude-from-classmap": ["/tests/"],
"psr-4": {
"Entities\\": "src/Entities/",
"Helpers\\": "src/Helpers/",
"Factories\\": "src/Factories/",
"Repositories\\": "src/Repositories",
"Requests\\": "src/Requests/",
"Responses\\": "src/Responses/",
"UseCases\\": "src/UseCases/"
}
},
"autoload-dev": {
"psr-4": {
"TestHelpers\\": "tests/Helpers",
"UnitTest\\": "tests/Unit/"
}
},
"scripts": {
"post-root-package-install": [
"#php -r \"file_exists('.env') || copy('.env.example', '.env');\""
]
},
"config": {
"preferred-install": "dist",
"sort-packages": true,
"optimize-autoloader": true
}
}
kernel.php content
<?php
namespace App;
use Symfony\Bundle\FrameworkBundle\Kernel\MicroKernelTrait;
use Symfony\Component\Config\Loader\LoaderInterface;
use Symfony\Component\Config\Resource\FileResource;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\HttpKernel\Kernel as BaseKernel;
use Symfony\Component\Routing\RouteCollectionBuilder;
class Kernel extends BaseKernel
Also i get this on my terminal when i run composer update
- WARNING jms/serializer-bundle (>=2.0): From github.com/symfony/recipes-contrib:master
The recipe for this package comes from the "contrib" repository, which is open to community contributions.
Review the recipe at https://github.com/symfony/recipes-contrib/tree/master/jms/serializer-bundle/2.0
Do you want to execute this recipe?
[y] Yes
[n] No
[a] Yes for all packages, only for the current installation session
[p] Yes permanently, never ask again for this project
(defaults to n):
my tests break
PHPUnit 7.2.4 by Sebastian Bergmann and contributors.
Fatal error: Cannot declare class App\Kernel, because the name is already in use in /www/base_site/src/Kernel.php on line 12
Call Stack:
0.0003 393112 1. {main}() /www/base_site/vendor/phpunit/phpunit/phpunit:0
0.0488 2886864 2. PHPUnit\TextUI\Command::main() /www/base_site/vendor/phpunit/phpunit/phpunit:53
0.0488 2886976 3. PHPUnit\TextUI\Command->run() /www/base_site/vendor/phpunit/phpunit/src/TextUI/Command.php:156
0.2294 7201648 4. PHPUnit\TextUI\TestRunner->doRun() /www/base_site/vendor/phpunit/phpunit/src/TextUI/Command.php:203
0.2886 7750008 5. PHPUnit\Framework\TestSuite->run() /www/base_site/vendor/phpunit/phpunit/src/TextUI/TestRunner.php:566
0.2959 7759160 6. PHPUnit\Framework\TestSuite->run() /www/base_site/vendor/phpunit/phpunit/src/Framework/TestSuite.php:776
0.3043 7759760 7. UnitTest\Entity\AccountTest->run() /www/base_site/vendor/phpunit/phpunit/src/Framework/TestSuite.php:776
0.3044 7759760 8. PHPUnit\Framework\TestResult->run() /www/base_site/vendor/phpunit/phpunit/src/Framework/TestCase.php:805
0.3053 7773536 9. SebastianBergmann\CodeCoverage\CodeCoverage->start() /www/base_site/vendor/phpunit/phpunit/src/Framework/TestResult.php:606
0.3053 7773536 10. SebastianBergmann\CodeCoverage\CodeCoverage->initializeData() /www/base_site/vendor/phpunit/php-code-coverage/src/CodeCoverage.php:243
0.3287 8329976 11. include_once('/www/base_site/src/Kernel.php') /www/base_site/vendor/phpunit/php-code-coverage/src/CodeCoverage.php:948
Process finished with exit code 255
Is there anyway to resolve this issue?

Related

Neither command is working at app/console in symfony 2.8

I'm working on symfony 2.8 project and I'm new in it. Now I try to upgrade it to the newest version. I found the rector package for update the symfony (rector-prefixed exactly, for older version). I've install it and try to run like it is in documentation: https://github.com/rectorphp/rector, and got this error in the console:
'vendor' is not recognized as an internal or external command,
operable program or batch file.
I've don't found any information about errors like this so I think it could be a problem connect with console error. When I try to write any command for example:
php app/console list
I've got this exception back:
#!/usr/bin/env php
[Symfony\Component\Console\Exception\LogicException]
An option named "connection" already exists.
I don't know exactly where to looking for a problem. I will add my console file code and composer.json, maybe someone have same problem as me.
#!/usr/bin/env php
<?php
use Symfony\Bundle\FrameworkBundle\Console\Application;
use Symfony\Component\Console\Input\ArgvInput;
use Symfony\Component\Debug\Debug;
// if you don't want to setup permissions the proper way, just uncomment the following PHP line
// read https://symfony.com/doc/current/setup.html#checking-symfony-application-configuration-and-setup
// for more information
//umask(0000);
set_time_limit(0);
require __DIR__.'/autoload.php';
$input = new ArgvInput();
$env = $input->getParameterOption(array('--env', '-e'), getenv('SYMFONY_ENV') ?: 'dev');
$debug = getenv('SYMFONY_DEBUG') !== '0' && !$input->hasParameterOption(array('--no-debug', '')) && $env !== 'prod';
if ($debug) {
Debug::enable();
}
$kernel = new AppKernel($env, $debug);
$application = new Application($kernel);
$application->run($input);
{
"name": "symfony/framework-standard-edition",
"license": "MIT",
"type": "project",
"description": "The \"Symfony Standard Edition\" distribution",
"autoload": {
"psr-4": {
"Tixi\\": "src/Tixi/"
},
"classmap": [ "app/AppKernel.php", "app/AppCache.php" ]
},
"autoload-dev": {
"files": [ "vendor/symfony/symfony/src/Symfony/Component/VarDumper/Resources/functions/dump.php" ]
},
"require": {
"php": "~7.4",
"ext-json": "*",
"apy/breadcrumbtrail-bundle": "1.3.*",
"composer/ca-bundle": "~1.2.7",
"doctrine/doctrine-bundle": "~1.4",
"doctrine/doctrine-migrations-bundle": "1.3.*",
"doctrine/orm": "^2.4.8",
"egulias/email-validator": "~1.2",
"friendsofsymfony/oauth-server-bundle": "1.5.*",
"friendsofsymfony/rest-bundle": "1.7.*",
"incenteev/composer-parameter-handler": "~2.0",
"jms/serializer-bundle": "1.5.*",
"knplabs/knp-snappy-bundle": "1.5.*",
"mediaburst/clockworksms": "2.0.*",
"sensio/distribution-bundle": "~4.0",
"sensio/framework-extra-bundle": "^3.0.2",
"symfony/monolog-bundle": "^3.0.2",
"symfony/swiftmailer-bundle": "~2.3,>=2.3.10",
"symfony/symfony": "2.8.*",
"twig/extensions": "1.5.*",
"twig/twig": "^1.0||^2.0"
},
"require-dev": {
"rector/rector-prefixed": "^0.9.31",
"sensio/generator-bundle": "~3.0",
"symfony/phpunit-bridge": "~2.7"
},
"scripts": {
"symfony-scripts": [
"Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::buildBootstrap",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::clearCache",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installAssets",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installRequirementsFile",
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::prepareDeploymentTarget"
],
"post-install-cmd": [
"#symfony-scripts"
],
"post-update-cmd": [
"#symfony-scripts"
]
},
"config": {
"bin-dir": "bin",
"platform": {
"php": "7.4"
},
"sort-packages": true,
"discard-changes": true
},
"extra": {
"symfony-app-dir": "app",
"symfony-web-dir": "web",
"symfony-assets-install": "relative",
"incenteev-parameters": {
"file": "app/config/parameters.yml"
},
"branch-alias": {
"dev-master": "2.8-dev"
}
}
}
I solved already the problem. First the problem with Rector was with the command. I don't know exactly why but normal command don't work with my project. In Rector documentation there is:
vendor/bin/rector
command but in my project there works only:
php bin/rector
So this problem was solved. Next I have an issue with any other command form command line. There was a Logic exception. But I handle with this after upgrade the Symfony from 2.8 to 3.x. So I think there was conflict between the oldest version of Symfony and the php 7.4 version.

Laravel Error Call to undefined method Pelago\Emogrifier::disableInvisibleNodeRemoval()

I was cloning our laravel web-api project in gitlab. Then I want to migrate and serve in order to test the api's in postman. But when I do a migrate or serve, there is an error
In CssInlinerPlugin.php line 18:
Call to undefined method Pelago\Emogrifier::disableInvisibleNodeRemoval()
Can someone help me with this? I dont know how to solve this because even google doesnt have an answer. Thanks in advance.
CssInlinerPlugin.php
<?php
namespace Snowfire\Beautymail;
class CssInlinerPlugin implements \Swift_Events_SendListener
{
/**
* #var \Pelago\Emogrifier
*/
protected $inliner;
/**
* Initialize the CSS inliner.
*/
public function __construct()
{
$this->inliner = new \Pelago\Emogrifier();
$this->inliner->disableInvisibleNodeRemoval();
}
/**
* Inline the CSS before an email is sent.
*
* #param \Swift_Events_SendEvent $evt
*/
public function beforeSendPerformed(\Swift_Events_SendEvent $evt)
{
$message = $evt->getMessage();
$properTypes = [
'text/html',
'multipart/alternative',
'multipart/mixed',
];
if ($message->getBody() && in_array($message->getContentType(), $properTypes)) {
$this->inliner->setHtml($message->getBody());
$message->setBody($this->inliner->emogrify());
}
foreach ($message->getChildren() as $part) {
if (strpos($part->getContentType(), 'text/html') === 0) {
$this->inliner->setHtml($part->getBody());
$message->setBody($this->inliner->emogrify());
}
}
}
/**
* Do nothing.
*
* #param \Swift_Events_SendEvent $evt
*/
public function sendPerformed(\Swift_Events_SendEvent $evt)
{
// Do Nothing
}
}
Composer.json
{
"name": "laravel/laravel",
"description": "The Laravel Framework.",
"keywords": ["framework", "laravel"],
"license": "MIT",
"type": "project",
"require": {
"php": ">=7.0.0",
"fideloper/proxy": "~3.3",
"guzzlehttp/guzzle": "^6.3",
"laravel/framework": "5.5.*",
"laravel/passport": "^4.0",
"laravel/tinker": "~1.0",
"laravelcollective/html": "^5.5",
"maatwebsite/excel": "~2.1.0",
"nexmo/laravel": "^1.0",
"pusher/pusher-http-laravel": "^4.0",
"pusher/pusher-php-server": "^3.0",
"pusher/pusher-push-notifications": "1.0",
"snowfire/beautymail": "dev-master"
},
"require-dev": {
"filp/whoops": "~2.0",
"fzaninotto/faker": "~1.4",
"mockery/mockery": "0.9.*",
"phpunit/phpunit": "~6.0"
},
"autoload": {
"classmap": [
"database/seeds",
"database/factories"
],
"psr-4": {
"App\\": "app/"
}
},
"autoload-dev": {
"psr-4": {
"Tests\\": "tests/"
}
},
"extra": {
"laravel": {
"dont-discover": [
]
}
},
"scripts": {
"post-root-package-install": [
"#php -r \"file_exists('.env') || copy('.env.example', '.env');\""
],
"post-create-project-cmd": [
"#php artisan key:generate"
],
"post-autoload-dump": [
"Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
"#php artisan package:discover"
]
},
"config": {
"preferred-install": "dist",
"sort-packages": true,
"optimize-autoloader": true
}
}
When i do composer install
$ composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Nothing to install or update
Package phpoffice/phpexcel is abandoned, you should avoid using it. Use phpoffice/phpspreadsheet instead.
Package phpunit/phpunit-mock-objects is abandoned, you should avoid using it. No replacement was suggested.
Generating optimized autoload files
Carbon 1 is deprecated, see how to migrate to Carbon 2.
https://carbon.nesbot.com/docs/#api-carbon-2
You can run ".\vendor\bin\upgrade-carbon" to get help in updating carbon and other frameworks and libraries that depend on it.
> Illuminate\Foundation\ComposerScripts::postAutoloadDump
> #php artisan package:discover
In CssInlinerPlugin.php line 18:
Call to undefined method Pelago\Emogrifier::disableInvisibleNodeRemoval()
Script #php artisan package:discover handling the post-autoload-dump event returned with error code 1
It looks like that package has an open issue for this: https://github.com/Snowfire/Beautymail/issues/111
They list a couple solutions here. Maybe try to change the version to 2.2.0?

class not found with composer autoloader

I have this in my composer.json
{
"name": "laravel/laravel",
"description": "The Laravel Framework.",
"keywords": ["framework", "laravel"],
"license": "MIT",
"type": "project",
"require": {
"php": ">=7.0.0",
"alchemy/zippy": "^0.4.8",
"barryvdh/laravel-debugbar": "^3.1",
"fideloper/proxy": "~3.3",
"graham-campbell/exceptions": "^10.0",
"intervention/image": "^2.4",
"intervention/imagecache": "^2.3",
"laravel/framework": "5.5.*",
"laravel/tinker": "~1.0",
"laravelcollective/html": "^5.5",
"symfony/dom-crawler": "^3.3"
},
"files": [
"vendor/redbutton/text-image-alpha/vendor/autoload.php"
],
"require-dev": {
"filp/whoops": "^2.1",
"fzaninotto/faker": "~1.4",
"mockery/mockery": "0.9.*",
"phpunit/phpunit": "~6.0"
},
"autoload": {
"classmap": [
"database/seeds",
"database/factories"
],
"psr-4": {
"App\\": "app/"
}
},
"autoload-dev": {
"psr-4": {
"Tests\\": "tests/"
}
},
"extra": {
"laravel": {
"dont-discover": [
]
}
},
"scripts": {
"post-root-package-install": [
"#php -r \"file_exists('.env') || copy('.env.example', '.env');\""
],
"post-create-project-cmd": [
"#php artisan key:generate"
],
"post-autoload-dump": [
"Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
"#php artisan package:discover"
]
},
"config": {
"preferred-install": "dist",
"sort-packages": true,
"optimize-autoloader": true
}
}
The php files for my package are in a laravel installation:
/vendor/redbutton/text-image-alpha/src/
When I try to call a file I get the message:
Class 'Class 'RedButton\TextImageAlpha\TextImageAlpha' not found' not found
I use this to try and call the class:
$image = new \RedButton\TextImageAlpha\TextImageAlpha( 'some string' );
The file in /vendor/redbutton/text-image-alpha/src/TextImageAlpha.php looks like this:
<?php
namespace RedButton\TextImageAlpha;
use RedButton\TextImageAlpha\Exceptions;
use RedButton\Tools\Objects;
/**
* TextImageAlpha class convert a text to image.
*
* #author Tomas Rathouz <trathouz at gmail.com>
*/
class TextImageAlpha
{
// lots of code
}
This is my first composer package and I don't really have an idea of what is going wrong here. Could someone please explain to me what I'm doing wrong?
Good news. I've looked at your package at Bitbucket and you're doing it right in its composer.json:
Drop unnecessary code from composer.json
I've noticed in pasted composer.json there is manual adding of some vendor file.
"files": [
"vendor/redbutton/text-image-alpha/vendor/autoload.php"
],
/vendor nested in /vendor doesn't make sense as it might duplicate autoloading and break it.
Also I don't see redbutton/text-image-alpha in require section, where it should be.
How to add package the right way?
To install your package just call composer:
composer require redbutton/text-image-alpha
And that's it.
It should appear in require section in composer.json. Composer will autoload it by rules in composer.json of the package - here.
Test
I've tried following code and class is found correctly:
<?php
require __DIR__ . '/vendor/autoload.php';
$image = new \RedButton\TextImageAlpha\TextImageAlpha('some string');
var_dump($image);
Having composer.json:
{
"require": {
"redbutton/text-image-alpha": "^1.0"
}
}

Laravel - Call to undefined method Illuminate\Foundation\Application::share()

I am upgrading from Laravel 5.3 to Laravel 5.4. Problem is that when I run composer update and when it comes to php artisan optimize part, I get an error:
[Symfony\Component\Debug\Exception\FatalErrorException]
Call to undefined method Illuminate\Foundation\Application::share()
I've read a couple of questions here on StackOverflow and the answer is to replace this share method with singleton. But where can I find this share()?
EDIT
My composer.json file:
"name": "laravel/laravel",
"description": "The Laravel Framework.",
"keywords": ["framework", "laravel"],
"license": "MIT",
"type": "project",
"require": {
"php": ">=5.6.4",
"laravel/framework": "5.4.*",
"sngrl/sphinxsearch": "dev-master",
"laravelcollective/html": "5.4.*",
"aws/aws-sdk-php-laravel": "~3.0",
"league/flysystem-aws-s3-v3": "^1.0",
"mcamara/laravel-localization": "1.2.*",
"league/csv": "^8.2",
"mikehaertl/phpwkhtmltopdf": "^2.2",
"barryvdh/laravel-snappy": "^0.3.3",
"wemersonjanuario/wkhtmltopdf-windows": "dev-master",
"nesbot/carbon": "^1.22",
"uxweb/sweet-alert": "^1.4",
"laracasts/flash": "^2.0",
"guzzlehttp/guzzle": "^6.2",
"illuminate/support": "5.4.*",
"laravel/scout": "^3.0"
},
"require-dev": {
"fzaninotto/faker": "~1.4",
"mockery/mockery": "0.9.*",
"phpunit/phpunit": "~5.7",
"symfony/css-selector": "3.1.*",
"symfony/dom-crawler": "3.1.*"
},
"autoload": {
"classmap": [
"database"
],
"psr-4": {
"App\\": "app/"
}
},
"autoload-dev": {
"classmap": [
"tests/TestCase.php"
]
},
"scripts": {
"post-root-package-install": [
"php -r \"file_exists('.env') || copy('.env.example', '.env');\""
],
"post-create-project-cmd": [
"php artisan key:generate"
],
"post-install-cmd": [
"Illuminate\\Foundation\\ComposerScripts::postInstall",
"php artisan optimize"
],
"post-update-cmd": [
"Illuminate\\Foundation\\ComposerScripts::postUpdate",
"php artisan optimize"
]
},
"config": {
"preferred-install": "dist"
}
}
Project Share() method file is the Following Path:
Your Project >> Vendor >> laravel >> framework >> src >> Illuminate >> Container >> Container.php
Comment your share() method code and put below code.
public function singleton($abstract, $concrete = null)
{
$this->bind($abstract, $concrete, true);
}

PHPUnit Test Failing - 'PHPUnit\Framework\Assert' not found

Laravel project, simple test, only tries to load the default page '/'
SIMPLE TEST
<?php
namespace Tests\Feature;
use Tests\TestCase;
use Illuminate\Foundation\Testing\WithoutMiddleware;
use Illuminate\Foundation\Testing\DatabaseMigrations;
use Illuminate\Foundation\Testing\DatabaseTransactions;
class ExampleTest extends TestCase
{
/**
* A basic test example.
*
* #return void
*/
public function testBasicTest()
{
$response = $this->get('/');
$response->assertStatus(200);
}
}
ERROR MESSAGE via PhpStorm
Class 'PHPUnit\Framework\Assert' not found
/var/www/vhosts/app-native/app-app/vendor/laravel/framework/src/Illuminate/Foundation/Testing/TestResponse.php:52
/var/www/vhosts/app-native/app-app/tests/Feature/ExampleTest.php:21
ERROR MESSAGE via CLI
# php vendor/phpunit/phpunit/phpunit
PHPUnit 5.6.4 by Sebastian Bergmann and contributors.
EEE.. 5 / 5 (100%)
Time: 1.78 seconds, Memory: 16.00MB
There were 3 errors:
1) Tests\Feature\ExampleTest::testBasicTest
Error: Class 'PHPUnit\Framework\Assert' not found
/var/www/vhosts/app-native/app-app/vendor/laravel/framework/src/Illuminate/Foundation/Testing/TestResponse.php:52
/var/www/vhosts/app-native/app-app/tests/Feature/ExampleTest.php:21
2) Tests\Feature\JsonTest::testSignup
Error: Class 'PHPUnit\Framework\Assert' not found
/var/www/vhosts/app-native/app-app/vendor/laravel/framework/src/Illuminate/Foundation/Testing/TestResponse.php:52
/var/www/vhosts/app-native/app-app/tests/Feature/JsonTest.php:29
3) Tests\Feature\RoutesTest::testBasicTest
Error: Class 'PHPUnit\Framework\Assert' not found
/var/www/vhosts/app-native/app-app/vendor/laravel/framework/src/Illuminate/Foundation/Testing/TestResponse.php:52
/var/www/vhosts/app-native/app-app/tests/Feature/RoutesTest.php:21
ERRORS!
Tests: 5, Assertions: 2, Errors: 3.
Upon further investigation...
The Assert class is not found via the IDE either.
Looking into the composer autoloader, the only PHPUnit\Framework classes being loaded is the "ForwardCompatibility/TestCase ???!!!
3285'PHPUnit\\Framework\\TestCase' => $vendorDir . '/phpunit/phpunit/src/ForwardCompatibility/TestCase.php',
3825'PHPUnit\\Framework\\TestCase' => __DIR__ . '/..' . '/phpunit/phpunit/src/ForwardCompatibility/TestCase.php',
Here is my composer file, for good measure...
{
"name": "app/webapp",
"description": "app Web App (API & Frontend).",
"keywords": ["framework", "laravel"],
"license": "MIT",
"type": "project",
"require": {
"php": ">=5.6.4",
"laravel/framework": "5.4.*",
"laravel/tinker": "~1.0",
"laravelcollective/html": "~5.0",
"laracasts/flash": "~1.3",
"maatwebsite/excel": "~2.1",
"guzzlehttp/guzzle": "~6.2",
"doctrine/dbal": "~2.5",
"laravel/cashier": "~7.0",
"league/flysystem-aws-s3-v3": "~1.0",
"zizaco/entrust": "1.7.0",
"barryvdh/laravel-ide-helper": "^2.2",
"blueimp/jquery-file-upload": "^9.14",
"ipunkt/laravel-analytics": "^1.3",
"braintree/braintree_php": "^3.21",
"tymon/jwt-auth": "0.5.*",
"f2m2/apidocs": "~2.0",
"barryvdh/laravel-cors": "0.8.*",
"pulkitjalan/geoip": "~2.4",
"aws/aws-sdk-php-laravel": "^3.1",
"vsmoraes/laravel-pdf": "^1.0",
"propaganistas/laravel-phone": "^2.8",
"activecampaign/api-php": "~2.0"
},
"require-dev": {
"fzaninotto/faker": "~1.4",
"mockery/mockery": "0.9.*",
"phpunit/phpunit": "~5",
"phpspec/phpspec": "~2.1",
"ozankurt/repoist": "^1.0",
"symfony/dom-crawler": "~3.1",
"symfony/css-selector": "~3.1"
},
"autoload": {
"classmap": [
"database"
],
"psr-4": {
"App\\": "app/"
}
},
"autoload-dev": {
"psr-4": {
"Tests\\": "tests/"
}
},
"scripts": {
"post-root-package-install": [
"php -r \"file_exists('.env') || copy('.env.example', '.env');\""
],
"post-create-project-cmd": [
"php artisan key:generate"
],
"post-install-cmd": [
"Illuminate\\Foundation\\ComposerScripts::postInstall",
"php artisan ide-helper:generate",
"php artisan ide-helper:meta",
"php artisan optimize"
],
"post-update-cmd": [
"Illuminate\\Foundation\\ComposerScripts::postUpdate",
"php artisan ide-helper:generate",
"php artisan ide-helper:meta",
"php artisan optimize"
]
},
"config": {
"preferred-install": "dist",
"sort-packages": true
}
}
Upgrading to PhpSpec 3 will solve your dependency problem.
Older versions of PhpSpec can't be installed alongside very recent versions of PHPUnit, as they both require different versions of sebastian/exporter.

Categories