Commit 2ba3763e by Gert Wollny Committed by Commit Bot

Capture/Replay: reset CWD after the test ends

As suggested by Jamie Bug: angleproject:5849 Change-Id: I3e548935a9119b7ca7ca392c50bcb0f58ae3e974 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2882578 Commit-Queue: Gert Wollny <gert.wollny@collabora.com> Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org>
parent 2e84e59a
...@@ -97,6 +97,8 @@ class CaptureReplayTests ...@@ -97,6 +97,8 @@ class CaptureReplayTests
return false; return false;
} }
mStartingDirectory = angle::GetCWD().value();
// Load trace // Load trace
mTraceLibrary.reset(new angle::TraceLibrary(testTraceInfo.testName.c_str())); mTraceLibrary.reset(new angle::TraceLibrary(testTraceInfo.testName.c_str()));
...@@ -119,6 +121,7 @@ class CaptureReplayTests ...@@ -119,6 +121,7 @@ class CaptureReplayTests
void cleanupTest() void cleanupTest()
{ {
angle::SetCWD(mStartingDirectory.c_str());
mTraceLibrary.reset(nullptr); mTraceLibrary.reset(nullptr);
mEGLWindow->destroyGL(); mEGLWindow->destroyGL();
mOSWindow->destroy(); mOSWindow->destroy();
...@@ -184,6 +187,7 @@ class CaptureReplayTests ...@@ -184,6 +187,7 @@ class CaptureReplayTests
mTraceLibrary->getSerializedContextState(frame)); mTraceLibrary->getSerializedContextState(frame));
} }
std::string mStartingDirectory;
OSWindow *mOSWindow = nullptr; OSWindow *mOSWindow = nullptr;
EGLWindow *mEGLWindow = nullptr; EGLWindow *mEGLWindow = nullptr;
EGLPlatformParameters mPlatformParams; EGLPlatformParameters mPlatformParams;
......
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