description = "Integration of Tapestry with the Spring Inversion Of Control Container"

// Spring 6 requires Java 17
sourceCompatibility = "17"
targetCompatibility = "17"

dependencies {
  implementation project(':tapestry-core')
  implementation "org.springframework:spring-websocket:6.0.11"

  provided "jakarta.servlet:jakarta.servlet-api:${versions.servletapi}"

  testImplementation project(':tapestry-test')
}

jar {
    manifest {
        attributes 'Tapestry-Module-Classes': 'org.apache.tapestry5.spring.modules.SpringModule'
    }
}

task runTestApp(type:JavaExec) {
    description 'Start tapestry-spring integration test app, useful when debugging failing integration tests'
    main = 'org.apache.tapestry5.test.JettyRunner'
    args "-d", "src/test/webapp", "-p", "8080"
    classpath += project.sourceSets.test.runtimeClasspath
}

task runTestApp1(type:JavaExec) {
    description 'Start tapestry-spring integration test app 1, useful when debugging failing integration tests'
    main = 'org.apache.tapestry5.test.JettyRunner'
    args "-d", "src/test/webapp1", "-p", "8080"
    classpath += project.sourceSets.test.runtimeClasspath
}
