Review main Merged

42971[BUGFIX] Abstract XSD generator can handle more than two namespace parts

Helmut Hummel CR +2 V +2 Easy +11 −8 updated 09/02/15, 07:50

Commit message

The getTagNameForClass method in the abstract XSD generator class
could not handle class names with more than two namespace parts.

This caused e.g. TYPO3\CMS\Fluid\ViewHelpers\Be\Buttons\CshViewHelper to
not be transformed to "be.buttons.csh", but just "be.", which in turn
caused duplicate id errors in the resulting XSD document.

Make the code aware of more than two namespace parts.

Review

  • Code review CR +2
    • Nicole Hummel +2
    • Markus Klein +1
  • Verified V +2
    • Nicole Hummel +2
    • Markus Klein +1

Issues 1

Files 1

Review log 10

  1. Helmut Hummel uploaded patch set 1 09/01/15, 20:11

  2. Markus Klein commented on patch set 1 09/01/15, 20:21

    deserves a simple unit test IMHO

    AbstractGenerator.php:81

    please add the comment again why this is -10
  3. Helmut Hummel commented on patch set 1 09/02/15, 05:53

    AbstractGenerator.php:74

    see comment here what the goal of this method is

    AbstractGenerator.php:81 Reply

    the -10 is to strip off "ViewHelper" from the end. It was there a few lines below. I only moved it here, as it makes more sense to just strip in once. This line strips off the namespace from the beginning and "ViewHelper" from the end of the class name, leaving "Form\Select" from "TYPO3\CMS\Fluid\ViewHelpers\Form\SelectViewHelper" This is then transformed to "form.select" below
  4. Helmut Hummel commented on patch set 1 09/02/15, 05:57

    AbstractGenerator.php:81 Reply

    Done
  5. Helmut Hummel uploaded patch set 2 09/02/15, 05:58

  6. Markus Klein voted on patch set 2 CR +1 V +1 09/02/15, 06:49

  7. Nicole Hummel voted on patch set 2 CR +2 V +2 09/02/15, 07:41

  8. Nicole Hummel merged patch set 2 09/02/15, 07:41

  9. Nicole Hummel commented on patch set 3 09/02/15, 07:41

    Cherry Picked This patchset was cherry picked to branch TYPO3_6-2 as commit cc5d7dd9a330204bd21e6049ead690314698ce9e
  10. Helmut Hummel commented on patch set 3 09/02/15, 07:50

    Thanks!