You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@netbeans.apache.org by GitBox <gi...@apache.org> on 2017/11/23 03:56:18 UTC

[GitHub] junichi11 closed pull request #264: Check whether line endings are LF with Travis CI

junichi11 closed pull request #264: Check whether line endings are LF with Travis CI
URL: https://github.com/apache/incubator-netbeans/pull/264
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/.travis.yml b/.travis.yml
index d455e5891..2a5cc1917 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -22,3 +22,4 @@ script:
   - ant -quiet build -Djavac.compilerargs=-nowarn -Dbuild.compiler.deprecation=false
   - ant -quiet test -Djavac.compilerargs=-nowarn -Dbuild.compiler.deprecation=false -Dtest.includes=NoTestsJustBuild
   - ant -quiet verify-libs-and-licenses -Dcluster.config=platform -Dverify-libs-and-licenses.haltonfailure=true
+  - ./travis-check-line-endings.sh
diff --git a/autoupdate.services/test/unit/src/org/netbeans/modules/autoupdate/services/ExecutablePermissionsTestDisabled.java b/autoupdate.services/test/unit/src/org/netbeans/modules/autoupdate/services/ExecutablePermissionsTestDisabled.java
index 513ddecb7..17458e86c 100644
--- a/autoupdate.services/test/unit/src/org/netbeans/modules/autoupdate/services/ExecutablePermissionsTestDisabled.java
+++ b/autoupdate.services/test/unit/src/org/netbeans/modules/autoupdate/services/ExecutablePermissionsTestDisabled.java
@@ -1,91 +1,91 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.netbeans.modules.autoupdate.services;
-
-import java.io.File;
-import java.io.IOException;
-import java.util.HashMap;
-import java.util.Map;
-import org.netbeans.api.autoupdate.UpdateUnit;
-import org.netbeans.spi.autoupdate.UpdateItem;
-import org.netbeans.spi.autoupdate.UpdateProvider;
-
-/**
- *
- * @author Dmitry Lipin
- */
-public class ExecutablePermissionsTestDisabled extends NbmAdvancedTestCase {
-
-    private UpdateProvider p = null;
-    private String testModuleVersion = "1.0";
-    private String testModuleName = "org.yourorghere.executable.permissions";
-
-    public ExecutablePermissionsTestDisabled(String name) {
-        super(name);
-    }
-
-    @Override
-    protected void setUp() throws IOException, Exception {
-        super.setUp();
-    }
-
-    @Override
-    public boolean canRun() {
-        return super.canRun() && !System.getProperty("os.name").startsWith("Windows");
-    }
-
-    private String generateExecutablePermissionsModuleElement() {
-        String res = "\n<module codenamebase=\"" + testModuleName + "\" " +
-                "homepage=\"http://www.netbeans.org/\" distribution=\"nbresloc:/org/netbeans/api/autoupdate/data/org-yourorghere-executable-permissions.nbm\" " +
-                "license=\"standard-nbm-license.txt\" downloadsize=\"5122\" " +
-                "needsrestart=\"false\" moduleauthor=\"\" " +
-                "eager=\"false\" " +
-                "releasedate=\"2006/02/23\">\n";
-        res += "<manifest OpenIDE-Module=\"" + testModuleName + "\" " +
-                "OpenIDE-Module-Name=\"" + testModuleName + "\" " +
-                "AutoUpdate-Show-In-Client=\"true\" " +
-                "OpenIDE-Module-Specification-Version=\"" + testModuleVersion + "\"/>\n";
-        res += "</module>";
-        return res;
-    }
-
-    public void testExecutablePermissionsModule() throws IOException {
-        String os = !org.openide.util.Utilities.isUnix() ? "Windows" : "Unix";
-        String catalog = generateCatalog(generateExecutablePermissionsModuleElement());
-
-        p = createUpdateProvider(catalog);
-        p.refresh(true);
-
-        Map<String, UpdateUnit> unitImpls = new HashMap<String, UpdateUnit>();
-        Map<String, UpdateItem> updates = p.getUpdateItems();
-        assertNotNull("Some modules are installed.", updates);
-        assertFalse("Some modules are installed.", updates.isEmpty());
-        assertTrue(testModuleName + " found in parsed items.", updates.keySet().contains(testModuleName + "_" + testModuleVersion));
-
-        Map<String, UpdateUnit> newImpls = UpdateUnitFactory.getDefault().appendUpdateItems(unitImpls, p);
-        assertNotNull("Some units found.", newImpls);
-        assertFalse("Some units found.", newImpls.isEmpty());
-
-        UpdateUnit u1 = newImpls.get(testModuleName);
-        installUpdateUnit(u1);
-        File f = new File(userDir, "bin/start.sh");
-        assertTrue("File " + f + " should exist after module installation", f.exists());
-        assertTrue("File " + f + " is not executable after module installation", f.canExecute());
-    }    
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.netbeans.modules.autoupdate.services;
+
+import java.io.File;
+import java.io.IOException;
+import java.util.HashMap;
+import java.util.Map;
+import org.netbeans.api.autoupdate.UpdateUnit;
+import org.netbeans.spi.autoupdate.UpdateItem;
+import org.netbeans.spi.autoupdate.UpdateProvider;
+
+/**
+ *
+ * @author Dmitry Lipin
+ */
+public class ExecutablePermissionsTestDisabled extends NbmAdvancedTestCase {
+
+    private UpdateProvider p = null;
+    private String testModuleVersion = "1.0";
+    private String testModuleName = "org.yourorghere.executable.permissions";
+
+    public ExecutablePermissionsTestDisabled(String name) {
+        super(name);
+    }
+
+    @Override
+    protected void setUp() throws IOException, Exception {
+        super.setUp();
+    }
+
+    @Override
+    public boolean canRun() {
+        return super.canRun() && !System.getProperty("os.name").startsWith("Windows");
+    }
+
+    private String generateExecutablePermissionsModuleElement() {
+        String res = "\n<module codenamebase=\"" + testModuleName + "\" " +
+                "homepage=\"http://www.netbeans.org/\" distribution=\"nbresloc:/org/netbeans/api/autoupdate/data/org-yourorghere-executable-permissions.nbm\" " +
+                "license=\"standard-nbm-license.txt\" downloadsize=\"5122\" " +
+                "needsrestart=\"false\" moduleauthor=\"\" " +
+                "eager=\"false\" " +
+                "releasedate=\"2006/02/23\">\n";
+        res += "<manifest OpenIDE-Module=\"" + testModuleName + "\" " +
+                "OpenIDE-Module-Name=\"" + testModuleName + "\" " +
+                "AutoUpdate-Show-In-Client=\"true\" " +
+                "OpenIDE-Module-Specification-Version=\"" + testModuleVersion + "\"/>\n";
+        res += "</module>";
+        return res;
+    }
+
+    public void testExecutablePermissionsModule() throws IOException {
+        String os = !org.openide.util.Utilities.isUnix() ? "Windows" : "Unix";
+        String catalog = generateCatalog(generateExecutablePermissionsModuleElement());
+
+        p = createUpdateProvider(catalog);
+        p.refresh(true);
+
+        Map<String, UpdateUnit> unitImpls = new HashMap<String, UpdateUnit>();
+        Map<String, UpdateItem> updates = p.getUpdateItems();
+        assertNotNull("Some modules are installed.", updates);
+        assertFalse("Some modules are installed.", updates.isEmpty());
+        assertTrue(testModuleName + " found in parsed items.", updates.keySet().contains(testModuleName + "_" + testModuleVersion));
+
+        Map<String, UpdateUnit> newImpls = UpdateUnitFactory.getDefault().appendUpdateItems(unitImpls, p);
+        assertNotNull("Some units found.", newImpls);
+        assertFalse("Some units found.", newImpls.isEmpty());
+
+        UpdateUnit u1 = newImpls.get(testModuleName);
+        installUpdateUnit(u1);
+        File f = new File(userDir, "bin/start.sh");
+        assertTrue("File " + f + " should exist after module installation", f.exists());
+        assertTrue("File " + f + " is not executable after module installation", f.canExecute());
+    }    
+}
diff --git a/autoupdate.services/test/unit/src/org/netbeans/modules/autoupdate/services/InstallEagerModuleTest.java b/autoupdate.services/test/unit/src/org/netbeans/modules/autoupdate/services/InstallEagerModuleTest.java
index 9e28fd5a8..ce1609ad9 100644
--- a/autoupdate.services/test/unit/src/org/netbeans/modules/autoupdate/services/InstallEagerModuleTest.java
+++ b/autoupdate.services/test/unit/src/org/netbeans/modules/autoupdate/services/InstallEagerModuleTest.java
@@ -1,167 +1,167 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-package org.netbeans.modules.autoupdate.services;
-
-import java.io.IOException;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import org.netbeans.api.autoupdate.UpdateElement;
-import org.netbeans.api.autoupdate.UpdateManager;
-import org.netbeans.api.autoupdate.UpdateUnit;
-import org.netbeans.api.autoupdate.UpdateUnitProviderFactory;
-import org.netbeans.modules.autoupdate.updateprovider.AutoupdateCatalogProvider;
-import org.netbeans.modules.autoupdate.updateprovider.ModuleItem;
-import org.netbeans.spi.autoupdate.UpdateItem;
-
-/**
- *
- * @author Jiri Rechtacek
- */
-public class InstallEagerModuleTest extends NbmAdvancedTestCase {
-    
-    public InstallEagerModuleTest (String testName) {
-        super (testName);
-    }
-    
-    public void testIfAutoupdateUnderstandsEagerAttribute () throws IOException {
-        // Lookup.getDefault ().lookup (ModuleInfo.class);
-        String eagerModule = "com.sun.testmodule.eager";
-        String regularModule = "com.sun.testmodule.regular";
-        String catalog = generateCatalog (
-                generateModuleElement (eagerModule, "1.3", null, null, false, true,
-                    "org.openide.filesystems > 6.2",
-                    "org.openide.util > 6.2",
-                    "org.openide.modules > 6.2",
-                    "org.openide.nodes > 6.2",
-                    "org.openide.loaders",
-                    "org.openide.io"),
-                generateModuleElement (regularModule, "1.3", null, null, false, false,
-                    "org.openide.filesystems > 6.2",
-                    "org.openide.util > 6.2",
-                    "org.openide.modules > 6.2",
-                    "org.openide.nodes > 6.2",
-                    "org.openide.loaders",
-                    "org.openide.io")
-                
-                );
-        AutoupdateCatalogProvider p = createUpdateProvider (catalog);
-        p.refresh (true);
-        Map<String, UpdateItem> updates = p.getUpdateItems ();
-        assertNotNull ("Some modules are installed.", updates);
-        assertFalse ("Some modules are installed.", updates.isEmpty ());
-        
-        // check being 
-        assertTrue (eagerModule + " found in parsed items.", updates.keySet ().contains (eagerModule + "_1.3"));
-        assertTrue (regularModule + " found in parsed items.", updates.keySet ().contains (regularModule + "_1.3"));
-        
-        // check state
-        ModuleItem eagerModuleItem = (ModuleItem) Trampoline.SPI.impl (updates.get (eagerModule + "_1.3"));
-        ModuleItem regularModuleItem = (ModuleItem) Trampoline.SPI.impl (updates.get (regularModule + "_1.3"));
-        assertTrue (eagerModule + " is eager.", eagerModuleItem.isEager () && ! eagerModuleItem.isAutoload ());
-        assertFalse (regularModule + " is regular.", regularModuleItem.isEager () || regularModuleItem.isAutoload ());
-    }
-    
-    public void testAquireEargersFromManager () throws IOException {
-        String eagerModule = "com.sun.testmodule.eager";
-        String regularModule1 = "org.yourorghere.independent";
-        String regularModule2 = "org.yourorghere.engine";
-        String catalog = generateCatalog (
-                generateModuleElement (eagerModule, "1.0", null, null, false, true,
-                    regularModule1,
-                    regularModule2),
-                generateModuleElement (regularModule1, "1.0", null, null, false, false),
-                generateModuleElement (regularModule2, "1.0", null, null, false, false, regularModule1)
-                
-                );
-
-        UpdateUnitProviderFactory.getDefault ().create ("test-update-provider", "test-update-provider", generateFile (catalog));
-        UpdateUnitProviderFactory.getDefault ().refreshProviders (null, true);
-        
-        Set<UpdateElement> eagerElements = UpdateManagerImpl.getInstance ().getAvailableEagers ();
-        assertFalse ("Some available eagers are found.", eagerElements.isEmpty ());
-        UpdateUnit ea = UpdateManagerImpl.getInstance ().getUpdateUnit (eagerModule);
-        UpdateElement foundEaEl = eagerElements.iterator ().next ();
-        UpdateUnit foundEaU = foundEaEl.getUpdateUnit ();
-        assertEquals ("Same eager UpdateUnit", ea, foundEaU);
-        
-        // assertFalse ("Some installed eagers are found.", UpdateManagerImpl.getInstance ().getInstalledEagers ().isEmpty ());
-    }
-    
-    public void disable_testInstallRegularModule () throws IOException {
-        String eagerModule = "com.sun.testmodule.eager";
-        String regularModule1 = "org.yourorghere.independent";
-        String regularModule2 = "org.yourorghere.engine";
-        String catalog = generateCatalog (
-                generateModuleElement (eagerModule, "1.0", null, null, false, true,
-                    regularModule1,
-                    regularModule2),
-                generateModuleElement (regularModule1, "1.0", null, null, true, false),
-                generateModuleElement (regularModule2, "1.0", null, null, true, false, regularModule1)
-                
-                );
-
-        AutoupdateCatalogProvider p = createUpdateProvider (catalog);
-        p.refresh (true);
-        Map<String, UpdateItem> updates = p.getUpdateItems ();
-        
-        // initial check of updates being and its states
-        ModuleItem eagerModuleItem = (ModuleItem) Trampoline.SPI.impl (updates.get (eagerModule + "_1.0"));
-        assertFalse (eagerModuleItem.getModuleInfo ().getDependencies () + " are not empty.",
-                eagerModuleItem.getModuleInfo ().getDependencies ().isEmpty ());
-        ModuleItem regularModule1Item = (ModuleItem) Trampoline.SPI.impl (updates.get (regularModule1 + "_1.0"));
-        ModuleItem regularModule2Item = (ModuleItem) Trampoline.SPI.impl (updates.get (regularModule2 + "_1.0"));
-        assertTrue (eagerModule + " is eager.", eagerModuleItem.isEager () && ! eagerModuleItem.isAutoload ());
-        assertFalse (regularModule1 + " is regular.", regularModule1Item.isEager () || regularModule1Item.isAutoload ());
-        assertFalse (regularModule2 + " is regular.", regularModule2Item.isEager () || regularModule2Item.isAutoload ());
-        
-        // acquire UpdateUnits for test modules
-        UpdateUnitProviderFactory.getDefault ().create ("test-update-provider", "test-update-provider", generateFile (catalog));
-        UpdateUnitProviderFactory.getDefault ().refreshProviders (null, true);
-        UpdateUnit u1 = UpdateManagerImpl.getInstance ().getUpdateUnit (regularModule1);
-        assertTrue (UpdateManager.TYPE.KIT_MODULE.equals (u1.getType ()));
-        
-        //keep it to prevent GC-ed cache in UpdateManagerImpl
-        List<UpdateUnit> uuu =   UpdateManagerImpl.getInstance ().getUpdateUnits();
-        UpdateUnit u2 = UpdateManagerImpl.getInstance ().getUpdateUnit (regularModule2);
-        UpdateUnit ea = UpdateManagerImpl.getInstance ().getUpdateUnit (eagerModule);
-        assertNotNull ("Unit " + regularModule1 + " found.", u1);
-        assertNotNull ("Unit " + regularModule2 + " found.", u2);
-        assertNotNull ("Unit " + eagerModule + " found.", ea);
-        
-        // install regular module 1
-        installUpdateUnit (u1);
-
-        // check states installed regular 1 and others
-        assertNotNull (u1 + " is installed.", u1.getInstalled ());
-        assertNull (u2 + " is not installed.", u2.getInstalled ());
-        assertNull (ea + " is not installed.", ea.getInstalled ());
-        
-        // installe regular module 2
-        installUpdateUnit (u2);
-        
-        // check states installed regular 1 and others
-        assertNotNull (u1 + " is installed.", u1.getInstalled ());
-        assertNotNull (u2 + " is installed.", u2.getInstalled ());
-        assertNotNull (ea + " is must be installed as well because all required modules are on.", ea.getInstalled ());
-        
-    }
-    
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.netbeans.modules.autoupdate.services;
+
+import java.io.IOException;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import org.netbeans.api.autoupdate.UpdateElement;
+import org.netbeans.api.autoupdate.UpdateManager;
+import org.netbeans.api.autoupdate.UpdateUnit;
+import org.netbeans.api.autoupdate.UpdateUnitProviderFactory;
+import org.netbeans.modules.autoupdate.updateprovider.AutoupdateCatalogProvider;
+import org.netbeans.modules.autoupdate.updateprovider.ModuleItem;
+import org.netbeans.spi.autoupdate.UpdateItem;
+
+/**
+ *
+ * @author Jiri Rechtacek
+ */
+public class InstallEagerModuleTest extends NbmAdvancedTestCase {
+    
+    public InstallEagerModuleTest (String testName) {
+        super (testName);
+    }
+    
+    public void testIfAutoupdateUnderstandsEagerAttribute () throws IOException {
+        // Lookup.getDefault ().lookup (ModuleInfo.class);
+        String eagerModule = "com.sun.testmodule.eager";
+        String regularModule = "com.sun.testmodule.regular";
+        String catalog = generateCatalog (
+                generateModuleElement (eagerModule, "1.3", null, null, false, true,
+                    "org.openide.filesystems > 6.2",
+                    "org.openide.util > 6.2",
+                    "org.openide.modules > 6.2",
+                    "org.openide.nodes > 6.2",
+                    "org.openide.loaders",
+                    "org.openide.io"),
+                generateModuleElement (regularModule, "1.3", null, null, false, false,
+                    "org.openide.filesystems > 6.2",
+                    "org.openide.util > 6.2",
+                    "org.openide.modules > 6.2",
+                    "org.openide.nodes > 6.2",
+                    "org.openide.loaders",
+                    "org.openide.io")
+                
+                );
+        AutoupdateCatalogProvider p = createUpdateProvider (catalog);
+        p.refresh (true);
+        Map<String, UpdateItem> updates = p.getUpdateItems ();
+        assertNotNull ("Some modules are installed.", updates);
+        assertFalse ("Some modules are installed.", updates.isEmpty ());
+        
+        // check being 
+        assertTrue (eagerModule + " found in parsed items.", updates.keySet ().contains (eagerModule + "_1.3"));
+        assertTrue (regularModule + " found in parsed items.", updates.keySet ().contains (regularModule + "_1.3"));
+        
+        // check state
+        ModuleItem eagerModuleItem = (ModuleItem) Trampoline.SPI.impl (updates.get (eagerModule + "_1.3"));
+        ModuleItem regularModuleItem = (ModuleItem) Trampoline.SPI.impl (updates.get (regularModule + "_1.3"));
+        assertTrue (eagerModule + " is eager.", eagerModuleItem.isEager () && ! eagerModuleItem.isAutoload ());
+        assertFalse (regularModule + " is regular.", regularModuleItem.isEager () || regularModuleItem.isAutoload ());
+    }
+    
+    public void testAquireEargersFromManager () throws IOException {
+        String eagerModule = "com.sun.testmodule.eager";
+        String regularModule1 = "org.yourorghere.independent";
+        String regularModule2 = "org.yourorghere.engine";
+        String catalog = generateCatalog (
+                generateModuleElement (eagerModule, "1.0", null, null, false, true,
+                    regularModule1,
+                    regularModule2),
+                generateModuleElement (regularModule1, "1.0", null, null, false, false),
+                generateModuleElement (regularModule2, "1.0", null, null, false, false, regularModule1)
+                
+                );
+
+        UpdateUnitProviderFactory.getDefault ().create ("test-update-provider", "test-update-provider", generateFile (catalog));
+        UpdateUnitProviderFactory.getDefault ().refreshProviders (null, true);
+        
+        Set<UpdateElement> eagerElements = UpdateManagerImpl.getInstance ().getAvailableEagers ();
+        assertFalse ("Some available eagers are found.", eagerElements.isEmpty ());
+        UpdateUnit ea = UpdateManagerImpl.getInstance ().getUpdateUnit (eagerModule);
+        UpdateElement foundEaEl = eagerElements.iterator ().next ();
+        UpdateUnit foundEaU = foundEaEl.getUpdateUnit ();
+        assertEquals ("Same eager UpdateUnit", ea, foundEaU);
+        
+        // assertFalse ("Some installed eagers are found.", UpdateManagerImpl.getInstance ().getInstalledEagers ().isEmpty ());
+    }
+    
+    public void disable_testInstallRegularModule () throws IOException {
+        String eagerModule = "com.sun.testmodule.eager";
+        String regularModule1 = "org.yourorghere.independent";
+        String regularModule2 = "org.yourorghere.engine";
+        String catalog = generateCatalog (
+                generateModuleElement (eagerModule, "1.0", null, null, false, true,
+                    regularModule1,
+                    regularModule2),
+                generateModuleElement (regularModule1, "1.0", null, null, true, false),
+                generateModuleElement (regularModule2, "1.0", null, null, true, false, regularModule1)
+                
+                );
+
+        AutoupdateCatalogProvider p = createUpdateProvider (catalog);
+        p.refresh (true);
+        Map<String, UpdateItem> updates = p.getUpdateItems ();
+        
+        // initial check of updates being and its states
+        ModuleItem eagerModuleItem = (ModuleItem) Trampoline.SPI.impl (updates.get (eagerModule + "_1.0"));
+        assertFalse (eagerModuleItem.getModuleInfo ().getDependencies () + " are not empty.",
+                eagerModuleItem.getModuleInfo ().getDependencies ().isEmpty ());
+        ModuleItem regularModule1Item = (ModuleItem) Trampoline.SPI.impl (updates.get (regularModule1 + "_1.0"));
+        ModuleItem regularModule2Item = (ModuleItem) Trampoline.SPI.impl (updates.get (regularModule2 + "_1.0"));
+        assertTrue (eagerModule + " is eager.", eagerModuleItem.isEager () && ! eagerModuleItem.isAutoload ());
+        assertFalse (regularModule1 + " is regular.", regularModule1Item.isEager () || regularModule1Item.isAutoload ());
+        assertFalse (regularModule2 + " is regular.", regularModule2Item.isEager () || regularModule2Item.isAutoload ());
+        
+        // acquire UpdateUnits for test modules
+        UpdateUnitProviderFactory.getDefault ().create ("test-update-provider", "test-update-provider", generateFile (catalog));
+        UpdateUnitProviderFactory.getDefault ().refreshProviders (null, true);
+        UpdateUnit u1 = UpdateManagerImpl.getInstance ().getUpdateUnit (regularModule1);
+        assertTrue (UpdateManager.TYPE.KIT_MODULE.equals (u1.getType ()));
+        
+        //keep it to prevent GC-ed cache in UpdateManagerImpl
+        List<UpdateUnit> uuu =   UpdateManagerImpl.getInstance ().getUpdateUnits();
+        UpdateUnit u2 = UpdateManagerImpl.getInstance ().getUpdateUnit (regularModule2);
+        UpdateUnit ea = UpdateManagerImpl.getInstance ().getUpdateUnit (eagerModule);
+        assertNotNull ("Unit " + regularModule1 + " found.", u1);
+        assertNotNull ("Unit " + regularModule2 + " found.", u2);
+        assertNotNull ("Unit " + eagerModule + " found.", ea);
+        
+        // install regular module 1
+        installUpdateUnit (u1);
+
+        // check states installed regular 1 and others
+        assertNotNull (u1 + " is installed.", u1.getInstalled ());
+        assertNull (u2 + " is not installed.", u2.getInstalled ());
+        assertNull (ea + " is not installed.", ea.getInstalled ());
+        
+        // installe regular module 2
+        installUpdateUnit (u2);
+        
+        // check states installed regular 1 and others
+        assertNotNull (u1 + " is installed.", u1.getInstalled ());
+        assertNotNull (u2 + " is installed.", u2.getInstalled ());
+        assertNotNull (ea + " is must be installed as well because all required modules are on.", ea.getInstalled ());
+        
+    }
+    
+}
diff --git a/o.apache.xml.resolver/external/resolver-1.2-notice.txt b/o.apache.xml.resolver/external/resolver-1.2-notice.txt
index 214dadd56..cf064e381 100644
--- a/o.apache.xml.resolver/external/resolver-1.2-notice.txt
+++ b/o.apache.xml.resolver/external/resolver-1.2-notice.txt
@@ -1,9 +1,9 @@
-Apache XML Commons Resolver
-Copyright 2006 The Apache Software Foundation.
-
-This product includes software developed at
-The Apache Software Foundation http://www.apache.org/
-
-Portions of this code are derived from classes placed in the
-public domain by Arbortext on 10 Apr 2000. See:
-http://www.arbortext.com/customer_support/updates_and_technical_notes/catalogs/docs/README.htm
+Apache XML Commons Resolver
+Copyright 2006 The Apache Software Foundation.
+
+This product includes software developed at
+The Apache Software Foundation http://www.apache.org/
+
+Portions of this code are derived from classes placed in the
+public domain by Arbortext on 10 Apr 2000. See:
+http://www.arbortext.com/customer_support/updates_and_technical_notes/catalogs/docs/README.htm
diff --git a/o.apache.xml.resolver/external/xml-resolver-1.2-netbeans.patch b/o.apache.xml.resolver/external/xml-resolver-1.2-netbeans.patch
index 5dd98b55b..bef321464 100644
--- a/o.apache.xml.resolver/external/xml-resolver-1.2-netbeans.patch
+++ b/o.apache.xml.resolver/external/xml-resolver-1.2-netbeans.patch
@@ -19,45 +19,45 @@ diff -ruN org/apache/xml/resolver/Catalog.java patched-org/apache/xml/resolver/C
 --- org/apache/xml/resolver/Catalog.java	2006-11-20 15:23:08.000000000 +0100
 +++ patched-org/apache/xml/resolver/Catalog.java	2017-10-21 08:26:49.650587000 +0200
 @@ -393,6 +393,26 @@
-   }
- 
-   /**
-+   * Return all registered public IDs.
-+   * This method added for solving the following issues in NetBeans codebase:
-+   * http://www.netbeans.org/issues/show_bug.cgi?id=98212
-+   * and 
-+   * http://www.netbeans.org/issues/show_bug.cgi?id=112679
-+   */
-+  public java.util.Iterator getPublicIDs() {
-+      Vector v = new Vector();
-+      Enumeration enumeration = catalogEntries.elements();
-+
-+      while (enumeration.hasMoreElements()) {
-+        CatalogEntry e = (CatalogEntry) enumeration.nextElement();
-+        if (e.getEntryType() == PUBLIC) {
-+            v.add(e.getEntryArg(0));
-+        }
-+      }
-+      return v.iterator();
-+  }
-+
-+  /**
-    * Setup readers.
-    */
-   public void setupReaders() {
+   }
+ 
+   /**
++   * Return all registered public IDs.
++   * This method added for solving the following issues in NetBeans codebase:
++   * http://www.netbeans.org/issues/show_bug.cgi?id=98212
++   * and 
++   * http://www.netbeans.org/issues/show_bug.cgi?id=112679
++   */
++  public java.util.Iterator getPublicIDs() {
++      Vector v = new Vector();
++      Enumeration enumeration = catalogEntries.elements();
++
++      while (enumeration.hasMoreElements()) {
++        CatalogEntry e = (CatalogEntry) enumeration.nextElement();
++        if (e.getEntryType() == PUBLIC) {
++            v.add(e.getEntryArg(0));
++        }
++      }
++      return v.iterator();
++  }
++
++  /**
+    * Setup readers.
+    */
+   public void setupReaders() {
 diff -ruN org/apache/xml/resolver/CatalogManager.java patched-org/apache/xml/resolver/CatalogManager.java
 --- org/apache/xml/resolver/CatalogManager.java	2006-11-20 15:23:08.000000000 +0100
 +++ patched-org/apache/xml/resolver/CatalogManager.java	2017-10-21 08:27:26.850588000 +0200
 @@ -239,6 +239,9 @@
-    * resources from it.
-    */
-   private synchronized void readProperties() {
-+      if (propertyFile == null) {
-+          return;
-+      }
-     try {
-       propertyFileURI = CatalogManager.class.getResource("/"+propertyFile);
-       InputStream in =
+    * resources from it.
+    */
+   private synchronized void readProperties() {
++      if (propertyFile == null) {
++          return;
++      }
+     try {
+       propertyFileURI = CatalogManager.class.getResource("/"+propertyFile);
+       InputStream in =
 diff -ruN org/apache/xml/resolver/NbCatalogManager.java patched-org/apache/xml/resolver/NbCatalogManager.java
 --- org/apache/xml/resolver/NbCatalogManager.java	1970-01-01 01:00:00.000000000 +0100
 +++ patched-org/apache/xml/resolver/NbCatalogManager.java	2017-10-22 15:12:38.608007524 +0200
diff --git a/travis-check-line-endings.sh b/travis-check-line-endings.sh
new file mode 100755
index 000000000..8ea416419
--- /dev/null
+++ b/travis-check-line-endings.sh
@@ -0,0 +1,29 @@
+#!/bin/bash
+
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+result=$(git grep --cached -I -n --no-color $'\r')
+if [ -z "$result" ]
+then
+    echo "[OK] Checked whether line endings are LF(\\n)."
+    exit 0
+else
+    echo -e "$result"
+    echo "[Error] Found CRLF(\\r\\n). Please use LF(\\n) instead of it."
+    exit 1
+fi


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services