StrutsTestCase 中setRequestPathInfo出错

carolineREN 2007-03-29 09:28:00
在使用StrutsTestCase的时候出现了问题.
在struts-config.xml中配置如下:
<form-bean name="registerForm" type="app.RegisterForm">
</form-bean>
<action path= "/registerAction"
type= "app.RegisterAction"
name= "registerForm"
input="/input.jsp"/>

RegisterTest中如下:
public void testSuccessfulLogin(){
setRequestPathInfo("/registerAction");
addRequestParameter("password1","aaa");
addRequestParameter("password2","aaa");
actionPerform();
verifyForward("success");

}
可是执行这个测试用列的时候,总是提示
ClassNotDefineError:
at setRequestPathInfo.....
好像是setRequestPathInfo中的时候找不到registerAction 可是我明明已经配置好了的啊
不知道为什么,请教.

...全文
173 2 打赏 收藏 转发到动态 举报
AI 作业
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
craig_wolfdon 2007-03-30
  • 打赏
  • 举报
回复
没用过这种测试工具的,不过应该是路径问题,或者说是你测试工具的配置问题,感觉,你直接执行的时候有问题吗
yeah920 2007-03-30
  • 打赏
  • 举报
回复
up

81,121

社区成员

发帖
与我相关
我的任务
社区描述
Java Web 开发
社区管理员
  • Web 开发社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