Asked  1 Year ago    Answers:  5   Viewed   34 times

i'm having trouble getting phpunit working inside of a symfony project in phpstorm - phpunit -c app works fine in the osx terminal.

here is the error:

unable to attach test reporter to test framework of test framework quit unexpectedly
/applications/mamp/bin/php/php5.4.4/bin/php/private/var/folders/4l/hw8g4qlj6nnc37lfkc6hcj7w0000gn/t/ide-phpunit.php --bootstrap
/users/greg/repos/myapp/app/bootstrap.php.cache --configuration    

testing started at 11:45 am ...

process finished with exit code 255

edit: here is the error from the php log:

fatal error: uncaught exception 'invalidargumentexception' with message 'the "app/" directory does not exist.' in /users/greg/repos/myapp/vendor/symfony/symfony/src/symfony/component/finder/finder.php:650



i ran into the same issue and found the following solution in the documentation:

to run your functional tests, the webtestcase class bootstraps the kernel of your application. in most cases, this happens automatically. however, if your kernel is in a non-standard directory, you'll need to modify your phpunit.xml.dist file to set the kernel_dir environment variable to the directory of your kernel:

    <!-- ... -->
        <server name="kernel_dir" value="/path/to/your/app/" />
    <!-- ... -->

so check your phpunit.xml.dist configuration file and try to add the absolute path to your app-directory.

hope it helps.

Friday, July 30, 2021

i execute the test of the other vendor of my project with this configuration:


    <testsuite name="project test suite">

hope this help

Thursday, April 1, 2021

on mac os x environment variables available in terminal and for the normal applications can be different, check the related question for the solution how to make them similar.

note that this solution will not work on mountain lion (10.8).

Saturday, May 29, 2021

you didn't provide us any information that we can use to debug your problem.

so i'm posting generic instructions to debug issues with a "sign tool".

  1. try command-line compiler (iscc.exe). it will preserve a full signtool.exe error message in the output:

  2. or temporarily prefix the sign tool command with cmd.exe /k to preserve its output even when compiling in inno setup gui compiler. e.g.:

     cmd.exe /k c:pathtosigntool.exe sign /f c:mykey.pfx $f

    note that if you use a path to signtool.exe with spaces, due to the way cmd works, you have to wrap not only the path itself to double quotes, but also the whole command:

     cmd.exe /k ""c:path to signtoolsigntool.exe" sign /f c:mykey.pfx $f"

see also signtool fail with inno setup with exit code 0x1.

Thursday, June 3, 2021

ecma 335 assemblies need to have a version number. but the windows runtime type resolution algorithm doesn't use the version number, so the team creating the winmd format chose an arbitrary version number of for the assembly version number.

that helps to ensure that nobody attempts to use the .net type resolution algorithm when doing type resolution (it's not perfect, unfortunately some tools still use the .net type resolution algorithm).

oh and the mscorlib reference is a pro-forma reference - ecma 335 requires that all typeref's have a corresponding assemblyref and the winmd file format chose to use typerefs to certain ecma 335 types as indicators of a specific type. for example, the winrt "enum" construct is represented as a type which extends "system.enum" - for a winmd file the "system.enum" part is just a string (it could have been anything), and cannot be resolved to a real type. that string is represented in metadata as a typeref and typerefs have to have an assemblyref - we chose to use the mscorlib version of system.enum as the assemblyref for the enum because it was convenient.

Friday, November 5, 2021
Only authorized users can answer the question. Please sign in first, or register a free account.
Not the answer you're looking for? Browse other questions tagged :