Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. /* *******************************************************************
  2. * Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC).
  3. * All rights reserved.
  4. * This program and the accompanying materials are made available
  5. * under the terms of the Common Public License v1.0
  6. * which accompanies this distribution and is available at
  7. * http://www.eclipse.org/legal/cpl-v10.html
  8. *
  9. * Contributors:
  10. * PARC initial implementation
  11. * ******************************************************************/
  12. package tests;
  13. import figures.*;
  14. import support.Log;
  15. import junit.framework.*;
  16. public class Test1a extends Test {
  17. public Test1a(String name) { super(name); }
  18. public static void main(String[] args) {
  19. junit.textui.TestRunner.run(Test1a.class);
  20. }
  21. public void setUp() {
  22. Log.clear();
  23. super.setUp();
  24. }
  25. public void testCreateLog() {
  26. assertEquals("", Log.getString());
  27. }
  28. public void testSetXPointLog() {
  29. p1.setX(20);
  30. assertEquals("set;", Log.getString());
  31. }
  32. public void testSetYPointLog() {
  33. p1.setY(10);
  34. assertEquals("", Log.getString());
  35. }
  36. public void testGetYPointLog() {
  37. p1.getY();
  38. assertEquals("", Log.getString());
  39. }
  40. public void testMoveLineLog() {
  41. l1.move(40, 40);
  42. assertEquals("", Log.getString());
  43. }
  44. }