This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Hi, in the project properties for the grunt builder (8.1RC(2)) you can "Assign IDE actions to Grunt tasks". There is e.g. Test File. I've setup a grunt task testfile:filename which needs the filename as parameter. What is the placeholder or variable in Netbeans for the filename? There is no user documentation available for this important information. Does anyone know the variables? Are there variables? I have not found any common syntax which would get replaced on execution. Thanks Markus
(In reply to capricious from comment #0) > What is the placeholder or variable in Netbeans for the filename? Just to be sure - can you please provide an example of such a Grunt task and what it does exactly? > Are there variables? No, none at the moment. Feel free to provide a list of possible variables, we could add them. Thanks for reporting.
Created attachment 156796 [details] Gruntfile.js With the attached Grunfile.js you can do something like... sh> grunt testfile:test/app/models/ratelimit.js Running "testfile:test/app/models/ratelimit.js" (testfile) task testfile: test/app/models/ratelimit.js Running "jshint:files" (jshint) task >> 2 files lint free. Running "mochaTest:test" (mochaTest) task synchronizing database n4vnewsletter_test synchronized database n4vnewsletter_test Ratelimit #update ✓ should increase blockcount (116ms) 1 passing (1s) Done, without errors. The 0before.js is the database setup needed for all of my tests. The task replaces the default file list with the 0before.js plus the one specified after the colon. So it would be nice to provide a variable with the currently active test file or the test file you would navigate to with Ctrl+Alt+T.