📄 viewmythreadactiontest.java
字号:
/* * XP Forum * * Copyright (c) 2002-2003 RedSoft Group. All rights reserved. * */package org.redsoft.forum.web;import org.redsoft.forum.dao.DAOFactory;import org.redsoft.forum.ForumConstants;/** * TestCase for ViewMyThreadAction */public class ViewMyThreadActionTest extends MyMockStrutsTestCase { public ViewMyThreadActionTest(String s) { super(s); } public void setUp() throws Exception { super.setUp(); DAOFactory.buildMockDAOFactory(); // logon first before editing account addRequestParameter("userName", "User1"); addRequestParameter("password", "111111"); setRequestPathInfo("/logon"); actionPerform(); } public void testOk() { setRequestPathInfo("/viewMyThreads"); actionPerform(); verifyNoActionErrors(); verifyForward( "success" ); assertNotNull( "startIndex in request", getRequest().getAttribute( ForumConstants.START_INDEX_PARAM ) ); assertNotNull( "endIndex in request", getRequest().getAttribute( ForumConstants.END_INDEX_PARAM ) ); assertNotNull( "thread count in request", getRequest().getAttribute( ForumConstants.THREAD_COUNT_PARAM ) ); assertNotNull( "threads in request", getRequest().getAttribute( ForumConstants.MY_THREAD_PARAM ) ); assertNotNull( "account in request",getRequest().getAttribute( ForumConstants.ACCOUNT ) ); }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -