KARATE, VScode : "Run Karate Test" codelens not displayed [duplicate] - visual-studio-code

This question already has an answer here:
Unable to use read('classpath:') when running tests with standalone karate.jar
(1 answer)
Closed 1 year ago.
Visual Studio Code 1.43.0
Karate Standalone JAR 0.9.5.RC5
In the VScode editor, in a Karate .feature file opened, the codelens "Run Karate Test", as shown in the screenshot, isn't displayed anymore.
So, it is impossible to debug a specific scenario.
Any idea about this?
Thanks a lot.
In a correct configuration, it looks like this :

We are still unable to reproduce this issue. Referencing some searches it appears this may be due to a broader issue such as other plugins Eg. Intellisense. Reference to the broader issues https://www.google.com/search?q=vscode+codelens+not+showing
I would recommend trying a clean install with only the Karate Plugin to do some process of elimination. The latest Karate Version is 0.8.1 by the way which it doesn't appear you are using. The Codelens names have changed recently to "Karate: Run" and "Karate: Debug".
Hope this helps.

Related

VSCode 'The file is in the program because: Default library for target 'es3''

I'm using VSCode. After the last update of the IDE, I see this error (Even if I didn't open any project to work on).
I googled it, and I tried several actions according to this link:
https://github.com/microsoft/TypeScript/issues/43838
but none of them seems to work.
Anyone faced the issue? (I'm not using TypeScript in any of my projects and I don't have any tsconfig.ts file). Is it related to one of my VSCode extensions?
It is a general update problem about visual-studio-code with the last update. Issue can be followed from here: https://github.com/microsoft/vscode/issues/168420
Installing JavaScript and TypeScript Nightly extension is helpful for me.
Configure .eslintrc.json in your folder again and reload the vs code
example:
.eslintrc.json file for salesforce
Or
you can refer below link to config your eslint file
https://eslint.org/docs/latest/user-guide/configuring/

Example of launching browser window via Playwright with Karate [duplicate]

This question already has an answer here:
How to get playwrightUrl of Docker container for Playwright (needed to integrate Karate scripts)?
(1 answer)
Closed 1 year ago.
Does anyone have a simple example of launching a browser window in a Karate .feature file using Playwright?
Preferable where the Playwright server is already started. I'm especially not clear on what parameters need to be included in the * configure driver = line.
Instructions are here: https://github.com/karatelabs/karate/tree/master/karate-core#playwright
If already started, you do need to know what the server URL is. Then the driver config would be something like this:
* configure driver = { type: 'playwright', start: false, playwrightUrl: '<change me>' }
It seems that newer versions of Playwright do allow you to set the server URL value to a "known" value when you start the server, see wsPath here: https://playwright.dev/docs/api/class-browsertype#browser-type-launch-server
Playwright support in Karate is still a bit experimental, so if you can report your findings here, that will help others.

Unable to start Karate debug server in Visual Studio Code, Windows 10 [duplicate]

This question already has an answer here:
Unable to use read('classpath:') when running tests with standalone karate.jar
(1 answer)
Closed 1 year ago.
I am trying to use Karate with Visual Studio Code. I have followed the instructions to set up Karate on VSC for Windows, with the robot and Karate Zip. I am able to run the examples in the zip when I run Karate directly. But when I try to debug using VS Code and the standalone jar I keep getting the error that the server cannot start because it times out. I have tried cleaning up VS Code and installing Karate plug in only, Java JRE 1.8 version, disabled the windows 10 firewall. I attach the error screenshots showing debug server timeout. I have tried Karate versions 0.9.6 and 0.9.9RC3 both with the same problem.
[enter image description here][1]
[enter image description here][2]
[enter image description here][3]
[1]: https://i.stack.imgur.com/tTEEM.png
[2]: https://i.stack.imgur.com/bULiN.png
[3]: https://i.stack.imgur.com/69T9T.png
either karate.jar is failing to create target\karate-debug-port.txt file or vscode extension is failing to detect it
check if file was created and/or what may be preventing this file to be created

Flutter driver Test Explorer

is there a way to get some kind of Flutter Test Explorer into the IntelliJ IDE?
I am thinking of something like JUnit has in Visual Studio. Let's say that it should be something like this. My tests are stored in Feature Files.
If yes please send me a link to an addon or tool.
Thanks.
EDIT 1:
I am talking about the tool which "sees" all feature files and scenarios in it before the run. User than can select which scenario will be executed from the list of scenarios.
If you run tests in IntelliJ you should see something very similar to what you have screen shotted above for VS. You may find if you're using a build tool (Gradle/Maven) that running tests defaults to using the build tool to do so but you can switch this back to IntelliJ alone. What are you currently seeing/not seeing in IntelliJ?
See https://www.jetbrains.com/help/idea/performing-tests.html for more info + screen shot very similar to VS.

Getting "Error: Failed to connect to OmniSharp"

I'm trying to get VSCode working with my Unity projects, and every time I select the Project icon (the little fire at the bottom) I get the following error:
Error: Failed to connect to OmniSharp
Is anyone else getting this?
You need to download the most recent version of "mono". Open up terminal and pass in brew install mono. Then "Pick a project" and select the ..-csharp.sln file and you should be up and running.
Ok, made some progress and gotten a few Unity projects working. It seems that you need some prerequisites installed, a clean up of your Unity project folder, and possibly some hand editing of your .sln and .csproj files.
I posted a (possibly) better answer over on Reddit. Hope that's not breaking stack etiquitte.
http://www.reddit.com/r/Unity3D/comments/34d6gc/visual_studio_for_mac_help_us_vote_for_unity/
i get this on windows when my project directory has a space in it
i removed the space and removed the error
i expect it will be fixed soom
I have a completely different answer: it's the runtime that VSCode is using. It doesn't match up with what it thinks it needs. I have to remember that we're still in beta and that things are changing rapidly. I had my dnvm running beta 7, but VSCode (and OmniSharp, by extension) is looking for beta 6, so it was failing. I updated my runtime using this this post as a clue. Now I have VSCode 0.7.0 using the beta 6 runtime. I have no idea how to tell what it's looking for...I just guessed based on when they were both released. HTH