I am having problem with syncing changes on my test that I made in VSC and running it in cypress.
When I make change in test in VSC and open cypress and run it, in Chrome appears old test with no changes
Change was made in VSC and saved
Test is running without change
Related
I want to add E2E tests to my web extension, using cypress, and run them on a CI.
Is that even possible?
The tests pass locally on $ cypress open, but fail on $cypress run
The extension adds an element to the dom and cypress can't find it (the extension doesn't seem to get loaded in headless mode)
Here's a reproducible repo with the most simple one line test:
https://github.com/goldylucks/cypress-test-tiny
Using Visual Studio 2019, I have downloaded all the dependencies needed to run NodeJS scripts and all works well. I can only run each .js script from VS (Ctrl+F5), but I want to know whether its possible to run a series of scripts like I would normally do via command prompt using npm start, but in real-time through VS? It's very important to me that I do not modify any script file in order to make this work, but rather let VS do the job instead of npm start, if It's possible at all.
I already have a project setup which I can successfully run via command prompt with npm start, but can I run and debug it with VS?
My main goal is to get any console output and even use breakpoints, aka. properly debug my code.
Actually, in VS IDE, there is a default node js project template that Microsoft provided.
You only have to install the workload Node.js development on the vs_installer so that you can use that template.
I think you should create such project template which follows the rule of VS IDE with node.js. And then migrate your old project's content into this new project.
Note: in this project, there is no such easy way to start several js files at the same time unless you nest nested js methods in the starting js file. And other types of projects do the same.
If you want to debug other js files, you only need to right-click on the file on the Solution Explorer. Every time switch like this, you can debug other js files.
You do not have to use npm start in this way and just click Debug to debug the project.
I am not sure about Visual studio, but you can debug on Visual Studio Code.
you can debug from run menu.
I'm developing a very simple typescript project and I added a very tiny test with mocha. I installed mocha sidebar on VS Code and all it's dependencies, but test are not showing in the left panel.
The strange is that when I press debug button, my test run without problem (?)
I want to distribute this package on NPM, and only distribute .js, .d.ts, js.map and d.ts.map files.
I think the problem is in my project.json, but I cannot figure what is it. The source code is here
The only change I needed was in the VS code workspace settings: Under extensions I pointed the 'mocha glob files'-setting to my test scripts
One thing that I notice from your repo is you have package.json, test folder and another src folder inside type-exception/src.
I can run the mocha sidebar plugin successfully.
My solution is to open the project in vscode from the type-exception/src folder not type-exception folder.
My file structure
My mocha sidebar
I also saw that you have correct vscode workspace settings that set mocha files to
{
"mocha.files.glob": "lib/test/**/*.js"
}
Hope it helps
I had the Testing view showing Jest tests and realised that for Mocha I needed to install another VSCode Extension called "Mocha Test Explorer": https://marketplace.visualstudio.com/items?itemName=hbenl.vscode-mocha-test-adapter
Once installed I created/edited a .vscode/settings.json file in my project folder and added the following clues to tell Mocha to find my tests under the tests folder:
{
"mochaExplorer.files": "tests/**/*.ts"
}
I want to run a project which I developed with Node and ejs.
But there is a problem with the start file.
What musst I change.
If I start the project from the terminal everything goes fine.
I have an electron app, arbitrator. It uses electron-boilerplate as a base. Within that electron application, I have an icon specified in resources/icons/512x512.png. When I run the application using npm start, the icon shows up on the Gnome Unity bar.
If, however, I run npm run release, and then run cd dist/linux && ./Arbitrator, the application runs, but the icon doesn't show up in the Unity bar (just the default icon). Further, if I run the ./Arbitrator command from the source repository working directory, then it finds the resources/icons/512x512.png file and shows it in the unity bar.
Is there a way I can make sure that the icon is shown for the app, regardless of how it's run (it seems to be referencing the path for the icon locally, rather than using the asar file for resources).