You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tapestry.apache.org by be...@apache.org on 2026/03/29 13:18:59 UTC

(tapestry-5) branch master updated (e02987902 -> bafa7f74a)

This is an automated email from the ASF dual-hosted git repository.

benw pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/tapestry-5.git


    from e02987902 TAP5-2819: Jenkinsfile increase selenium timeout
     new b42abba58 TAP5-2821: ReloadSpec write bytecode first, touch after
     new 1cfb911cf TAP5-2819: Jenkinsfile don't test integration variants
     new bafa7f74a TAP5-2819: SeleniumTestCase allow paramters from system property as fallback

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 Jenkinsfile                                        | 72 ++--------------------
 tapestry-core/build.gradle                         | 24 ++++++--
 .../src/test/groovy/ioc/specs/ReloadSpec.groovy    | 22 +++----
 .../apache/tapestry5/test/SeleniumTestCase.java    |  8 ++-
 4 files changed, 41 insertions(+), 85 deletions(-)


(tapestry-5) 01/03: TAP5-2821: ReloadSpec write bytecode first, touch after

Posted by be...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

benw pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tapestry-5.git

commit b42abba5828ea61bfc65a8f86d3b87d48aebe21b
Author: Ben Weidig <be...@netzgut.net>
AuthorDate: Sun Mar 29 13:25:31 2026 +0200

    TAP5-2821: ReloadSpec write bytecode first, touch after
---
 .../src/test/groovy/ioc/specs/ReloadSpec.groovy    | 22 +++++++++++-----------
 1 file changed, 11 insertions(+), 11 deletions(-)

