|
From: Greg R. <gr...@us...> - 2004-04-01 23:13:38
|
Update of /cvsroot/jgatms/jgatms-core/src/test/inklings/jgatms/command In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv884/src/test/inklings/jgatms/command Modified Files: AddResponseToQuestionTest.java GetMemberListTest.java GetQuestionTest.java GetQuestionsTest.java GetResponsesTest.java GetSkillsListTest.java Log Message: Now using JgatmsContext instead of ContextBase. Index: GetSkillsListTest.java =================================================================== RCS file: /cvsroot/jgatms/jgatms-core/src/test/inklings/jgatms/command/GetSkillsListTest.java,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** GetSkillsListTest.java 29 Jan 2004 23:38:25 -0000 1.1.1.1 --- GetSkillsListTest.java 1 Apr 2004 23:01:36 -0000 1.2 *************** *** 9,12 **** --- 9,13 ---- import org.apache.commons.chain.impl.ContextBase; + import inklings.jgatms.context.JgatmsContext; import inklings.jgatms.ContextKeys; import inklings.jgatms.CommandKeys; *************** *** 24,33 **** */ public void testGetSkillsList() throws Exception { ! Context context = new ContextBase(); Command command = catalog.getCommand(CommandKeys.GET_SKILLS_LIST); assertNotNull(CommandKeys.GET_SKILLS_LIST + " not found.", command); command.execute(context); ! String dispatch = (String) context.get(ContextKeys.DISPATCH_KEY); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); --- 25,34 ---- */ public void testGetSkillsList() throws Exception { ! JgatmsContext context = new JgatmsContext(); Command command = catalog.getCommand(CommandKeys.GET_SKILLS_LIST); assertNotNull(CommandKeys.GET_SKILLS_LIST + " not found.", command); command.execute(context); ! String dispatch = context.getDispatch(); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); Index: GetQuestionTest.java =================================================================== RCS file: /cvsroot/jgatms/jgatms-core/src/test/inklings/jgatms/command/GetQuestionTest.java,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** GetQuestionTest.java 29 Jan 2004 23:38:37 -0000 1.1.1.1 --- GetQuestionTest.java 1 Apr 2004 23:01:36 -0000 1.2 *************** *** 9,12 **** --- 9,13 ---- import org.apache.commons.chain.impl.ContextBase; + import inklings.jgatms.context.JgatmsContext; import inklings.jgatms.CommandKeys; import inklings.jgatms.ContextKeys; *************** *** 23,27 **** */ public void testGetQuestion() throws Exception { ! Context context = new ContextBase(); context.put(ContextKeys.QUESTION_ID_KEY, new Long(0)); Command command = catalog.getCommand(CommandKeys.GET_QUESTION); --- 24,28 ---- */ public void testGetQuestion() throws Exception { ! JgatmsContext context = new JgatmsContext(); context.put(ContextKeys.QUESTION_ID_KEY, new Long(0)); Command command = catalog.getCommand(CommandKeys.GET_QUESTION); *************** *** 29,33 **** command.execute(context); ! String dispatch = (String) context.get(ContextKeys.DISPATCH_KEY); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); --- 30,34 ---- command.execute(context); ! String dispatch = context.getDispatch(); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); Index: AddResponseToQuestionTest.java =================================================================== RCS file: /cvsroot/jgatms/jgatms-core/src/test/inklings/jgatms/command/AddResponseToQuestionTest.java,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** AddResponseToQuestionTest.java 29 Jan 2004 23:38:37 -0000 1.1.1.1 --- AddResponseToQuestionTest.java 1 Apr 2004 23:01:36 -0000 1.2 *************** *** 9,12 **** --- 9,13 ---- import org.apache.commons.chain.impl.ContextBase; + import inklings.jgatms.context.JgatmsContext; import inklings.jgatms.CommandKeys; import inklings.jgatms.ContextKeys; *************** *** 24,28 **** public void testAddResponseToQuestion() throws Exception { ! Context context = new ContextBase(); Command command = catalog.getCommand(CommandKeys.GET_QUESTION); assertNotNull(CommandKeys.GET_QUESTION + " not found", command); --- 25,29 ---- public void testAddResponseToQuestion() throws Exception { ! JgatmsContext context = new JgatmsContext(); Command command = catalog.getCommand(CommandKeys.GET_QUESTION); assertNotNull(CommandKeys.GET_QUESTION + " not found", command); *************** *** 31,35 **** context.put(ContextKeys.QUESTION_ID_KEY, questionId); command.execute(context); ! String dispatch = (String) context.get(ContextKeys.DISPATCH_KEY); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); --- 32,36 ---- context.put(ContextKeys.QUESTION_ID_KEY, questionId); command.execute(context); ! String dispatch = context.getDispatch(); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); *************** *** 47,51 **** context.put(ContextKeys.QUESTION_KEY, question); command.execute(context); ! dispatch = (String) context.get(ContextKeys.DISPATCH_KEY); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); --- 48,52 ---- context.put(ContextKeys.QUESTION_KEY, question); command.execute(context); ! dispatch = context.getDispatch(); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); Index: GetMemberListTest.java =================================================================== RCS file: /cvsroot/jgatms/jgatms-core/src/test/inklings/jgatms/command/GetMemberListTest.java,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** GetMemberListTest.java 29 Jan 2004 23:38:37 -0000 1.1.1.1 --- GetMemberListTest.java 1 Apr 2004 23:01:36 -0000 1.2 *************** *** 9,12 **** --- 9,13 ---- import org.apache.commons.chain.impl.ContextBase; + import inklings.jgatms.context.JgatmsContext; import inklings.jgatms.CommandKeys; import inklings.jgatms.ContextKeys; *************** *** 30,39 **** public void testGetMemberList() throws Exception { ! Context context = new ContextBase(); Command command = catalog.getCommand(CommandKeys.GET_MEMBER_LIST); assertNotNull(CommandKeys.GET_MEMBER_LIST + " not found", command); command.execute(context); ! String dispatch = (String) context.get(ContextKeys.DISPATCH_KEY); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); --- 31,40 ---- public void testGetMemberList() throws Exception { ! JgatmsContext context = new JgatmsContext(); Command command = catalog.getCommand(CommandKeys.GET_MEMBER_LIST); assertNotNull(CommandKeys.GET_MEMBER_LIST + " not found", command); command.execute(context); ! String dispatch = context.getDispatch(); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); Index: GetQuestionsTest.java =================================================================== RCS file: /cvsroot/jgatms/jgatms-core/src/test/inklings/jgatms/command/GetQuestionsTest.java,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** GetQuestionsTest.java 29 Jan 2004 23:38:37 -0000 1.1.1.1 --- GetQuestionsTest.java 1 Apr 2004 23:01:36 -0000 1.2 *************** *** 9,12 **** --- 9,13 ---- import org.apache.commons.chain.impl.ContextBase; + import inklings.jgatms.context.JgatmsContext; import inklings.jgatms.CommandKeys; import inklings.jgatms.ContextKeys; *************** *** 23,32 **** */ public void testGetQuestions() throws Exception { ! Context context = new ContextBase(); Command command = catalog.getCommand(CommandKeys.GET_QUESTIONS); assertNotNull(CommandKeys.GET_QUESTIONS + " not found.", command); command.execute(context); ! String dispatch = (String) context.get(ContextKeys.DISPATCH_KEY); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); --- 24,33 ---- */ public void testGetQuestions() throws Exception { ! JgatmsContext context = new JgatmsContext(); Command command = catalog.getCommand(CommandKeys.GET_QUESTIONS); assertNotNull(CommandKeys.GET_QUESTIONS + " not found.", command); command.execute(context); ! String dispatch = context.getDispatch(); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); Index: GetResponsesTest.java =================================================================== RCS file: /cvsroot/jgatms/jgatms-core/src/test/inklings/jgatms/command/GetResponsesTest.java,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** GetResponsesTest.java 29 Jan 2004 23:38:37 -0000 1.1.1.1 --- GetResponsesTest.java 1 Apr 2004 23:01:36 -0000 1.2 *************** *** 9,12 **** --- 9,13 ---- import org.apache.commons.chain.impl.ContextBase; + import inklings.jgatms.context.JgatmsContext; import inklings.jgatms.CommandKeys; import inklings.jgatms.ContextKeys; *************** *** 23,32 **** */ public void testGetResponses() throws Exception { ! Context context = new ContextBase(); Command command = catalog.getCommand(CommandKeys.GET_RESPONSES); assertNotNull(CommandKeys.GET_RESPONSES + " not found.", command); command.execute(context); ! String dispatch = (String) context.get(ContextKeys.DISPATCH_KEY); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); --- 24,33 ---- */ public void testGetResponses() throws Exception { ! JgatmsContext context = new JgatmsContext(); Command command = catalog.getCommand(CommandKeys.GET_RESPONSES); assertNotNull(CommandKeys.GET_RESPONSES + " not found.", command); command.execute(context); ! String dispatch = context.getDispatch(); assertTrue("Unsuccessful command execution.", dispatch.equals(ContextKeys.SUCCESS_DISPATCH)); |