日期:2014-05-19 浏览次数:20838 次
WARNING: [12:27.926] Couldn't determine real path of resource class path resource [org/apache/struts2/dispatcher/error_zh_CN.ftl]
WARNING: [12:27.926] Couldn't determine real path of resource class path resource [org/apache/struts2/dispatcher/error_zh.ftl]
WARNING: [12:27.926] Couldn't determine real path of resource class path resource [org/apache/struts2/dispatcher/error.ftl]
public class HelloActionTest extends StrutsSpringTestCase{
@Test
public void testExecute() throws Exception{
executeAction("/hello");
}
}
public class HelloAction extends ActionSupport {
private People people;
public String execute(){
people.hello();
return SUCCESS;
}
public void setPeople(People people) {
this.people = people;
}
}
public class People {
private Long id;
private String name;
public void hello(){
System.out.println("Hello World!");
}
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
}