Add doxygen testing of Java constructor wrappers
This commit is contained in:
parent
9cc05724ef
commit
602b0d5a2c
6 changed files with 20 additions and 4 deletions
|
|
@ -7,6 +7,7 @@
|
|||
struct DoxOuter {
|
||||
/** DoxOuter constructor */
|
||||
DoxOuter() {}
|
||||
/** DoxInner class description */
|
||||
struct DoxInner {
|
||||
/** DoxInner constructor */
|
||||
DoxInner() {}
|
||||
|
|
|
|||
|
|
@ -41,6 +41,7 @@ int someVar=42;
|
|||
*/
|
||||
#define CONSTANT_VALUE 4242
|
||||
|
||||
/// SomeAnotherClass description
|
||||
class SomeAnotherClass
|
||||
{
|
||||
public:
|
||||
|
|
|
|||
|
|
@ -34,6 +34,10 @@ public class CommentParser {
|
|||
if (f.getRawCommentText().length() > 0)
|
||||
m_parsedComments.put(f.qualifiedName(), f.getRawCommentText());
|
||||
}
|
||||
for (ConstructorDoc c : classDoc.constructors()) {
|
||||
if (c.getRawCommentText().length() > 0)
|
||||
m_parsedComments.put(c.toString(), c.getRawCommentText());
|
||||
}
|
||||
for (MethodDoc m : classDoc.methods()) {
|
||||
if (m.getRawCommentText().length() > 0)
|
||||
m_parsedComments.put(m.toString(), m.getRawCommentText());
|
||||
|
|
|
|||
|
|
@ -25,10 +25,12 @@ public class doxygen_nested_class_runme {
|
|||
|
||||
HashMap<String, String> wantedComments = new HashMap<String, String>();
|
||||
|
||||
// wantedComments.put("doxygen_nested_class.DoxOuter.DoxOuter()",
|
||||
// " DoxOuter constructor ");
|
||||
// wantedComments.put("doxygen_nested_class.DoxOuter.DoxInner.DoxInner()",
|
||||
// " DoxInner constructor ");
|
||||
wantedComments.put("doxygen_nested_class.DoxOuter()",
|
||||
" DoxOuter constructor ");
|
||||
wantedComments.put("doxygen_nested_class.DoxOuter.DoxInner",
|
||||
" DoxInner class description ");
|
||||
wantedComments.put("doxygen_nested_class.DoxOuter.DoxInner()",
|
||||
" DoxInner constructor ");
|
||||
wantedComments.put("doxygen_nested_class.DoxOuter.DoxInner.setDoxInt(int)",
|
||||
" doxInt variable ");
|
||||
wantedComments.put("doxygen_nested_class.DoxOuter.DoxInner.getDoxInt()",
|
||||
|
|
|
|||
|
|
@ -26,6 +26,12 @@ public class doxygen_parsing_runme {
|
|||
|
||||
HashMap<String, String> wantedComments = new HashMap<String, String>();
|
||||
|
||||
wantedComments.put("doxygen_parsing.SomeAnotherClass",
|
||||
" SomeAnotherClass description");
|
||||
wantedComments.put("doxygen_parsing.SomeAnotherClass(int)",
|
||||
" First overloaded constructor.");
|
||||
wantedComments.put("doxygen_parsing.SomeAnotherClass(java.lang.String)",
|
||||
" Second overloaded constructor.");
|
||||
wantedComments.put("doxygen_parsing.SomeAnotherClass.getClassAttr()",
|
||||
" The class attribute comment \n" +
|
||||
" \n" +
|
||||
|
|
|
|||
|
|
@ -11,6 +11,8 @@ comment_verifier.check(inspect.getdoc(doxygen_parsing.SomeClass),
|
|||
"The class comment")
|
||||
comment_verifier.check(inspect.getdoc(doxygen_parsing.SomeStruct),
|
||||
"The struct comment")
|
||||
comment_verifier.check(inspect.getdoc(doxygen_parsing.SomeAnotherClass),
|
||||
"SomeAnotherClass description")
|
||||
|
||||
# There doesn't seem to be any way to specify the doc string for __init__ when
|
||||
# using "-builtin" (see http://stackoverflow.com/q/11913492/15275), so skip
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue