Skip to content

Commit

Permalink
Add new repo, and enabling versionless tests
Browse files Browse the repository at this point in the history
  • Loading branch information
cbridgha committed Jul 17, 2024
1 parent d5a3db5 commit 38d2dd2
Show file tree
Hide file tree
Showing 5 changed files with 38 additions and 6 deletions.
4 changes: 2 additions & 2 deletions dev/com.ibm.ws.install.featureUtility_fat/build.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* Copyright (c) 2021, 2023 IBM Corporation and others.
/* Copyright (c) 2021, 2024 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
* which accompanies this distribution, and is available at
Expand All @@ -18,7 +18,7 @@ addRequiredLibraries {

dependencies {
usrFeatures 'test.featureUtility_fat:userFeature:1.0@zip'
features 'test.featureUtility_fat:Archive:1.0@zip'
features 'test.featureUtility_fat:Archive:2.0@zip'
requiredLibs project(':com.ibm.ws.org.slf4j.api'),
project(':com.ibm.ws.org.slf4j.simple')
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public class FATSuite extends TestContainerSuite {
public static void beforeSuite() throws Exception {
FeatureUtilityToolTest.setupEnv();
FeatureUtilityToolTest.constructLocalMavenRepo(Paths.get("publish/repo/userFeature/userFeature-1.0.zip"));
FeatureUtilityToolTest.constructLocalMavenRepo(Paths.get("publish/repo/archive/Archive-1.0.zip"));
FeatureUtilityToolTest.constructLocalMavenRepo(Paths.get("publish/repo/archive/Archive-2.0.zip"));
}

@AfterClass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public abstract class FeatureUtilityToolTest {

private static final Class<?> c = FeatureUtilityToolTest.class;

protected static String libertyVersion = "23.0.0.2";
protected static String libertyVersion = "24.0.0.8";
// ${buildDir}/publish/repo
protected static String mavenLocalRepo = Paths.get("publish/repo/").toAbsolutePath().toString();
public static LibertyServer server;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ public void testInvalidMultiVersionFeatures() throws Exception {
*
* @throws Exception
*/
@Ignore

@Test
public void testVersionlessWithBadPlatformFeatures() throws Exception {
final String METHOD_NAME = "testVersionlessWithBadPlatformFeatures";
Expand All @@ -183,7 +183,7 @@ public void testVersionlessWithBadPlatformFeatures() throws Exception {
*
* @throws Exception
*/
@Ignore

@Test
public void testVersionlessWithNoPlatformFeatures() throws Exception {
final String METHOD_NAME = "testVersionlessWithNoPlatformFeatures";
Expand All @@ -198,6 +198,28 @@ public void testVersionlessWithNoPlatformFeatures() throws Exception {
Log.exiting(c, METHOD_NAME);
}

/**
* Test the install of versionless with platform name. install servlet-6.0 feature
*
* @throws Exception
*/

@Test
public void testVersionlessWithPlatformFeatures() throws Exception {
final String METHOD_NAME = "testVersionlessWithPlatformFeatures";
Log.entering(c, METHOD_NAME);

copyFileToMinifiedRoot("usr/servers/serverX", "publish/tmp/versionlessWithPlatform/server.xml");

String[] param1s = { "installServerFeatures", "serverX", "--verbose" };
String[] filesList = { "/lib/features/com.ibm.websphere.appserver.servlet-6.0.mf" };

ProgramOutput po = runFeatureUtility(METHOD_NAME, param1s);

checkCommandOutput(po, 0, null, filesList); //Should have servlet-6.0
Log.exiting(c, METHOD_NAME);
}

/**
* Install an user feature with the "--featuresBom" parameters
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<server description="new server">

<!-- Enable features -->
<featureManager>
<platform>jakartaee-10.0</platform>
<feature>servlet</feature>
</featureManager>
</server>

0 comments on commit 38d2dd2

Please sign in to comment.