diff --git a/tapestry-ioc/src/test/groovy/ioc/specs/ReloadSpec.groovy b/tapestry-ioc/src/test/groovy/ioc/specs/ReloadSpec.groovy
index 3221cafc0..e5ddb3106 100644
--- a/tapestry-ioc/src/test/groovy/ioc/specs/ReloadSpec.groovy
+++ b/tapestry-ioc/src/test/groovy/ioc/specs/ReloadSpec.groovy
@@ -149,10 +149,10 @@ class ReloadSpec extends Specification {
 
     update()
 
-    touch classFile
-
     createImplementationClass "updated"
 
+    touch classFile
+
     then:
 
     // Changes do not take effect until after update check
@@ -207,10 +207,10 @@ class ReloadSpec extends Specification {
 
     when:
 
-    touch(new File(pathForInternalName(baseClassInternalName)))
-
     createImplementationClass BASE_CLASS, "updated from base"
 
+    touch(new File(pathForInternalName(baseClassInternalName)))
+
     update()
 
     then:
@@ -267,10 +267,10 @@ class ReloadSpec extends Specification {
 
     when:
 
-    touch classFile
-
     createImplementationClass "updated proxy"
 
+    touch classFile
+
     update()
 
     then:
@@ -279,10 +279,10 @@ class ReloadSpec extends Specification {
 
     when:
 
-    touch classFile
-
     createImplementationClass "re-updated proxy"
 
+    touch classFile
+
     update()
 
     then:
@@ -300,10 +300,10 @@ class ReloadSpec extends Specification {
 
     ReloadableService reloadable = getService ReloadableService
 
-    touch classFile
-
     createInvalidImplementationClass()
 
+    touch classFile
+
     update()
 
     reloadable.getStatus()
@@ -398,7 +398,7 @@ class ReloadSpec extends Specification {
       // catches the change to the file. The Ubuntu CI Server appears
       // to need longer waits.
 
-      Thread.sleep 50 * (2 ^ index++)
+      Thread.sleep 50 * (2 ** index++)
     }
   }
 }


(tapestry-5) 02/03: TAP5-2819: Jenkinsfile don't test integration variants

Posted by be...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

benw pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tapestry-5.git

commit 1cfb911cfac4f1458cb5a5b6336478f5f1e6f73e
Author: Ben Weidig <be...@netzgut.net>
AuthorDate: Sun Mar 29 15:13:55 2026 +0200

    TAP5-2819: Jenkinsfile don't test integration variants
    
    As the integration tests can be quite flaky and take forever to complete
    all 4 of them, we should move the extra 3 variants out of the "default"
    Jenkinsfile and trigger them downstream (wip).
---
 Jenkinsfile | 72 +++++--------------------------------------------------------
 1 file changed, 5 insertions(+), 67 deletions(-)

diff --git a/Jenkinsfile b/Jenkinsfile
index d3fe1b0f8..bb982fbdb 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -28,9 +28,9 @@ pipeline {
             }
         }
 
-        // -- 02: Test: Check + jQuery + RequireJS Enabled ---------------------
+        // -- 02: Test: Check - Unit + integration tests (jQuery + RequireJS) --
 
-        stage('Test: Check + jQuery + RequireJS Enabled') {
+        stage('Test: Check') {
             steps {
                 sh './gradlew check'
             }
@@ -44,69 +44,7 @@ pipeline {
             }
         }
 
-        // -- 03: Test Variants ------------------------------------------------
-
-        stage('Test: Prototype + RequireJS Disabled') {
-            steps {
-                sh './gradlew tapestry-core:testWithPrototypeAndRequireJsDisabled'
-            }
-            post {
-                always {
-                     sh '''
-                        if [ -d "tapestry-core/build/test-results/testWithPrototypeAndRequireJsDisabled" ]; then
-                            find tapestry-core/build/test-results/testWithPrototypeAndRequireJsDisabled -name "*.xml" -type f -exec sed -i 's/classname="/classname="PrototypeAndRequireJsDisabled./g' {} +
-                        fi
-                    '''
-
-                    junit(
-                        testResults: 'tapestry-core/build/test-results/testWithPrototypeAndRequireJsDisabled/**/*.xml',
-                        allowEmptyResults: true
-                    )
-                }
-            }
-        }
-
-        stage('Test: jQuery + RequireJS Disabled') {
-            steps {
-                sh './gradlew tapestry-core:testWithJqueryAndRequireJsDisabled'
-            }
-            post {
-                always {
-                   sh '''
-                        if [ -d "tapestry-core/build/test-results/testWithJqueryAndRequireJsDisabled" ]; then
-                            find tapestry-core/build/test-results/testWithJqueryAndRequireJsDisabled -name "*.xml" -type f -exec sed -i 's/classname="/classname="JqueryAndRequireJsDisabled./g' {} +
-                        fi
-                    '''
-
-                    junit(
-                        testResults: 'tapestry-core/build/test-results/testWithJqueryAndRequireJsDisabled/**/*.xml',
-                        allowEmptyResults: true
-                    )
-                }
-            }
-        }
-
-        stage('Test: Prototype + RequireJS Enabled') {
-            steps {
-                sh './gradlew tapestry-core:testWithPrototypeAndRequireJsEnabled'
-            }
-            post {
-                always {
-                    sh '''
-                        if [ -d "tapestry-core/build/test-results/testWithPrototypeAndRequireJsEnabled" ]; then
-                            find tapestry-core/build/test-results/testWithPrototypeAndRequireJsEnabled -name "*.xml" -type f -exec sed -i 's/classname="/classname="PrototypeAndRequireJsEnabled./g' {} +
-                        fi
-                    '''
-
-                    junit(
-                        testResults: 'tapestry-core/build/test-results/testWithPrototypeAndRequireJsEnabled/**/*.xml',
-                        allowEmptyResults: true
-                    )
-                }
-            }
-        }
-
-        // -- 04: Coverage (JaCoCo) --------------------------------------------
+        // -- 03: Coverage (JaCoCo) --------------------------------------------
 
         stage('Coverage') {
             steps {
@@ -128,7 +66,7 @@ pipeline {
             }
         }
 
-        // -- 05: Archive Artifacts --------------------------------------------
+        // -- 04: Archive Artifacts --------------------------------------------
 
         stage('Archive') {
             steps {
@@ -139,7 +77,7 @@ pipeline {
             }
         }
 
-        // -- 06: Aggregate Javadoc --------------------------------------------
+        // -- 05: Aggregate Javadoc --------------------------------------------
 
         stage('Aggregate Javadoc') {
             steps {


(tapestry-5) 03/03: TAP5-2819: SeleniumTestCase allow paramters from system property as fallback

Posted by be...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

benw pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tapestry-5.git

commit bafa7f74ac10952b6ddc3de268d45b2e12ae7e07
Author: Ben Weidig <be...@netzgut.net>
AuthorDate: Sun Mar 29 15:17:45 2026 +0200

    TAP5-2819: SeleniumTestCase allow paramters from system property as fallback
    
    To eventually parallelize the integration testing in the future, the
    integration tests variant shouldn't all use the default port 9090.
    
    Therefore, the parameters should fallback to system properties if the
    XML value is null, and only if the prop is null, too, return the default
    value.
---
 tapestry-core/build.gradle                         | 24 ++++++++++++++++------
 .../apache/tapestry5/test/SeleniumTestCase.java    |  8 +++++++-
 2 files changed, 25 insertions(+), 7 deletions(-)

diff --git a/tapestry-core/build.gradle b/tapestry-core/build.gradle
index 0940740f5..d50636592 100644
--- a/tapestry-core/build.gradle
+++ b/tapestry-core/build.gradle
@@ -144,22 +144,34 @@ tasks.register('testWithJqueryAndRequireJsDisabled', Test) {
     group = 'Verification'
     description = 'Runs tests with jQuery and Require.js disabled'
 
-    systemProperty 'tapestry.javascript-infrastructure-provider', 'jquery'
-    systemProperty 'tapestry.require-js-enabled', 'false'
+    systemProperties(
+        'tapestry.javascript-infrastructure-provider': 'jquery',
+        'tapestry.require-js-enabled':                 'false',
+        'tapestry.port':                               '9091',
+        'tapestry.ssl-port':                           '8444'
+    )
 }
 
 tasks.register('testWithPrototypeAndRequireJsEnabled', Test) {
     group = 'Verification'  
     description = 'Runs tests with Prototype and Require.js enabled'
 
-    systemProperty 'tapestry.javascript-infrastructure-provider', 'prototype'
-    systemProperty 'tapestry.require-js-enabled', 'true'
+    systemProperties(
+        'tapestry.javascript-infrastructure-provider': 'prototype',
+        'tapestry.require-js-enabled':                 'true',
+        'tapestry.port':                               '9092',
+        'tapestry.ssl-port':                           '8445'
+    )
 }
 
 tasks.register('testWithPrototypeAndRequireJsDisabled', Test) {
     group = 'Verification'
     description = 'Runs tests with Prototype and Require.js disabled'
 
-    systemProperty 'tapestry.javascript-infrastructure-provider', 'prototype'
-    systemProperty 'tapestry.require-js-enabled', 'false'
+    systemProperties(
+        'tapestry.javascript-infrastructure-provider': 'prototype',
+        'tapestry.require-js-enabled':                 'false',
+        'tapestry.port':                               '9093',
+        'tapestry.ssl-port':                           '8446'
+    )
 }
diff --git a/tapestry-test/src/main/java/org/apache/tapestry5/test/SeleniumTestCase.java b/tapestry-test/src/main/java/org/apache/tapestry5/test/SeleniumTestCase.java
index d9d1f0bf4..83b60031a 100644
--- a/tapestry-test/src/main/java/org/apache/tapestry5/test/SeleniumTestCase.java
+++ b/tapestry-test/src/main/java/org/apache/tapestry5/test/SeleniumTestCase.java
@@ -360,12 +360,18 @@ public abstract class SeleniumTestCase extends Assert implements Selenium
     {
         String value = xmlTest.getParameter(key);
 
+        if (value == null)
+        {
+            // fall back to JVM system property
+            value = System.getProperty(key);
+        }
+
         return value != null ? value : defaultValue;
     }
 
     private final int getIntParameter(XmlTest xmlTest, String key, int defaultValue)
     {
-        String value = xmlTest.getParameter(key);
+        String value = getParameter(xmlTest, key, null);
 
         return value != null ? Integer.parseInt(value) : defaultValue;
     }