From dc5e6f093386967d07b8ec5e0064b12ea416ea2c Mon Sep 17 00:00:00 2001 From: mathematicalcoffee Date: Fri, 15 Feb 2013 13:21:02 +1000 Subject: [PATCH] @desc: added tests --- test/specs/tags/descriptiontag.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 test/specs/tags/descriptiontag.js diff --git a/test/specs/tags/descriptiontag.js b/test/specs/tags/descriptiontag.js new file mode 100644 index 00000000..4c004e75 --- /dev/null +++ b/test/specs/tags/descriptiontag.js @@ -0,0 +1,15 @@ +describe("@description tag", function() { + var doclet = require('jsdoc/doclet'), + doc = new doclet.Doclet('/** Blah Blah Blah\n @desc halb halb halb */', {}), + doc2 = new doclet.Doclet('/** @description lkjasdf */', {}); + + it("sets the doclet's 'description' property to the description", function() { + expect(doc2.description).toBeDefined(); + expect(doc2.description).toBe('lkjasdf'); + }); + + it("overrides the default description", function() { + expect(doc.description).toBeDefined(); + expect(doc.description).toBe('halb halb halb'); + }); +});