Introduction to EJB JNDI Lookup on WildFly Application Server - Alejandro Gervasio | alejandro.gervasio@gmail.com (#2417)
* Initial Commit * jboss-ejb-client.properties file * Updated jboss-ejb-client.properties file
This commit is contained in:
committed by
Zeger Hendrikse
parent
9b2e8ec9f9
commit
e13204ca96
@@ -0,0 +1,10 @@
|
||||
package com.baeldung.ejbmodule;
|
||||
|
||||
import javax.ejb.Stateless;
|
||||
|
||||
@Stateless
|
||||
public class TextProcessorBean implements TextProcessorRemote {
|
||||
public String processText(String text) {
|
||||
return text.toUpperCase();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
package com.baeldung.ejbmodule;
|
||||
|
||||
import javax.ejb.Remote;
|
||||
|
||||
@Remote
|
||||
public interface TextProcessorRemote {
|
||||
|
||||
String processText(String text);
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
package com.baeldung.ejbmodule;
|
||||
|
||||
import org.junit.Test;
|
||||
import static org.junit.Assert.assertEquals;
|
||||
|
||||
public class TextProcessorBeanTest {
|
||||
@Test
|
||||
public void givenInputString_whenComparedToStringParsedByBean_thenSuccessful() {
|
||||
TextProcessorBean textProcessor = new TextProcessorBean();
|
||||
assertEquals("TEST", textProcessor.processText("test"));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user