From f747b829d02a4b76fc44da2a0eb1940c3e9cd593 Mon Sep 17 00:00:00 2001 From: aclement Date: Wed, 8 Jun 2005 10:48:50 +0000 Subject: tests for pr84260: static imports --- tests/bugs150/pr84260/A.java | 6 ++++++ tests/bugs150/pr84260/I1.java | 6 ++++++ tests/bugs150/pr84260/I2.java | 9 +++++++++ tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java | 4 ++++ tests/src/org/aspectj/systemtest/ajc150/ajc150.xml | 14 ++++++++++++++ 5 files changed, 39 insertions(+) create mode 100644 tests/bugs150/pr84260/A.java create mode 100644 tests/bugs150/pr84260/I1.java create mode 100644 tests/bugs150/pr84260/I2.java diff --git a/tests/bugs150/pr84260/A.java b/tests/bugs150/pr84260/A.java new file mode 100644 index 000000000..32062ff34 --- /dev/null +++ b/tests/bugs150/pr84260/A.java @@ -0,0 +1,6 @@ +package a.b.c; + +public class A { + + public static void m() {System.err.println("static method running");} +} diff --git a/tests/bugs150/pr84260/I1.java b/tests/bugs150/pr84260/I1.java new file mode 100644 index 000000000..5ddcac98f --- /dev/null +++ b/tests/bugs150/pr84260/I1.java @@ -0,0 +1,6 @@ +import static a.b.c.A.m; +public class I1 { + public static void main(String []argv) { + m(); + } +} diff --git a/tests/bugs150/pr84260/I2.java b/tests/bugs150/pr84260/I2.java new file mode 100644 index 000000000..6e36b2dc7 --- /dev/null +++ b/tests/bugs150/pr84260/I2.java @@ -0,0 +1,9 @@ +import static a.b.c.A.*; + +public class I2 { + + public static void main(String []argv) { + m(); + } + +} diff --git a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java index 7ee575f19..5e27fc0a3 100644 --- a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java +++ b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java @@ -178,6 +178,10 @@ public class Ajc150Tests extends org.aspectj.testing.XMLBasedAjcTestCase { runTest("NPE in reflect implementation"); } + public void testStaticImports_pr84260() { + runTest("static import failures"); + } + // helper methods..... public SyntheticRepository createRepos(File cpentry) { diff --git a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml index 863c39dae..41b2a7780 100644 --- a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml +++ b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml @@ -51,6 +51,20 @@ + + + + + + + + + + + + + + -- cgit v1.2.3