Raible's Wiki

Raible Designs
Wiki Home
News
Recent Changes

AppFuse

Homepage
  - Korean
  - Chinese
  - Italian
  - Japanese

QuickStart Guide
  - Chinese
  - French
  - German
  - Italian
  - Korean
  - Portuguese
  - Spanish
  - Japanese

User Guide
  - Korean
  - Chinese

Tutorials
  - Chinese
  - German
  - Italian
  - Korean
  - Portuguese
  - Spanish

FAQ
  - Korean

Latest Downloads

Other Applications

Struts Resume
Security Example
Struts Menu

Set your name in
UserPreferences


Referenced by
Articles
Articles_pt
CreateActions
CreateDAO
CreateDAO_sp
CreateDAOiBATIS
CreateDAOiBATIS_ko
CreateManager_es
JSFBeans
SpringControllers
...and 3 more




JSPWiki v2.2.33

[RSS]


Hide Menu

CreateManager


Difference between version 56 and version 55:

At line 30 changed 1 line.
The code below is what we need for a basic JUnit test of our Managers. It created and destroys our PersonManager. The "ctx" object is initialized in the [BaseManagerTestCase|http://raibledesigns.com/downloads/appfuse/api/org/appfuse/service/BaseManagerTestCase.java.html] class.
The code below is what we need for a basic JUnit test of our Managers. The code below simply creates and destroys the PersonManager. The "ctx" object is initialized in the [BaseManagerTestCase|http://raibledesigns.com/downloads/appfuse/api/org/appfuse/service/BaseManagerTestCase.java.html] class.
At line 43 removed 1 line.
//~ Static fields/initializers =============================================
At line 46 removed 3 lines.
//~ Instance fields ========================================================
At line 52 changed 4 lines.
//~ Methods ================================================================
protected void setUp() throws Exception {
protected void setUp() {
At line 59 changed 1 line.
protected void tearDown() throws Exception {
protected void tearDown() {
At line 80 changed 2 lines.
assertTrue("person.firstName not null",
person.getFirstName() != null);
assertTrue("person.firstName not null",
person.getFirstName() != null);
At line 111 changed 1 line.
assertNull(mgr.getPerson(person.getId().toString()));
assertNull(mgr.getPerson(person.getId().toString()));
At line 131 changed 1 line.
public Object getPerson(String id) throws Exception;
public List getPeople(Person person);
At line 133 changed 1 line.
public Object savePerson(Object person) throws Exception;
public Person getPerson(String id);
At line 135 changed 1 line.
public void removePerson(String id) throws Exception;
public Person savePerson(Person person);
public void removePerson(String id);
At line 146 added 1 line.
import java.util.List;
At line 148 added 4 lines.
/**
* @author mraible
* @version $Revision: $ $Date: May 25, 2004 11:46:54 PM $
*/
At line 160 changed 1 line.
public Object getPerson(String id) throws Exception {
public List getPeople(Person person) {
return dao.getPeople();
}
public Person getPerson(String id) {
At line 164 changed 2 lines.
public Object savePerson(Object obj) throws Exception {
Person person = (Person) obj;
public Person savePerson(Person person) {
At line 167 removed 1 line.
At line 171 changed 1 line.
public void removePerson(String id) throws Exception {
public void removePerson(String id) {
At line 195 removed 1 line.
<!-- Person Manager -->

Back to CreateManager, or to the Page History.