aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwisberg <wisberg>2003-08-14 22:49:08 +0000
committerwisberg <wisberg>2003-08-14 22:49:08 +0000
commitc6eb8d360b20d409683eb3f5392249d43828e773 (patch)
tree5e6391d10f6ae72a5efac1d6f7061df911a39a67
parentbca09473654d7c665716a35dde500158d0a726e9 (diff)
downloadaspectj-c6eb8d360b20d409683eb3f5392249d43828e773.tar.gz
aspectj-c6eb8d360b20d409683eb3f5392249d43828e773.zip
static methods for unwrapping to keep internal structure knowledge local
-rw-r--r--testing/src/org/aspectj/testing/harness/bridge/AjcTest.java14
1 files changed, 14 insertions, 0 deletions
diff --git a/testing/src/org/aspectj/testing/harness/bridge/AjcTest.java b/testing/src/org/aspectj/testing/harness/bridge/AjcTest.java
index e67eb8b9e..7d4e97036 100644
--- a/testing/src/org/aspectj/testing/harness/bridge/AjcTest.java
+++ b/testing/src/org/aspectj/testing/harness/bridge/AjcTest.java
@@ -452,6 +452,20 @@ public class AjcTest extends RunSpecIterator {
*/
public static class Suite extends RunSpecIterator {
final Spec spec;
+
+ /**
+ * Count the number of AjcTest in this suite.
+ * @param spec
+ * @return
+ */
+ public static int countTests(Suite.Spec spec) {
+ return spec.children.size();
+ }
+
+ public static AjcTest.Spec[] getTests(Suite.Spec spec) {
+ return (AjcTest.Spec[]) spec.children.toArray(new AjcTest.Spec[0]);
+ }
+
public Suite(Spec spec, Sandbox sandbox, Validator validator) {
super(spec, sandbox, validator, false);
this.spec = spec;