1 /****************************************************************************** 2 * TestGameManager.java - Test the Game Manager 3 * $Id$ 4 * 5 * BuckoFIBS - Backgammon by BuckoSoft 6 * Copyright© 2011 - Dick Balaska - BuckoSoft, Corp. 7 * 8 * $Log$ 9 * Revision 1.12 2011/06/10 20:38:09 dick 10 * yourMove() is not public anymore as it only comes from the AnimateManager. 11 * 12 * Revision 1.11 2011/06/10 05:59:58 dick 13 * getPlayPause() becomes isPlayPaused(). 14 * 15 * Revision 1.10 2011/06/05 06:47:46 dick 16 * Make writeGameMessageLn(s) public. 17 * 18 * Revision 1.9 2011/06/02 18:49:22 dick 19 * compile cleanups (no real work here). 20 * 21 * Revision 1.8 2011/05/23 05:59:29 dick 22 * Need playSound. 23 * 24 * Revision 1.7 2011/05/23 03:24:54 dick 25 * Need PlayPause handling. 26 * 27 * Revision 1.6 2011/05/21 05:08:37 dick 28 * Just kill some to do tags. 29 * 30 * Revision 1.5 2011/05/15 02:20:12 dick 31 * Move a whole bunch of packages around. 32 * 33 * Revision 1.4 2011/05/14 05:20:02 dick 34 * I needed to deal with some lightweight Boards. 35 * So finally make the primary document Document 36 * and demote just the Board handling to a domain object. 37 * 38 * Revision 1.3 2011/05/13 15:06:20 dick 39 * Fix the non-functional tests. (Third checkin and DDS). 40 * 41 * Revision 1.2 2011/05/11 22:25:04 dick 42 * Early GameManager tests. 43 * 44 * Revision 1.1 2011/05/10 05:55:33 dick 45 * GameManager test skeleton. 46 * 47 */ 48 49 /* 50 * This program is free software: you can redistribute it and/or modify 51 * it under the terms of the GNU General Public License as published by 52 * the Free Software Foundation, either version 3 of the License, or 53 * (at your option) any later version. 54 * 55 * This program is distributed in the hope that it will be useful, 56 * but WITHOUT ANY WARRANTY; without even the implied warranty of 57 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 58 * GNU General Public License for more details. 59 * 60 * You should have received a copy of the GNU General Public License 61 * along with this program. If not, see <http://www.gnu.org/licenses/>. 62 * 63 * The Original Code is BuckoFIBS, <http://www.buckosoft.com/BuckoFIBS/>. 64 * The Initial Developer of the Original Code is Dick Balaska and BuckoSoft, Corp. 65 * 66 */ 67 package com.buckosoft.fibs.BuckoFIBS; 68 69 import static org.junit.Assert.fail; 70 71 import org.junit.Before; 72 import org.junit.Ignore; 73 import org.junit.Test; 74 75 import com.buckosoft.fibs.BuckoFIBS.AudioManager.Cue; 76 import com.buckosoft.fibs.BuckoFIBS.gui.MainDialogI; 77 import com.buckosoft.fibs.BuckoFIBS.gui.boardTab.ReplayToolbarI; 78 import com.buckosoft.fibs.BuckoFIBS.gui.boardTab.ToolbarHandler; 79 import com.buckosoft.fibs.document.Document; 80 import com.buckosoft.fibs.domain.gameEvent.GameEvent; 81 import com.buckosoft.swing.JButtonI; 82 import com.buckosoft.swing.JUButton; 83 84 /** Test the GameManager 85 * @since 2011/05/09 86 * @author Dick Balaska 87 * @see <a href="http://cvs.buckosoft.com/Projects/BuckoFIBS/BuckoFIBS/src/test/java/com/buckosoft/fibs/test/BuckoFIBS/TestGameManager.java">cvs TestGameManager.java</a> 88 * 89 */ 90 @Ignore 91 public class TestGameManager { 92 ReplayToolbarI replayToolbar; 93 MainDialogI harnessMainDialog; 94 /** 95 * @throws java.lang.Exception 96 */ 97 @Before 98 public void setUp() throws Exception { 99 replayToolbar = new ReplayToolbar(); 100 harnessMainDialog = new HarnessMainDialog(); 101 } 102 103 /** 104 * Test method for {@link com.buckosoft.fibs.BuckoFIBS.GameManager#GameManager()}. 105 */ 106 @Test 107 public void testGameManager() { 108 fail("Not yet implemented"); 109 } 110 111 /** 112 * Test method for {@link com.buckosoft.fibs.BuckoFIBS.GameManager#setReplayToolbar(com.buckosoft.fibs.BuckoFIBS.gui.boardTab.ReplayToolbarI)}. 113 */ 114 @Test 115 public void testSetReplayToolbar() { 116 fail("Not yet implemented"); 117 } 118 119 /** 120 * Test method for {@link com.buckosoft.fibs.BuckoFIBS.GameManager#setMainDialog(com.buckosoft.fibs.BuckoFIBS.gui.MainDialog)}. 121 */ 122 @Test 123 public void testSetMainDialog() { 124 fail("Not yet implemented"); 125 } 126 127 /** 128 * Test method for {@link com.buckosoft.fibs.BuckoFIBS.GameManager#reset(boolean)}. 129 */ 130 @Test 131 public void testReset() { 132 fail("Not yet implemented"); 133 } 134 135 /** 136 * Test method for {@link com.buckosoft.fibs.BuckoFIBS.GameManager#addEvent(com.buckosoft.fibs.domain.CookieString)}. 137 */ 138 @Test 139 public void testAddEvent() { 140 fail("Not yet implemented"); 141 } 142 143 /** 144 * Test method for {@link com.buckosoft.fibs.BuckoFIBS.GameManager#goFirst()}. 145 */ 146 @Test 147 public void testGoFirst() { 148 fail("Not yet implemented"); 149 } 150 151 /** 152 * Test method for {@link com.buckosoft.fibs.BuckoFIBS.GameManager#goPrev()}. 153 */ 154 @Test 155 public void testGoPrev() { 156 fail("Not yet implemented"); 157 } 158 159 /** 160 * Test method for {@link com.buckosoft.fibs.BuckoFIBS.GameManager#goNext()}. 161 */ 162 @Test 163 public void testGoNext() { 164 fail("Not yet implemented"); 165 } 166 167 /** 168 * Test method for {@link com.buckosoft.fibs.BuckoFIBS.GameManager#goLast()}. 169 */ 170 @Test 171 public void testGoLast() { 172 fail("Not yet implemented"); 173 } 174 175 /** 176 * Test method for {@link com.buckosoft.fibs.BuckoFIBS.GameManager#goUndo()}. 177 */ 178 @Test 179 public void testGoUndo() { 180 fail("Not yet implemented"); 181 } 182 183 private class ReplayToolbar implements ReplayToolbarI { 184 185 @Override 186 public JButtonI getJButtonBack() { 187 return null; 188 } 189 190 @Override 191 public JUButton getJButtonEnd() { 192 return null; 193 } 194 195 @Override 196 public JUButton getJButtonFirst() { 197 return null; 198 } 199 200 @Override 201 public JUButton getJButtonNext() { 202 return null; 203 } 204 205 @Override 206 public void setToolbarHandler(ToolbarHandler toolbarHandler) { 207 } 208 209 @Override 210 public boolean isPlayPause() { 211 return false; 212 } 213 214 @Override 215 public void setPlayPause(boolean playPause) { 216 } 217 218 } 219 220 private class HarnessMainDialog implements MainDialogI { 221 222 @Override 223 public Document getDocument() { 224 return null; 225 } 226 227 @Override 228 public void updateBoard() { 229 230 } 231 232 @Override 233 public void moveEvent(GameEvent gameEvent) { 234 235 } 236 237 @Override 238 public void playSound(Cue cue) { 239 } 240 241 @Override 242 public void writeGameMessageln(String s) { 243 244 } 245 } 246 }