diff options
author | Adam Cozzette <acozzette@google.com> | 2016-06-29 15:23:27 -0700 |
---|---|---|
committer | Adam Cozzette <acozzette@google.com> | 2016-06-29 15:38:03 -0700 |
commit | d64a2d9941c36a7bc2a7959ea10ab8363192ac14 (patch) | |
tree | 52330d146ad63d3d70f3baade00d5d1fea8f5e0c /java/core/src/test/java/com/google/protobuf/TestUtil.java | |
parent | c18aa7795a2e02ef700ff8b039d94ecdcc33432f (diff) | |
download | protobuf-d64a2d9941c36a7bc2a7959ea10ab8363192ac14.tar.gz protobuf-d64a2d9941c36a7bc2a7959ea10ab8363192ac14.tar.bz2 protobuf-d64a2d9941c36a7bc2a7959ea10ab8363192ac14.zip |
Integrated internal changes from Google
This includes all internal changes from around May 20 to now.
Diffstat (limited to 'java/core/src/test/java/com/google/protobuf/TestUtil.java')
-rw-r--r-- | java/core/src/test/java/com/google/protobuf/TestUtil.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/java/core/src/test/java/com/google/protobuf/TestUtil.java b/java/core/src/test/java/com/google/protobuf/TestUtil.java index 08b2a76d..d94f99e3 100644 --- a/java/core/src/test/java/com/google/protobuf/TestUtil.java +++ b/java/core/src/test/java/com/google/protobuf/TestUtil.java @@ -3764,7 +3764,8 @@ public final class TestUtil { private static File getTestDataDir() { // Search each parent directory looking for "src/google/protobuf". - File ancestor = new File("."); + File ancestor = new File(System.getProperty("protobuf.dir", ".")); + String initialPath = ancestor.getAbsolutePath(); try { ancestor = ancestor.getCanonicalFile(); } catch (IOException e) { @@ -3781,7 +3782,7 @@ public final class TestUtil { throw new RuntimeException( "Could not find golden files. This test must be run from within the " + "protobuf source package so that it can read test data files from the " + - "C++ source tree."); + "C++ source tree: " + initialPath); } /** |