prashaantt / node-tdd Goto Github PK
View Code? Open in Web Editor NEWVS Code TDD extension for Node and JavaScript
Home Page: https://marketplace.visualstudio.com/items?itemName=prashaantt.node-tdd
License: MIT License
VS Code TDD extension for Node and JavaScript
Home Page: https://marketplace.visualstudio.com/items?itemName=prashaantt.node-tdd
License: MIT License
Hello Prashaantt, your plugin is amazing! I would like to integrate code test coverage, what would be your prefered choice and your configuration to make it work in vscode.
First of all:
Thanks for the great plug-in. This will ease my daily work ๐
Unfortunately when setting the glob to something like:
"nodeTdd.glob": "{src,spec}/**/*.{js,ts,jsx,tsx}"
The '**' will only match exactly one folder level. Not more, not less. I would have assumed that it'd find spec files in sub folders as and in the spec
and src
folders as well.
I am running code on Windows. Is this an expected/known behavior?
Please also check following visualization:
spec
|-- spec1.js // changes here will be ignored
|-- folder
|---- spec2.js // changes here will trigger new test run
|---- anotherFolder
|----------- spec3.js // changes here will be ignored
I've stumbled upon this extension and my first impression was: Wow! Awesome idea! Unfortunately, it works really weird as of a TDD-helper.
TDD is about iterating on a single unit, so it's completely useless and a waste of time to run whole test suite on a single test/implementation change - that's not TDD, that's regression checking if your change did not affect other parts of the system. IMO it should only work just for the opened file.
Any reasons why this went the way it went? And are there any plans to make it work on single files?
It would be nice to have a terminal instead of the output when toggle the status, because of the current vscode limitation about colors on the output window:
See here:
microsoft/vscode#243
Check out the comment from bartlewis he says how to open a new terminal by sending a command to execute.
This would be great to see the colors on the tests reports, which are very important.
All three statusbaritems have a different priority (2, 1 and 0). This conflicts with other extensions that add statusbaritems with a certain priority.
I would suggest keeping the priority the same for all items, so they stay together. This might still cause issues because the statusbaritems are added/removed based on available info. I would suggest creating them once, and leaving them. That way, they will always stay together.
I often consult to the results of my tests, making changes to multiple files before being satisfied that I've fixed a test failure. However after I save the first file I change, the entire build starts over, which takes a while.
If that seems extreme, maybe a compromise could be that it could be a setting, or perhaps it could ask you if you want to build again.
Maybe you could allow the user to specify which command to execute for a test and also take a filepath that just contains a coverage value ("87.95") and then use those values to output the data. that way one could write wrappers for any language/framework and use it very easily. the extension itself is really beautiful so it would be a shame not being able to use it because of other languages.
Hi @prashaantt ,
I have Visual Studio Code v1.15.1 with Node TDD plugin. I can see the symbol in status bar which means that it is activated. However, it is not getting invoked at all. Am I missing something? It is not very clear from project readme.
Thanks,
Sanjeev
I've only recently found node-tdd and I've got to say, this might just change how i develop software.
I would however like to see an option to display failed builds in a more visual manner.
If a build is successful the green check-mark is absolutely enough, but when a build fails i want to know about it immediately and spectacularly (on my 4k laptop display the little "Failing" text is about 4mm (0.15") tall).
It doesn't even have to be that fancy to begin with, just allowing for a verbose output if the build fails would be enough.
Really excited about this extension. However I have yet to get it to work. I opened a typescript workspace with a package.json and nothing happens. Here are some things I have observed:
I would love to supply some logs or some debug information if you can point me where to find them.
I run my tests with AVA, but I never see the status bar update.
No output in the console under TDD.
Thanks.
I currently run my node app in a docker container and have custom make commands to run tests inside the container. I love the TDD extension in my non-docker apps and I would love to use it docker apps too. Adding the ability to be able to use docker-compose run npm/yarn test
would be great
Istanbul is being re-written as nyc, whose default output is currently not being parsed by node-tdd.
This messages appears "package.json was not found" while a package.json is located in my project root folder.
Hello,
I have been waiting to use your plug-in. It seems like just the tool that I need for my serverless development. When I first installed it, I saw it per your video in the status bar. However, now that I want to use it, it is not there. I have tried to uninstall, reinstall, etc and I can get it installed but it doesn't show up. I have checked that it is enabled, etc as well and it is. If you have any insight as to why it would not be in the status bar anymore I would greatly appreciate it. I will attach a few screenshots below for your reference.
What the status bar looks like:
Looking forward to fixing this soon!
Cheers,
Ryan
When I run my tests in karma, and don't enable the --single-run
flag, node-tdd does not close the process before running the next test, resulting in multiple node processes that does not shut down, even when closing vscode.
When I activate the extension nothing happens except the text building... keeps rolling over and over.
The npm script that is refered in setting works manually. When I look at output for the extension there is none.
Any help would be super nice!
Hey @prashaantt! Gotta say, I love your plugin and I use it every day! ๐
The only thing that I think could be improved is that it would be really nice if clicking on the "Building..." label would simply show you the progress of the build (as clicking on "Passing" does), rather than canceling the build.
I find that I want to see the progress of the build much more often than I want to cancel the build.
The behavior for canceling the build could still be preserved. Perhaps there could be a small X icon to cancel the build that would show only while the build was, ah, building. ๐
Anyway, again this plugin is great. Simple and effective. Thanks for your work!
The results are not displayed in the status bar. I have restarted everything NodeTDD extension, VS Code and Laptop.
I am using the following :
Zipped Project Folder is also attached for reference :
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.