Comments (7)
Your tests are in /var/www/html/tests
folder? The phpunit.xml
is configured to run tests in this folder correctly?
from vscode-phpunit.
Yes, the remote path is "/var/www/html/tests" and phpunit.xml is configured correctly.
The structure is as follows:
project:
- .vscode/
- docker/
- src/
----- app/
----- ...
----- tests/
----- phpunit.xml
In docker the "src" folder is mounted in "/var/www/html/".
settings:
"phpunit.phpunit": "/var/www/html/vendor/bin/phpunit",
"testExplorer.useNativeTesting": true,
"phpunit.files": "src/{test,tests,Test,Tests}/**/*Test.php",
"phpunit.remoteCwd": "/var/www/html",
"phpunit.relativeFilePath": true,
"phpunit.php": "/usr/bin/docker-compose exec -T blog ",
"phpunit.shell": "bash",
"phpunit.args": [
"--configuration ./phpunit.xml"
]
Trace:
[Trace - 12:51:38] Received notification 'TestRunFinishedEvent'.
Params: {
"command": {
"title": "PHPUnit LSP",
"command": "/usr/bin/docker-compose exec -T blog ",
"arguments": [
"/var/www/html/vendor/bin/phpunit",
"--configuration ./phpunit.xml",
"--filter",
"'/^.*::test_that_true_is_true.*$/'",
"src/tests/Unit/ExampleTest.php"
]
},
"events": [
{
"type": "test",
"test": "Tests\\Unit\\ExampleTest::test_that_true_is_true",
"state": "errored",
"message": "PHPUnit 9.5.21 #StandWithUkraine\n\nCannot open file \"src/tests/Unit/ExampleTest.php\".\n"
}
]
}
The file path should not begin with "src/"
from vscode-phpunit.
I made a fork of the original project and I have not had any problems, by the way I have modified the necessary and made a RP.
satiromarra@e87cec2
I made a fork of this project but whenever I test it I get nonsense errors.
With "npm install" I have to run "npm install --force" to install packages.
In debug mode "watch", "watch:server" or "watch:client" does not work with errors like:
- "TS2322: Type 'true' is not assignable to type 'Boolean | undefined'."
- "TS2345: Argument of type '(string | URL)[]' is not assignable to parameter of type 'string[]'."
Is there some configuration I'm setting wrong?
from vscode-phpunit.
I made a fork of the original project and I have not had any problems, by the way I have modified the necessary and made a RP. satiromarra@e87cec2
I made a fork of this project but whenever I test it I get nonsense errors.
With "npm install" I have to run "npm install --force" to install packages. In debug mode "watch", "watch:server" or "watch:client" does not work with errors like:
- "TS2322: Type 'true' is not assignable to type 'Boolean | undefined'."
- "TS2345: Argument of type '(string | URL)[]' is not assignable to parameter of type 'string[]'."
Is there some configuration I'm setting wrong?
Hello! I saw your PR so I belive you have managed to run the project, right? Let me see your PR #9 😄
from vscode-phpunit.
Hi, I have managed to copy the "node_modules" folders generated from the "recca0120" repository.
For some reason when I run "npm install" it installs "[email protected]" when "^3.0.0-prerelease.8" is specified in package.json.
In the original repository it has the same package however "npm install" installs the correct version.
The code is not perfect, but it can give you an idea of the changes (except for the indentation differences)
from vscode-phpunit.
I'll check the problem on install the npm dependencies soon! 😄 Thanks to report!
from vscode-phpunit.
If it helps:
$ npm --version
8.12.1
$ node --version
v18.4.0
Before clone this repo, I run:
$ npm install
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: [email protected]
npm ERR! Found: @types/[email protected]
npm ERR! node_modules/@types/jest
npm ERR! dev @types/jest@"^24.9.1" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peerOptional @types/jest@"^27.0.0" from [email protected]
npm ERR! node_modules/ts-jest
npm ERR! dev ts-jest@"^28.0.1" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: @types/[email protected]
npm ERR! node_modules/@types/jest
npm ERR! peerOptional @types/jest@"^27.0.0" from [email protected]
npm ERR! node_modules/ts-jest
npm ERR! dev ts-jest@"^28.0.1" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See ~/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! ~/.npm/_logs/2022-06-24T21_47_49_920Z-debug-0.log
from vscode-phpunit.
Related Issues (10)
- Using VSCode's native testing HOT 8
- Not working with Docker and WSL2 - Windows 10 - wrong path escaped HOT 23
- plugin inject wrong config file HOT 12
- "FAILURES!" = Pass HOT 2
- PHP server is crashing HOT 1
- phpunit.ssh setting not working HOT 1
- TypeError: Cannot read properties of undefined (reading 'loc') HOT 1
- Support ${workspaceRoot} in phpunit.phpunit setting HOT 2
- Repeated crashes of the language server HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vscode-phpunit.