Uploaded image for project: 'Apache Tomcat Maven Plugin'
  1. Apache Tomcat Maven Plugin
  2. MTOMCAT-123

Can't add test scoped dependency filters to web.xml

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.0-beta-1, 2.0
    • 2.0
    • tomcat7
    • None

    Description

      When a Filter that is from a test scoped dependency is added to the web.xml, a ClassNotFoundException is thrown when starting the Tomcat server. Everything runs fine when dependency is changed to compile.

      <plugin>
      <groupId>org.apache.tomcat.maven</groupId>
      <artifactId>tomcat7-maven-plugin</artifactId>
      <version>2.0-beta-1</version>
      <executions>
      <execution>
      <id>tomcat-run</id>
      <goals>
      <goal>run</goal>
      </goals>
      <phase>pre-integration-test</phase>
      <configuration>
      <path>/</path>
      <useTestClasspath>true</useTestClasspath>
      <fork>true</fork>
      <warSourceDirectory>${basedir}/src/test/webapp</warSourceDirectory>
      <ignorePackaging>true</ignorePackaging>
      </configuration>
      </execution>
      <execution>
      <id>tomcat-shutdown</id>
      <goals>
      <goal>shutdown</goal>
      </goals>
      <phase>post-integration-test</phase>
      </execution>
      </executions>
      </plugin>

      Attachments

        1. tomcat-testcase.zip
          15 kB
          Nathan Schile

        Activity

          People

            olamy Olivier Lamy
            nschile Nathan Schile
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: