]> source.dussan.org Git - aspectj.git/commitdiff
removed unnecessary constructors and untabified
authorehilsdal <ehilsdal>
Thu, 28 Aug 2003 16:04:53 +0000 (16:04 +0000)
committerehilsdal <ehilsdal>
Thu, 28 Aug 2003 16:04:53 +0000 (16:04 +0000)
13 files changed:
docs/teaching/exercises/tests/Test.java
docs/teaching/exercises/tests/Test1a.java [deleted file]
docs/teaching/exercises/tests/Test2a.java
docs/teaching/exercises/tests/Test2b.java
docs/teaching/exercises/tests/Test2c.java
docs/teaching/exercises/tests/Test2d.java
docs/teaching/exercises/tests/Test2e.java
docs/teaching/exercises/tests/Test2f.java
docs/teaching/exercises/tests/Test3a.java
docs/teaching/exercises/tests/Test3b.java
docs/teaching/exercises/tests/Test3c.java
docs/teaching/exercises/tests/Test4d.java
docs/teaching/exercises/tests/Test4e.java

index d6d3bb4e6e0d5adf83b8c3c6b9d7c198d86f581c..101dc8c55914087728fa705881496517ac4db3c8 100644 (file)
@@ -17,8 +17,6 @@ import figures.*;
 import junit.framework.*;
 
 public class Test extends TestCase {
-    public Test(String name) { super(name); }
-    public Test() {}
 
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test.class);
diff --git a/docs/teaching/exercises/tests/Test1a.java b/docs/teaching/exercises/tests/Test1a.java
deleted file mode 100644 (file)
index 147a899..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/* *******************************************************************
- * Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC).
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Common Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/cpl-v10.html
- *
- * Contributors:
- *     PARC     initial implementation
- * ******************************************************************/
-
-package tests;
-
-import figures.*;
-import support.Log;
-
-import junit.framework.*;
-
-public class Test1a extends Test {
-    public Test1a(String name) { super(name); }
-
-    public static void main(String[] args) {
-        junit.textui.TestRunner.run(Test1a.class);
-    }
-
-    public void setUp() {
-        Log.clear();
-        super.setUp();
-    }
-
-    public void testCreateLog() {
-        assertEquals("", Log.getString());
-    }
-
-    public void testSetXPointLog() {
-        p1.setX(20);
-        assertEquals("set;", Log.getString());
-    }
-
-    public void testSetYPointLog() {
-        p1.setY(10);
-        assertEquals("", Log.getString());
-    }
-
-    public void testGetYPointLog() {
-        p1.getY();
-        assertEquals("", Log.getString());
-    }
-
-    public void testMoveLineLog() {
-        l1.move(40, 40);
-        assertEquals("", Log.getString());
-    }
-}
index 4bc6dd28a7dafa14971789431c540bcde2826708..ece7191b77af3beebc612a060fc999012863fa93 100644 (file)
@@ -17,7 +17,6 @@ import figures.*;
 import junit.framework.*;
 
 public class Test2a extends TestCase {
-    public Test2a(String name) { super(name); }
 
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test.class);
@@ -25,7 +24,7 @@ public class Test2a extends TestCase {
     }
 
     public void testTooSmall() {
-       Point p1 = new Point(10, 100);
+        Point p1 = new Point(10, 100);
         try {
             p1.setX(-10);
             fail("should have thrown IllegalArgumentException");
@@ -34,8 +33,8 @@ public class Test2a extends TestCase {
     }
 
     public void testNotTooSmall() {
-       Point p1 = new Point(10, 100);
-       p1.setX(0);
+        Point p1 = new Point(10, 100);
+        p1.setX(0);
     }
 
     public void testMove() {
index 822c8de74088aced6e641d5ff9a0aa0dc5398f52..be53f09f33b341e7c0b2b3e002e197c74f964a2a 100644 (file)
@@ -17,8 +17,6 @@ import figures.*;
 import junit.framework.*;
 
 public class Test2b extends TestCase {
-    public Test2b(String name) { super(name); }
-
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test.class);
         junit.textui.TestRunner.run(Test2b.class);
@@ -40,7 +38,7 @@ public class Test2b extends TestCase {
         Group g  = new Group(p1);
         Point p2 = new Point(20, 200);
 
-       g.add(p2);
+        g.add(p2);
     }
 
 }
index 01c4978e4c6635d3d9b324be900b4b97bc9126bb..eef336ea2d99b5d1ad549e8ba5dbf452e9281aa7 100644 (file)
@@ -17,7 +17,6 @@ import figures.*;
 import junit.framework.*;
 
 public class Test2c extends TestCase {
-    public Test2c(String name) { super(name); }
 
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test.class);
index cc8d7f51c1e902074e7db818594b889418284494..6409e8c8e1520fc4048a24355757860314517a4f 100644 (file)
@@ -17,7 +17,6 @@ import figures.*;
 import junit.framework.*;
 
 public class Test2d extends TestCase {
-    public Test2d(String name) { super(name); }
 
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test.class);
index 09ab657905bb66b828ccc1a10e4916a9958b40c9..6ec31d608ed9d253bba8f519f7d8a9a219e96124 100644 (file)
@@ -17,23 +17,22 @@ import figures.*;
 import junit.framework.*;
 
 public class Test2e extends TestCase {
-    public Test2e(String name) { super(name); }
 
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test.class);
         junit.textui.TestRunner.run(Test2e.class);
     }
 
-    public void testSloth() {
-        Point sp = new SlothfulPoint(10, 10);
+    public void testNonMoving() {
+        Point sp = new Point(10, 10) { public void move(int x, int y) {} };
         try {
             sp.move(10, 10);
             fail("should have thrown IllegalStateException");
         } catch (IllegalStateException e) { }
     }
 
-    public void testNonSloth() {
-       Point p1 = new Point(10, 100);
+    public void testMoving() {
+        Point p1 = new Point(10, 100);
         p1.move(3, 30);
     }
 }
index 1b90d268a83a0e3a2a925c3f3e318a4c320f0663..30dfa7fa1d383c3bf775cf1c58d836cfff2de0a8 100644 (file)
@@ -17,7 +17,6 @@ import figures.*;
 import junit.framework.*;
 
 public class Test2f extends Test {
-    public Test2f(String name) { super(name); }
 
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test.class);
index 33afa3a82d3bff049b461bb275fbe66104af77e3..4db5450e99a292bdfefea0b3c8098beaed8fdf07 100644 (file)
@@ -18,7 +18,6 @@ import support.Log;
 import junit.framework.*;
 
 public class Test3a extends Test {
-    public Test3a(String name) { super(name); }
 
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test3a.class);
index 1e8e8bd4dfe4165d1aa54c423aa480138afa6dbd..c722bce7c8c62c4452156e032401efe914dde646 100644 (file)
@@ -18,7 +18,6 @@ import support.Log;
 import junit.framework.*;
 
 public class Test3b extends Test {
-    public Test3b(String name) { super(name); }
 
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test3b.class);
index 292a0213da78525e3cbc3c0111b4bb78845c5748..a8d8883662f1ab4a163da5b24a38246938c944ff 100644 (file)
@@ -18,7 +18,6 @@ import support.Log;
 import junit.framework.*;
 
 public class Test3c extends Test {
-    public Test3c(String name) { super(name); }
 
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test3c.class);
index 234422235336449ee1e93fb23f6f19f9757ec5f8..c4f21ff918782927b2ccf1db2f0a809b74327216 100644 (file)
@@ -19,8 +19,6 @@ import junit.framework.*;
 
 public class Test4d extends Test {
 
-    public Test4d(String name) { super(name); }
-
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test4d.class);
     }
index 3fe4689ee7723aabdf7036afd9dd498fdca4db17..d19beb71bd063bce825f7bbf777765035a8b3885 100644 (file)
@@ -19,8 +19,6 @@ import junit.framework.*;
 
 public class Test4e extends Test {
 
-    public Test4e(String name) { super(name); }
-
     public static void main(String[] args) {
         junit.textui.TestRunner.run(Test4e.class);
     }