facebook

XDoclet mock object support

  1. MyEclipse IDE
  2.  > 
  3. Feature Requests
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #267520 Reply

    erjablow
    Member

    XDoclet offers a <mockobjectdoclet> task and a @mock.generate tag that creates mock object classes that implement tagged interfaces. See Ch. 10 of XDoclet in Action. However, I see no way to add this to the MyEclipse XDoclet configurations, at least in 5.1.1GA. Could someone add this to an upcoming version of MyEclipse?

    The @mock.generate is applied to interfaces at the interface-wide level. It takes one optional argument, className. The <mockobjectdoclet> task takes only the common options; its one subtask, <mockobjects> gives a customized naming pattern.

    #267599 Reply

    Riyad Kalla
    Member

    I couldn’t reproduce this.

    Go to your project’s XDOclet properties, click Add and name the doclet, say “Mock”. Then right-click in the panel below to add a new task, and add the mockobjectdoclet task.

    Also with your classes, in your javadoc hit @ and then invoke autocomplete, you have all the mock entities. For example I added @mock.generate to my class for a test.

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: XDoclet mock object support

You must be logged in to post in the forum log in