Closed Kissaki closed 7 years ago
{ win32-static } master » cmd /c "cd ../../../../../win64-static-no-ltcg-1.3.x-2017-03-04-1ddd966-811.build\protobuf-3.2.0\cmake && tests.exe --gtest_filter=DiskSourceTreeTest.MapDirectory"
Running main() from gmock_main.cc
Note: Google Test filter = DiskSourceTreeTest.MapDirectory
[==========] Running 1 test from 1 test case.
[----------] Global test environment set-up.
[----------] 1 test from DiskSourceTreeTest
[ RUN ] DiskSourceTreeTest.MapDirectory
C:\MumbleBuild\win64-static-no-ltcg-1.3.x-2017-03-04-1ddd966-811.build\protobuf-3.2.0\src\google\protobuf\compiler\importer_unittest.cc(289): error: Value of: input == NULL
Actual: false
Expected: true
C:\MumbleBuild\win64-static-no-ltcg-1.3.x-2017-03-04-1ddd966-811.build\protobuf-3.2.0\src\google\protobuf\compiler\importer_unittest.cc(290): error: Value of: source_tree_.GetLastErrorMessage()
Actual: "Backslashes, consecutive slashes, \".\", or \"..\" are not allowed in the virtual path"
Expected: error_message
Which is: "File not found."
[ FAILED ] DiskSourceTreeTest.MapDirectory (15 ms)
[----------] 1 test from DiskSourceTreeTest (15 ms total)
[----------] Global test environment tear-down
[==========] 1 test from 1 test case ran. (16 ms total)
[ PASSED ] 0 tests.
[ FAILED ] 1 test, listed below:
[ FAILED ] DiskSourceTreeTest.MapDirectory
1 FAILED TEST
It occurs on the last line/test of the unit test:
ExpectCannotOpenFile("baz/foo/", "File not found.");
CanonicalizePath
removes the ending slash, so the equation in OpenVirtualFile
should be false, which should throw the error message Backslashes, consecutive slashes, \".\", or \"..\" are not allowed in the virtual path
, which is NOT the one the test expects - although the return value should still be NULL
.
Fixed in the tree via 97235e334fee00ae2eef6fd66fa3feeb5eef9562
The protobuf test DiskSourceTreeTest.MapDirectory fails when I run it from my cygwin shell, but succeeds when I run it from a fresh cmd or from a command prompt spawn with Cygwin.bat.
I am using a cygwin install installed and updated by babun (so I don't have to handle the GUI stuff but was able to initially install the required packages via command line). As it is a normal cygwin install which makes use of the cygwin setup.exe this shouldn't make a difference as far as the cygwin install goes.
I updated to protobuf from 2.6.1 to 3.2.0, and the test still fails.
I also noticed the issue #5 still exists and fails, unless the patch is applied (for both versions of protobuf). However, I have not verified this is linked in any way.