Uploaded image for project: 'Tools (JBoss Tools)'
  1. Tools (JBoss Tools)
  2. JBIDE-18808

JAX-RS Resource wizard: Resource methods are created even though there is no Target entity specified anymore

XMLWordPrintable

    • Hide

      ASSERT: Open JAX-RS Resource wizard.
      EXEC: Fill in Name for resource.
      ASSERT: Checkboxes to generate methods are uneditable.
      EXEC: Fill in Entity name.
      ASSERT: Checkboxes to generate methods are editable.
      EXEC: Check few of the checkboxes.
      EXEC: Clean Entity name (leave the text field blank).
      ASSERT: Checkboxes to generate methods are uneditable and some of them are checked.
      EXEC: Proceed the wizard (finish it).

      RESULT: Resource class is generated with methods and parameter for entity is blank which cause syntax error.
      EXPECTED RESULT: Resource class is generated without methods which have been checked with no Entity name filled.

      Show
      ASSERT: Open JAX-RS Resource wizard. EXEC: Fill in Name for resource. ASSERT: Checkboxes to generate methods are uneditable. EXEC: Fill in Entity name. ASSERT: Checkboxes to generate methods are editable. EXEC: Check few of the checkboxes. EXEC: Clean Entity name (leave the text field blank). ASSERT: Checkboxes to generate methods are uneditable and some of them are checked. EXEC: Proceed the wizard (finish it). RESULT: Resource class is generated with methods and parameter for entity is blank which cause syntax error. EXPECTED RESULT: Resource class is generated without methods which have been checked with no Entity name filled.

      If I start typing name of Target entity in the JAX-RS Resource wizard, then checkboxes for creating resource methods (findById, listAll...) are allowed to be changed (checked/unchecked). But after completely removing of Target entity (leaving the field blank) the checkboxes are stilled in state checked/unchecked as they were changed while having filled Entity, but this changes are propagated next. That cause generating resource class with those methods even though there was no Entity specified and it leaves blank space in those generated methods causing syntax error.

            xcoulon@redhat.com Xavier Coulon
            xcoulon@redhat.com Xavier Coulon
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: