project.py: Consider javatests directory for plugins

Bug: Issue 10715
Change-Id: Ie41100a5ecfe7801b5203faecae73befb90aea72
diff --git a/tools/eclipse/project.py b/tools/eclipse/project.py
index 24d4733..46aeb31 100755
--- a/tools/eclipse/project.py
+++ b/tools/eclipse/project.py
@@ -222,7 +222,10 @@
 
         p = path.join(s, 'java')
         if path.exists(p):
-            classpathentry('src', p, out=out)
+            classpathentry('src', p, out=out + '/main')
+            p = path.join(s, 'javatests')
+            if path.exists(p):
+                classpathentry('src', p, out=out + '/test')
             continue
 
         for env in ['main', 'test']: