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

slachiewicz pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-ejb-plugin.git

commit de08154c3e4a90a2bdfba09618ad14112c55a3f6
Author: Sylwester Lachiewicz <[email protected]>
AuthorDate: Wed Nov 25 22:21:10 2026 +0000

    Format Groovy IT scripts
    
    Formatting only: the CONVERSION-phase AST of every file is unchanged. See 
https://github.com/apache/maven-invoker-plugin/issues/811.
---
 src/it/MEJB-72/verify.groovy              |  8 ++++----
 src/it/default/verify.groovy              | 26 ++++++++++-------------
 src/it/exclude-ejb-jar-xml/verify.groovy  | 31 +++++++++++++---------------
 src/it/manifest-content/verify.groovy     | 20 +++++++++---------
 src/it/mejb-34-filtered/verify.groovy     | 34 +++++++++++++++----------------
 src/it/mejb-34-not-filtered/verify.groovy | 34 +++++++++++++++----------------
 src/it/mejb-93/verify.groovy              | 16 +++++++--------
 src/it/reactor/verify.groovy              | 29 +++++++++++---------------
 8 files changed, 93 insertions(+), 105 deletions(-)

diff --git a/src/it/MEJB-72/verify.groovy b/src/it/MEJB-72/verify.groovy
index 3dbeb72..484fc39 100644
--- a/src/it/MEJB-72/verify.groovy
+++ b/src/it/MEJB-72/verify.groovy
@@ -18,8 +18,8 @@
  * under the License.
  */
 
-File target = new File( basedir, "target" );
-assert target.exists() && target.isDirectory() : "target file is missing or 
not a directory.";
+File target = new File(basedir, "target")
+assert target.exists() && target.isDirectory() : "target file is missing or 
not a directory."
 
-File artifact = new File( target, "maven-it-mejb72-1.0-SNAPSHOT.jar" );
-assert artifact.exists() : "default artifact should exist.";
+File artifact = new File( target, "maven-it-mejb72-1.0-SNAPSHOT.jar" )
+assert artifact.exists() : "default artifact should exist."
diff --git a/src/it/default/verify.groovy b/src/it/default/verify.groovy
index 14cf850..dfa748f 100644
--- a/src/it/default/verify.groovy
+++ b/src/it/default/verify.groovy
@@ -17,24 +17,20 @@
  * under the License.
  */
 
-import java.util.jar.*;
+import java.util.jar.*
 
-File jarFile = new File( basedir, "target/maven-it-it0017-1.0.jar" );
-System.out.println( "Checking for existence of " + jarFile );
-assert jarFile.isFile();
+File jarFile = new File(basedir, "target/maven-it-it0017-1.0.jar")
+System.out.println("Checking for existence of " + jarFile)
+assert jarFile.isFile()
 
-JarFile jar = new JarFile( jarFile );
+JarFile jar = new JarFile(jarFile)
 
