Commit 1ecef1a2 authored by Austin Schuh's avatar Austin Schuh

Modified FindRubyTestDir to use GOOGLE_THIRD_PARTY_PROTOBUF

parent 7b354163
......@@ -47,6 +47,7 @@ namespace {
string FindRubyTestDir(const string& file) {
// Inspired by TestSourceDir() in src/google/protobuf/testing/googletest.cc.
#ifndef GOOGLE_THIRD_PARTY_PROTOBUF
string prefix = ".";
while (!File::Exists(prefix + "/src/google/protobuf/compiler/ruby" + file)) {
if (!File::Exists(prefix)) {
......@@ -57,6 +58,9 @@ string FindRubyTestDir(const string& file) {
prefix += "/..";
}
return prefix + "/src/google/protobuf/compiler/ruby";
#else
return "third_party/protobuf/src/google/protobuf/compiler/ruby";
#endif // GOOGLE_THIRD_PARTY_PROTOBUF
}
// This test is a simple golden-file test over the output of the Ruby code
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment