Maven 1.x EJB Plugin
  1. Maven 1.x EJB Plugin
  2. MPEJB-23

ejb:init does not compile java code if tests are not run

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.7.3
    • Labels:
      None
    • Number of attachments :
      1

      Description

      When there are no tests, or maven.test.skip=true, then the build classes and resources are not included in the ejb jar file.

      As a workaround, you can set java:compile and java:jar-resources as preGoals for ejb:ejb in your maven.xml:

      <preGoal name="ejb:init">
      <j:if test="$

      {unitTestSourcesPresent != 'true' or context.getVariable('maven.test.skip') == 'true'}

      ">
      <attainGoal name="java:compile"/>
      <attainGoal name="java:jar-resources"/>
      </j:if>
      </preGoal>

      1. MPEJB-23
        0.8 kB
        Shinobu Kawai

        Issue Links

          Activity

          Hide
          Shinobu Kawai added a comment -

          Patch to fix bug.

          Show
          Shinobu Kawai added a comment - Patch to fix bug.
          Hide
          dion gillard added a comment -

          This is a showstopper for another 1.1 beta release for me, as well.

          Show
          dion gillard added a comment - This is a showstopper for another 1.1 beta release for me, as well.
          Hide
          Shinobu Kawai added a comment -

          This should be revisited once MPTEST-66 is fixed one way or another.

          Show
          Shinobu Kawai added a comment - This should be revisited once MPTEST-66 is fixed one way or another.

            People

            • Assignee:
              Unassigned
              Reporter:
              Shinobu Kawai
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: