[jbpm-commits] JBoss JBPM SVN: r5831 - in jbpm4/trunk/modules/test-db: src/test/java/org/jbpm/test/activity and 1 other directories.
do-not-reply at jboss.org
do-not-reply at jboss.org
Wed Oct 28 11:11:38 EDT 2009
Author: tom.baeyens at jboss.com
Date: 2009-10-28 11:11:38 -0400 (Wed, 28 Oct 2009)
New Revision: 5831
Added:
jbpm4/trunk/modules/test-db/src/test/java/org/jbpm/test/activity/mail/
jbpm4/trunk/modules/test-db/src/test/java/org/jbpm/test/activity/mail/MailTest.java
Modified:
jbpm4/trunk/modules/test-db/pom.xml
Log:
added extra mail test in test-db module
Modified: jbpm4/trunk/modules/test-db/pom.xml
===================================================================
--- jbpm4/trunk/modules/test-db/pom.xml 2009-10-28 14:47:18 UTC (rev 5830)
+++ jbpm4/trunk/modules/test-db/pom.xml 2009-10-28 15:11:38 UTC (rev 5831)
@@ -48,17 +48,21 @@
<scope>test</scope>
</dependency>
<dependency>
+ <groupId>org.jbpm.jbpm4</groupId>
+ <artifactId>jbpm-console-reports</artifactId>
+ <scope>test</scope>
+ </dependency>
+
+ <dependency>
<groupId>org.springframework</groupId>
<artifactId>spring</artifactId>
<scope>test</scope>
</dependency>
-
<dependency>
- <groupId>org.jbpm.jbpm4</groupId>
- <artifactId>jbpm-console-reports</artifactId>
+ <groupId>org.subethamail</groupId>
+ <artifactId>subethasmtp-wiser</artifactId>
<scope>test</scope>
- </dependency>
-
+ </dependency>
</dependencies>
<build>
Added: jbpm4/trunk/modules/test-db/src/test/java/org/jbpm/test/activity/mail/MailTest.java
===================================================================
--- jbpm4/trunk/modules/test-db/src/test/java/org/jbpm/test/activity/mail/MailTest.java (rev 0)
+++ jbpm4/trunk/modules/test-db/src/test/java/org/jbpm/test/activity/mail/MailTest.java 2009-10-28 15:11:38 UTC (rev 5831)
@@ -0,0 +1,71 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.test.activity.mail;
+
+import java.util.List;
+
+import org.jbpm.test.JbpmTestCase;
+import org.subethamail.wiser.Wiser;
+import org.subethamail.wiser.WiserMessage;
+
+/**
+ * @author Tom Baeyens
+ */
+public class MailTest extends JbpmTestCase {
+
+ Wiser wiser = null;
+
+ protected void setUp() throws Exception {
+ super.setUp();
+ // start mail server
+ wiser = new Wiser();
+ wiser.setPort(2525);
+ wiser.start();
+ }
+
+ protected void tearDown() throws Exception {
+ wiser.stop();
+ super.tearDown();
+ }
+
+ public void testMailToPlainAddress() {
+ deployJpdlXmlString(
+ "<process name='MailTest'>" +
+ " <start>" +
+ " <transition to='mailtestmail' />" +
+ " </start>" +
+ " <mail name='mailtestmail'>" +
+ " <to addresses='jos at rubensstraat' />" +
+ " <subject>mail</subject>" +
+ " <text>youhoooo</text>" +
+ " <transition to='end' />" +
+ " </mail>" +
+ " <state name='end'/>" +
+ "</process>"
+ );
+
+ executionService.startProcessInstanceByKey("MailTest");
+
+ List<WiserMessage> messages = wiser.getMessages();
+ assertEquals(1, messages.size());
+ }
+}
Property changes on: jbpm4/trunk/modules/test-db/src/test/java/org/jbpm/test/activity/mail/MailTest.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
More information about the jbpm-commits
mailing list