Skip to content

Commit

Permalink
Added benchmark target to maven_layout()
Browse files Browse the repository at this point in the history
  • Loading branch information
ity committed Jul 29, 2014
1 parent ca40e28 commit e9f737b
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 5 deletions.
2 changes: 1 addition & 1 deletion BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ source_root('src/java', annotation_processor, jvm_binary, java_library, page)
source_root('src/protobuf', java_protobuf_library, page)
source_root('src/python', page, python_binary, python_library, resources)
source_root('src/resources', page, resources, jaxb_library)
source_root('src/scala', jvm_binary, page, scala_library)
source_root('src/scala', jvm_binary, page, scala_library, benchmark)
source_root('src/thrift', java_thrift_library, page, python_thrift_library)

source_root('tests/java', java_library, junit_tests, page)
Expand Down
9 changes: 5 additions & 4 deletions src/python/pants/backend/maven_layout/maven_layout.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
from pants.backend.core.targets.doc import Page
from pants.backend.core.targets.resources import Resources
from pants.backend.jvm.targets.annotation_processor import AnnotationProcessor
from pants.backend.jvm.targets.benchmark import Benchmark
from pants.backend.jvm.targets.java_agent import JavaAgent
from pants.backend.jvm.targets.java_library import JavaLibrary
from pants.backend.jvm.targets.java_tests import JavaTests
Expand Down Expand Up @@ -42,15 +43,15 @@ def root(path, *types):
SourceRoot.register(os.path.join(parse_context.rel_path, basedir, path), *types)

root('src/main/antlr', JavaAntlrLibrary, Page, PythonAntlrLibrary)
root('src/main/java', AnnotationProcessor, JavaAgent, JavaLibrary, JvmBinary, Page)
root('src/main/java', AnnotationProcessor, JavaAgent, JavaLibrary, JvmBinary, Page, Benchmark)
root('src/main/protobuf', JavaProtobufLibrary, Page)
root('src/main/python', Page, PythonBinary, PythonLibrary)
root('src/main/resources', Page, Resources)
root('src/main/scala', JvmBinary, Page, ScalaLibrary)
root('src/main/scala', JvmBinary, Page, ScalaLibrary, Benchmark)
root('src/main/thrift', JavaThriftLibrary, Page, PythonThriftLibrary)

root('src/test/java', JavaLibrary, JavaTests, Page)
root('src/test/java', JavaLibrary, JavaTests, Page, Benchmark)
root('src/test/python', Page, PythonLibrary, PythonTests)
root('src/test/resources', Page, Resources)
root('src/test/scala', JavaTests, Page, ScalaLibrary, ScalaTests)
root('src/test/scala', JavaTests, Page, ScalaLibrary, ScalaTests, Benchmark)

6 changes: 6 additions & 0 deletions src/scala/com/pants/testproject/javasources/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,9 @@ scala_library(
],
sources = rglobs('*.scala')
)

benchmark(name='benchmark',
dependencies=[
],
sources=rglobs('com/pants/testproject/javasources/*.scala')
)

0 comments on commit e9f737b

Please sign in to comment.