aboutsummaryrefslogtreecommitdiff
path: root/src/google/protobuf/compiler/command_line_interface_unittest.cc
diff options
context:
space:
mode:
authorBo Yang <teboring@google.com>2015-04-27 17:44:45 -0700
committerBo Yang <teboring@google.com>2015-04-27 17:44:45 -0700
commit46bd60b92f593a62e150c93cb8761148f6830b47 (patch)
tree26e73b5bc85f00817238685705fa29a1d39236ac /src/google/protobuf/compiler/command_line_interface_unittest.cc
parent9a121853236a8c77693f14d21d27987e5832176a (diff)
downloadprotobuf-46bd60b92f593a62e150c93cb8761148f6830b47.tar.gz
protobuf-46bd60b92f593a62e150c93cb8761148f6830b47.tar.bz2
protobuf-46bd60b92f593a62e150c93cb8761148f6830b47.zip
Modify directory to use in test
Change-Id: Iede1dc4e70427663e0d3c5304fa86b3aebf492b7
Diffstat (limited to 'src/google/protobuf/compiler/command_line_interface_unittest.cc')
-rw-r--r--src/google/protobuf/compiler/command_line_interface_unittest.cc6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/google/protobuf/compiler/command_line_interface_unittest.cc b/src/google/protobuf/compiler/command_line_interface_unittest.cc
index a2cbbdc6..e284c791 100644
--- a/src/google/protobuf/compiler/command_line_interface_unittest.cc
+++ b/src/google/protobuf/compiler/command_line_interface_unittest.cc
@@ -288,6 +288,7 @@ void CommandLineInterfaceTest::Run(const string& command) {
if (!disallow_plugins_) {
cli_.AllowPlugins("prefix-");
+#ifndef GOOGLE_THIRD_PARTY_PROTOBUF
const char* possible_paths[] = {
// When building with shared libraries, libtool hides the real executable
// in .libs and puts a fake wrapper in the current directory.
@@ -316,6 +317,11 @@ void CommandLineInterfaceTest::Run(const string& command) {
}
if (plugin_path.empty()) {
+#else
+ string plugin_path = "third_party/protobuf/test_plugin";
+
+ if (access(plugin_path.c_str(), F_OK) != 0) {
+#endif // GOOGLE_THIRD_PARTY_PROTOBUF
GOOGLE_LOG(ERROR)
<< "Plugin executable not found. Plugin tests are likely to fail.";
} else {