Uploaded image for project: 'Maven'
  1. Maven
  2. MNG-2344

Support for functional/integration tests is *way* too limited

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Duplicate
    • Affects Version/s: 2.0.4
    • Fix Version/s: None
    • Labels:
      None

      Description

      I am a recent convert to Maven2 ... after listening to advice from many people I respect (including Wendy Smoak and Brett Porter) we are in the midst of migrating the build environment for the Shale Framework (part of the http://struts.apache.org community) over to Maven2. For the most part, this has been all goodness ... the dependency management, and the hierarchical dependency resolution, make for a dramatic simplification in the overall environment.

      That being said, there is one major area where I'm really disappointed ... and it's almost enough to tip my personal scale back towards hand crafted Ant builds. It relates to support for testing of web applications. My plan is to leverage the Maven2 "archetype" capability to make it very easy to build "starter" web applications that are already set up to use Shale. To encourage best practices, I want to set up "out of the box" testing for the application to be developed.

      As we all know, this kind of testing can be divided into at least two major categories ... unit tests of the individual server side classes, and functiona/integration tests that want to deploy the application first, then interact with it (using a framework such as HttpUnit or HtmlUnit) to verify that the rendered results match expectations. In my previous Ant-based build world, I had two different targets ("test" and "systest") that could exercise the two different kinds of tests. Much to my surprise, it seems to be difficult-to-impossible to set up a similar sceanrio (two kinds of tests) in the same project when you're using Maven2.

      I could live with this (although I'd still grumble a lot) if it was just an issue of the sample apps that we ship with Shale. I can teach committers to run integration tests from a separate module before doing SVN commits. But that is not what I want to present to potential developers that will build webapps based on a Shale-provided archtetype. And it shouldn't be what you want for Maven2 users in general either ... support for both unit tests and integration tests seems like a mission critical feature that is not adequately supported at present.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                brettporter Brett Porter
                Reporter:
                craigmcc Craig R. McClanahan
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: