mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Fixed : ALF-12532: MMT should fail with an error if the target war file doesn't exist
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@33725 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -294,20 +294,27 @@ public class ModuleManagementToolTest extends TestCase
|
||||
return file.getPath();
|
||||
}
|
||||
|
||||
// public void testNoWar() throws Exception
|
||||
// {
|
||||
// File noWar = new File("noWar");
|
||||
// File amp = getFile(".amp", "module/test_v1.amp");
|
||||
// try
|
||||
// {
|
||||
// this.manager.installModule(amp, noWar,false,false);
|
||||
// }
|
||||
// catch (ModuleManagementToolException exception)
|
||||
// {
|
||||
// assertTrue(exception.getMessage().endsWith("does not exist."));
|
||||
// }
|
||||
//
|
||||
// }
|
||||
public void testNoWar() throws Exception
|
||||
{
|
||||
String noWar = "noWar";
|
||||
String ampLocation = getFileLocation(".amp", "module/test_v1.amp");
|
||||
try
|
||||
{
|
||||
this.manager.installModule(ampLocation, noWar,false,false, false);
|
||||
}
|
||||
catch (ModuleManagementToolException exception)
|
||||
{
|
||||
assertTrue(exception.getMessage().endsWith("does not exist."));
|
||||
}
|
||||
try
|
||||
{
|
||||
this.manager.installModule(ampLocation, noWar,false,false, true); //backup war
|
||||
}
|
||||
catch (ModuleManagementToolException exception)
|
||||
{
|
||||
assertTrue(exception.getMessage().endsWith("does not exist."));
|
||||
}
|
||||
}
|
||||
|
||||
private void checkForFileExistance(String warLocation, List<String> files)
|
||||
{
|
||||
|
Reference in New Issue
Block a user