diff --git a/plugins/test/specs/verboseOutput.js b/plugins/test/specs/verboseOutput.js new file mode 100644 index 00000000..04a4a4d9 --- /dev/null +++ b/plugins/test/specs/verboseOutput.js @@ -0,0 +1,17 @@ +/** + * @author Rob Taylor [manix84@gmail.com] + */ + +describe("verbose output plugin", function () { + var parser = new (require("jsdoc/src/parser")).Parser(), + plugin = require('plugins/verboseOutput'), + docSet; + + installPlugins(['plugins/verboseOutput'], parser); + docSet = jasmine.getDocSetFromFile("plugins/verboseOutput.js", parser); + + it("should log file names to console", function() { + var fileBegin = docSet.getByLongname("module:plugins/verboseOutput.handlers.fileBegin"); + expect(fileBegin[0].description).toEqual("Logging the file name to the console."); + }); +}); diff --git a/plugins/verboseOutput.js b/plugins/verboseOutput.js new file mode 100644 index 00000000..454a4a05 --- /dev/null +++ b/plugins/verboseOutput.js @@ -0,0 +1,15 @@ +/** + * Adds a verbose output to the console, so that you can see what's happening in your process. + * @module plugins/verboseOutput + * @author Rob Taylor - The basic idea + * @author Michael Mathews - Wrote the first itteration with me :) + */ + +exports.handlers = { + /** + * Logging the file name to the console. + */ + fileBegin: function (data) { + console.log(data.filename); + } +};