mirror of
https://github.com/opencv/opencv.git
synced 2026-07-31 08:13:04 +04:00
Merge pull request #20146 from asmorkalov:as/java_test_filter
This commit is contained in:
@@ -51,6 +51,7 @@ if __name__ == "__main__":
|
||||
parser.add_argument("--android_propagate_opencv_env", action="store_true", default=False, help="Android: propagate OPENCV* environment variables")
|
||||
parser.add_argument("--serial", metavar="serial number", default="", help="Android: directs command to the USB device or emulator with the given serial number")
|
||||
parser.add_argument("--package", metavar="package", default="", help="Java: run JUnit tests for specified module or Android package")
|
||||
parser.add_argument("--java_test_exclude", metavar="java_test_exclude", default="", help="Java: Filter out specific JUnit tests")
|
||||
|
||||
parser.add_argument("--trace", action="store_true", default=False, help="Trace: enable OpenCV tracing")
|
||||
parser.add_argument("--trace_dump", metavar="trace_dump", default=-1, help="Trace: dump highlight calls (specify max entries count, 0 - dump all)")
|
||||
|
||||
@@ -115,6 +115,8 @@ class TestSuite(object):
|
||||
cmd = [self.cache.ant_executable, "-Dopencv.build.type=%s" % self.cache.build_type]
|
||||
if self.options.package:
|
||||
cmd += ["-Dopencv.test.package=%s" % self.options.package]
|
||||
if self.options.java_test_exclude:
|
||||
cmd += ["-Dopencv.test.exclude=%s" % self.options.java_test_exclude]
|
||||
cmd += ["buildAndTest"]
|
||||
ret = execute(cmd, cwd=self.cache.java_test_dir)
|
||||
return None, ret
|
||||
|
||||
Reference in New Issue
Block a user