removed obsolete test
This commit is contained in:
parent
236d29f054
commit
6cc80228e0
15
pom.xml
15
pom.xml
|
@ -22,11 +22,11 @@
|
|||
|
||||
<properties>
|
||||
<!-- Convenience property to set the GWT version -->
|
||||
<gwtVersion>2.7.0</gwtVersion>
|
||||
<gwtVersion>2.8.2</gwtVersion>
|
||||
|
||||
<!-- GWT needs at least java 1.6 -->
|
||||
<maven.compiler.source>1.7</maven.compiler.source>
|
||||
<maven.compiler.target>1.7</maven.compiler.target>
|
||||
<maven.compiler.source>1.8</maven.compiler.source>
|
||||
<maven.compiler.target>1.8</maven.compiler.target>
|
||||
<distroDirectory>distro</distroDirectory>
|
||||
<webappDirectory>${project.build.directory}/${project.build.finalName}</webappDirectory>
|
||||
<liferayVersion>6.2.5</liferayVersion>
|
||||
|
@ -105,13 +105,12 @@
|
|||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.gcube.applicationsupportlayer</groupId>
|
||||
<artifactId>aslsocial</artifactId>
|
||||
<scope>provided</scope>
|
||||
<groupId>org.gcube.common</groupId>
|
||||
<artifactId>storagehub-client-library</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.gcube.common</groupId>
|
||||
<artifactId>home-library</artifactId>
|
||||
<groupId>org.gcube.applicationsupportlayer</groupId>
|
||||
<artifactId>aslsocial</artifactId>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
|
|
|
@ -16,8 +16,8 @@ import org.gcube.applicationsupportlayer.social.ApplicationNotificationsManager;
|
|||
import org.gcube.applicationsupportlayer.social.NotificationsManager;
|
||||
import org.gcube.applicationsupportlayer.social.shared.SocialNetworkingSite;
|
||||
import org.gcube.applicationsupportlayer.social.shared.SocialNetworkingUser;
|
||||
import org.gcube.common.homelibrary.home.HomeLibrary;
|
||||
import org.gcube.common.homelibrary.home.workspace.Workspace;
|
||||
import org.gcube.common.storagehub.client.plugins.AbstractPlugin;
|
||||
import org.gcube.common.storagehub.client.proxies.MessageManagerClient;
|
||||
import org.gcube.portal.custom.scopemanager.scopehelper.ScopeHelper;
|
||||
import org.gcube.portlets.admin.vredefinition.client.VREDefinitionService;
|
||||
import org.gcube.portlets.admin.vredefinition.shared.Functionality;
|
||||
|
@ -601,19 +601,22 @@ public class VREDefinitionServiceImpl extends RemoteServiceServlet implements V
|
|||
getVREGenerator().setVREtoPendingState();
|
||||
|
||||
getASLSession().setAttribute(VRE_DEFINER_GENERATOR_ATTRIBUTE, null);
|
||||
Workspace workspace = HomeLibrary.getUserWorkspace(getASLSession().getUsername());
|
||||
|
||||
ArrayList<String> toSend = new ArrayList<String>();
|
||||
toSend.add(managerUserName);
|
||||
String subject = "New VRE Definition requires your approval";
|
||||
String body = "Dear Manager, \n\n" + completeDesigner + " has created a VRE Definition indicating you as VRE Manager on " + getASLSession().getScope();
|
||||
body+=".\n\nThe VRE Name is: " + bean.getName() +", the VRE Description is: " + bean.getDescription()+".";
|
||||
String messagedId = workspace.getWorkspaceMessageManager().sendMessageToPortalLogins(subject, body, new ArrayList<String>(), toSend);
|
||||
|
||||
|
||||
MessageManagerClient client = AbstractPlugin.messages().build();
|
||||
String messageId = client.sendMessage(toSend, subject, body, null);
|
||||
|
||||
|
||||
ASLSession session = getASLSession();
|
||||
SocialNetworkingUser user = new SocialNetworkingUser(session.getUsername(), session.getUserEmailAddress(), session.getUserFullName(), session.getUserAvatarId());
|
||||
NotificationsManager nnm = new ApplicationNotificationsManager(new SocialNetworkingSite(getThreadLocalRequest()), session.getScope(), user);
|
||||
|
||||
if (nnm.notifyMessageReceived(managerUserName, messagedId, subject, body))
|
||||
if (nnm.notifyMessageReceived(managerUserName, messageId, subject, body))
|
||||
logger.trace("Sending VRE Definition create notification: " + subject + " OK");
|
||||
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
<!-- If you add any GWT meta tags, they must -->
|
||||
<!-- be added before this line. -->
|
||||
<!-- -->
|
||||
<script type="text/javascript" src="vredefinition/vredefinition.nocache.js"></script>
|
||||
<!-- <script type="text/javascript" src="vredefinition/vredefinition.nocache.js"></script> -->
|
||||
</head>
|
||||
|
||||
<!-- -->
|
||||
|
|
|
@ -1,19 +0,0 @@
|
|||
package org.gcube.portlets.admin.vredefinition.client;
|
||||
|
||||
import static org.junit.Assert.assertTrue;
|
||||
|
||||
import org.gcube.portlets.admin.vredefinition.server.VREDefinitionServiceImpl;
|
||||
import org.junit.Test;
|
||||
|
||||
public class TestForDeploy {
|
||||
|
||||
@Test
|
||||
public void testUserIsTestUser() {
|
||||
VREDefinitionServiceImpl serviceImpl = new VREDefinitionServiceImpl();
|
||||
String username = serviceImpl.getDevelopmentUser();
|
||||
System.out.println("username for deploy is: " + username);
|
||||
assertTrue(username.compareTo(VREDefinitionServiceImpl.defaultUserId) == 0);
|
||||
System.out.println("Test OK!");
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in New Issue