-String[] includedEntries = [
-    "META-INF/ejb-jar.xml",
-    "org/apache/maven/it0017/Person.class",
-];
-for ( String included : includedEntries )
-{
-    System.out.println( "Checking for existence of " + included );
-    assert jar.getEntry( included ) != null : "Missing " + included;
+String[] includedEntries = ["META-INF/ejb-jar.xml", 
"org/apache/maven/it0017/Person.class",]
+for (String included : includedEntries) {
+    System.out.println("Checking for existence of " + included)
+    assert jar.getEntry(included) != null : "Missing " + included
 }
 
-jar.close();
+jar.close()
 
-return true;
+return true
diff --git a/src/it/exclude-ejb-jar-xml/verify.groovy 
b/src/it/exclude-ejb-jar-xml/verify.groovy
index 95d1f21..f8b63aa 100644
--- a/src/it/exclude-ejb-jar-xml/verify.groovy
+++ b/src/it/exclude-ejb-jar-xml/verify.groovy
@@ -17,29 +17,26 @@
  * under the License.
  */
 
-import java.util.zip.*;
+import java.util.zip.*
 
-File jarFile = new File( basedir, "target/test-1.0.jar" );
-System.out.println( "Checking for existence of " + jarFile );
-assert jarFile.isFile() : "Missing " + jarFile;
+File jarFile = new File(basedir, "target/test-1.0.jar")
+System.out.println("Checking for existence of " + jarFile)
+assert jarFile.isFile() : "Missing " + jarFile
 
-ZipInputStream zis = new ZipInputStream( new FileInputStream( jarFile ) );
+ZipInputStream zis = new ZipInputStream( new FileInputStream( jarFile ) )
 
-int count = 0;
+int count = 0
 
-while (true)
-{
-    ZipEntry entry = zis.getNextEntry();
-    if ( entry == null )
-    {
-        break;
+while (true) {
+    ZipEntry entry = zis.getNextEntry()
+    if ( entry == null ) {
+        break
     }
-    if ( entry.getName().equals( "META-INF/ejb-jar.xml" ) )
-    {
-        count++;
+    if ( entry.getName().equals( "META-INF/ejb-jar.xml" ) ) {
+        count++
     }
 }
 
-zis.close();
+zis.close()
 
-assert count == 1 : "Wrong number of ejb-jar.xml's in archive: " + count;
+assert count == 1 : "Wrong number of ejb-jar.xml's in archive: " + count
diff --git a/src/it/manifest-content/verify.groovy 
b/src/it/manifest-content/verify.groovy
index 1bbce3e..ffcaab9 100644
--- a/src/it/manifest-content/verify.groovy
+++ b/src/it/manifest-content/verify.groovy
@@ -17,19 +17,19 @@
  * under the License.
  */
 
-import java.util.jar.*;
+import java.util.jar.*
 
-File jarFile = new File( basedir, "target/test-1.0.jar" );
-System.out.println( "Checking for existence of " + jarFile );
-assert jarFile.isFile() : "Missing " + jarFile;
+File jarFile = new File(basedir, "target/test-1.0.jar")
+System.out.println("Checking for existence of " + jarFile)
+assert jarFile.isFile() : "Missing " + jarFile
 
-JarFile jar = new JarFile( jarFile );
+JarFile jar = new JarFile( jarFile )
 
-Attributes manifest = jar.getManifest().getMainAttributes();
+Attributes manifest = jar.getManifest().getMainAttributes()
 
-assert manifest.getValue( new Attributes.Name( "Created-By" ) ).startsWith( 
"Maven EJB Plugin" ) : "Created-By not equals Maven EJB Plugin";
+assert manifest.getValue( new Attributes.Name( "Created-By" ) ).startsWith( 
"Maven EJB Plugin" ) : "Created-By not equals Maven EJB Plugin"
 
-String classpath = manifest.getValue( Attributes.Name.CLASS_PATH );
-assert classpath != null && classpath.indexOf( "junit-3.8.2.jar" ) >= 0 : "Bad 
Class-Path " + classpath;
+String classpath = manifest.getValue( Attributes.Name.CLASS_PATH )
+assert classpath != null && classpath.indexOf( "junit-3.8.2.jar" ) >= 0 : "Bad 
Class-Path " + classpath
 
-jar.close();
+jar.close()
diff --git a/src/it/mejb-34-filtered/verify.groovy 
b/src/it/mejb-34-filtered/verify.groovy
index 6d2bc20..8411653 100644
--- a/src/it/mejb-34-filtered/verify.groovy
+++ b/src/it/mejb-34-filtered/verify.groovy
@@ -17,26 +17,26 @@
  * under the License.
  */
 
-import java.util.jar.*;
-import java.util.zip.ZipEntry;
+import java.util.jar.*
+import java.util.zip.ZipEntry
 
-File file = new File( basedir, "target/mejb-34-filtered-1.0.jar" );
-System.out.println( "Checking for existence of " + file );
-assert file.isFile() : "FAILURE! Missing JAR file";
+File file = new File(basedir, "target/mejb-34-filtered-1.0.jar")
+System.out.println("Checking for existence of " + file)
+assert file.isFile() : "FAILURE! Missing JAR file"
 
-JarFile jarFile = new JarFile( file );
+JarFile jarFile = new JarFile( file )
 
-ZipEntry zipEntry = jarFile.getEntry( "META-INF/ejb-jar.xml" );
-assert zipEntry != null : "FAILURE! Missing META-INF/ejb-jar.xml in the JAR 
file";
+ZipEntry zipEntry = jarFile.getEntry( "META-INF/ejb-jar.xml" )
+assert zipEntry != null : "FAILURE! Missing META-INF/ejb-jar.xml in the JAR 
file"
 
-InputStream is = jarFile.getInputStream( zipEntry );
-String contents = is.getText( 'UTF-8' );
-int index = contents.indexOf( "myKey" );
-assert index < 0 : "FAILURE! The key 'myKey' has not been replaced during 
filtering";
-index = contents.indexOf( "myValue" );
-assert index >= 0 : "FAILURE! The value 'myValue' has not been injected during 
filtering";
-is.close();
+InputStream is = jarFile.getInputStream( zipEntry )
+String contents = is.getText( 'UTF-8' )
+int index = contents.indexOf( "myKey" )
+assert index < 0 : "FAILURE! The key 'myKey' has not been replaced during 
filtering"
+index = contents.indexOf( "myValue" )
+assert index >= 0 : "FAILURE! The value 'myValue' has not been injected during 
filtering"
+is.close()
 
-jarFile.close();
+jarFile.close()
 
-return true;
+return true
diff --git a/src/it/mejb-34-not-filtered/verify.groovy 
b/src/it/mejb-34-not-filtered/verify.groovy
index 5d7de7c..b629a88 100644
--- a/src/it/mejb-34-not-filtered/verify.groovy
+++ b/src/it/mejb-34-not-filtered/verify.groovy
@@ -17,26 +17,26 @@
  * under the License.
  */
 
-import java.util.jar.*;
-import java.util.zip.ZipEntry;
+import java.util.jar.*
+import java.util.zip.ZipEntry
 
-File file = new File( basedir, "target/mejb-34-not-filtered-1.0.jar" );
-System.out.println( "Checking for existence of " + file );
-assert file.isFile() : "FAILURE! Missing JAR file";
+File file = new File(basedir, "target/mejb-34-not-filtered-1.0.jar")
+System.out.println("Checking for existence of " + file)
+assert file.isFile() : "FAILURE! Missing JAR file"
 
-JarFile jarFile = new JarFile( file );
+JarFile jarFile = new JarFile( file )
 
-ZipEntry zipEntry = jarFile.getEntry( "META-INF/ejb-jar.xml" );
-assert zipEntry != null : "FAILURE! Missing META-INF/ejb-jar.xml in the JAR 
file";
+ZipEntry zipEntry = jarFile.getEntry( "META-INF/ejb-jar.xml" )
+assert zipEntry != null : "FAILURE! Missing META-INF/ejb-jar.xml in the JAR 
file"
 
-InputStream is = jarFile.getInputStream( zipEntry );
-String contents = is.getText( 'UTF-8' );
-int index = contents.indexOf( "myKey" );
-assert index >= 0 : "FAILURE! The key 'myKey' has been replaced, but filtering 
is turned off";
-index = contents.indexOf( "myValue" );
-assert index < 0 : "FAILURE! The value 'myValue' has been injected, but 
filtering is turned off";
-is.close();
+InputStream is = jarFile.getInputStream( zipEntry )
+String contents = is.getText( 'UTF-8' )
+int index = contents.indexOf( "myKey" )
+assert index >= 0 : "FAILURE! The key 'myKey' has been replaced, but filtering 
is turned off"
+index = contents.indexOf( "myValue" )
+assert index < 0 : "FAILURE! The value 'myValue' has been injected, but 
filtering is turned off"
+is.close()
 
-jarFile.close();
+jarFile.close()
 
-return true;
+return true
diff --git a/src/it/mejb-93/verify.groovy b/src/it/mejb-93/verify.groovy
index 3f93cab..8a4b235 100644
--- a/src/it/mejb-93/verify.groovy
+++ b/src/it/mejb-93/verify.groovy
@@ -34,22 +34,22 @@ def getProjectVersion() {
         item.groupId.equals("org.apache.maven.plugins") && 
item.artifactId.equals("maven-ejb-plugin")
     }
 
-    return mavenejb.version;
+    return mavenejb.version
 }
 
-def projectVersion = getProjectVersion();
+def projectVersion = getProjectVersion()
 
 println "ProjectVersion:" + projectVersion
 
 
-def jarFile = new File( basedir, "target/maven-it-mejb93-1.0.jar" )
+def jarFile = new File(basedir, "target/maven-it-mejb93-1.0.jar")
 assert jarFile.isFile()
 
-def buildLog = new File( basedir, "build.log" ).getText('UTF-8')
+def buildLog = new File(basedir, "build.log").getText('UTF-8')
 
-assert buildLog.contains ('' + projectVersion + ':ejb (default-ejb) @ 
maven-it-mejb93 ---') : "default executions did not happen."
+assert buildLog.contains('' + projectVersion + ':ejb (default-ejb) @ 
maven-it-mejb93 ---') : "default executions did not happen."
 assert buildLog.contains ('' + projectVersion + ':ejb (second-execution) @ 
maven-it-mejb93 ---') : "second executions did not happen."
 assert buildLog.contains ('[ERROR] Failed to execute goal 
org.apache.maven.plugins:maven-ejb-plugin:' + projectVersion
-    + ':ejb (second-execution) on project maven-it-mejb93: '
-    + 'You have to use a classifier to attach supplemental artifacts to the '
-    + 'project instead of replacing them. -> [Help 1]') : "exception message 
does not exists or the expected content does not exist."
++ ':ejb (second-execution) on project maven-it-mejb93: '
++ 'You have to use a classifier to attach supplemental artifacts to the '
++ 'project instead of replacing them. -> [Help 1]') : "exception message does 
not exists or the expected content does not exist."
diff --git a/src/it/reactor/verify.groovy b/src/it/reactor/verify.groovy
index fe55e95..a2265f4 100644
--- a/src/it/reactor/verify.groovy
+++ b/src/it/reactor/verify.groovy
@@ -17,27 +17,22 @@
  * under the License.
  */
 
-import java.util.jar.*;
+import java.util.jar.*
 
-File jarFile = new File( basedir, "sub/target/sub-1.0.jar" );
-System.out.println( "Checking for existence of " + jarFile );
-assert jarFile.isFile() : "Missing " + jarFile;
+File jarFile = new File(basedir, "sub/target/sub-1.0.jar")
+System.out.println("Checking for existence of " + jarFile)
+assert jarFile.isFile() : "Missing " + jarFile
 
-JarFile jar = new JarFile( jarFile );
+JarFile jar = new JarFile( jarFile )
 
-String[] includedEntries = [
-    "META-INF/ejb-jar.xml",
-    "org/apache/maven/Person.class",
-];
-for ( String included : includedEntries )
-{
-    System.out.println( "Checking for existence of " + included );
-    if ( jar.getEntry( included ) == null )
-    {
-        throw new Exception( "Missing " + included );
+String[] includedEntries = ["META-INF/ejb-jar.xml", 
"org/apache/maven/Person.class",]
+for ( String included : includedEntries ) {
+    System.out.println( "Checking for existence of " + included )
+    if ( jar.getEntry( included ) == null ) {
+        throw new Exception( "Missing " + included )
     }
 }
 
-jar.close();
+jar.close()
 
-return true;
+return true

Reply via email to