Fix VtIoTests for debug builds (#14358)
1774cfd
added a debug assertion in `CreateIoHandlers` which broke this test.
This commit is contained in:
parent
88c3ef68a5
commit
c12dc2aa4d
|
@ -6,11 +6,11 @@
|
||||||
#include "../../inc/consoletaeftemplates.hpp"
|
#include "../../inc/consoletaeftemplates.hpp"
|
||||||
#include "../../types/inc/Viewport.hpp"
|
#include "../../types/inc/Viewport.hpp"
|
||||||
|
|
||||||
|
#include "../VtIo.hpp"
|
||||||
|
#include "../../interactivity/inc/ServiceLocator.hpp"
|
||||||
|
#include "../../renderer/base/Renderer.hpp"
|
||||||
#include "../../renderer/vt/Xterm256Engine.hpp"
|
#include "../../renderer/vt/Xterm256Engine.hpp"
|
||||||
#include "../../renderer/vt/XtermEngine.hpp"
|
#include "../../renderer/vt/XtermEngine.hpp"
|
||||||
#include "../../renderer/base/Renderer.hpp"
|
|
||||||
#include "../Settings.hpp"
|
|
||||||
#include "../VtIo.hpp"
|
|
||||||
|
|
||||||
#if TIL_FEATURE_CONHOSTDXENGINE_ENABLED
|
#if TIL_FEATURE_CONHOSTDXENGINE_ENABLED
|
||||||
#include "../../renderer/dx/DxRenderer.hpp"
|
#include "../../renderer/dx/DxRenderer.hpp"
|
||||||
|
@ -19,7 +19,7 @@
|
||||||
using namespace WEX::Common;
|
using namespace WEX::Common;
|
||||||
using namespace WEX::Logging;
|
using namespace WEX::Logging;
|
||||||
using namespace WEX::TestExecution;
|
using namespace WEX::TestExecution;
|
||||||
using namespace std;
|
using namespace Microsoft::Console::Interactivity;
|
||||||
|
|
||||||
class Microsoft::Console::VirtualTerminal::VtIoTests
|
class Microsoft::Console::VirtualTerminal::VtIoTests
|
||||||
{
|
{
|
||||||
|
@ -473,6 +473,13 @@ void VtIoTests::BasicAnonymousPipeOpeningWithSignalChannelTest()
|
||||||
|
|
||||||
Log::Comment(L"\tinitializing vtio");
|
Log::Comment(L"\tinitializing vtio");
|
||||||
|
|
||||||
|
// CreateIoHandlers() assert()s on IsConsoleLocked() to guard against a race condition.
|
||||||
|
auto& gci = ServiceLocator::LocateGlobals().getConsoleInformation();
|
||||||
|
gci.LockConsole();
|
||||||
|
const auto cleanup = wil::scope_exit([&]() {
|
||||||
|
gci.UnlockConsole();
|
||||||
|
});
|
||||||
|
|
||||||
VtIo vtio;
|
VtIo vtio;
|
||||||
VERIFY_IS_FALSE(vtio.IsUsingVt());
|
VERIFY_IS_FALSE(vtio.IsUsingVt());
|
||||||
VERIFY_ARE_EQUAL(nullptr, vtio._pPtySignalInputThread);
|
VERIFY_ARE_EQUAL(nullptr, vtio._pPtySignalInputThread);
|
||||||
|
|
Loading…
Reference in New Issue